text stringlengths 5.51k 28.1k |
|---|
// Package nlp provides general purpose Natural Language Processing.
package nlp
import (
"bytes"
"errors"
"fmt"
"reflect"
"strconv"
"time"
"unicode"
"encoding/json"
"github.com/cdipaolo/goml/base"
"github.com/cdipaolo/goml/text"
"github.com/itrabbit/nlp/parser"
)
// NL is a Natural Language Processor
ty... |
package edit
import (
"bytes"
"context"
"encoding/json"
"fmt"
"io"
"net/http"
"strings"
"github.com/AlecAivazis/survey/v2"
"github.com/MakeNowJust/heredoc"
"github.com/cli/cli/v2/api"
fd "github.com/cli/cli/v2/internal/featuredetection"
"github.com/cli/cli/v2/internal/ghinstance"
"github.com/cli/cli/v2/i... |
package router
import (
"bufio"
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net"
"net/http"
"os/exec"
"regexp"
"strings"
"time"
"github.com/cloudfoundry/yagnats"
. "launchpad.net/gocheck"
"github.com/cloudfoundry/gorouter/common"
"github.com/cloudfoundry/gorouter/config"
"github.com/cloudfoundry/gorou... |
package do255s
import (
"errors"
"io"
"encoding/binary"
"crypto"
cryptorand "crypto/rand"
"golang.org/x/crypto/sha3"
)
// This file implements high-level operations over do255s:
//
// - Key pair generation
// - Key exchange (ECDH)
// - Signature generation and verification
// - Hash-to-curve
// A priva... |
/*
Copyright 2019 Cisco Systems
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
d... |
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: lock_state.proto
package backend
import (
fmt "fmt"
_ "github.com/gogo/protobuf/gogoproto"
proto "github.com/gogo/protobuf/proto"
types "github.com/gogo/protobuf/types"
_ "github.com/mwitkow/go-proto-validators"
cmdb "github.com/easyopsapis/easyops-a... |
// Copyright 2020 <NAME>.
// All rights reserved.
package main
import (
"fmt"
"html/template"
"net/http"
"strings"
"time"
"github.com/derat/aread/common"
"github.com/derat/aread/db"
"github.com/derat/aread/proc"
)
const sessionCookieName = "session"
type handler struct {
cfg *common.Config
proc... |
package worker
import (
"errors"
"github.com/turbonomic/kubeturbo/pkg/discovery/repository"
"github.com/turbonomic/kubeturbo/pkg/discovery/util"
"sync"
"time"
"github.com/turbonomic/kubeturbo/pkg/discovery/dtofactory"
"github.com/turbonomic/kubeturbo/pkg/discovery/metrics"
"github.com/turbonomic/kubeturbo/pkg... |
// Copyright 2015 Auburn University. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package doc
import (
"bytes"
"flag"
"fmt"
"io"
"os/exec"
"strings"
"text/template"
)
type UserGuideContent struct {
docContent
ManPageHTML string
... |
//
// Copyright 2021 Johns Hopkins University
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law ... |
// Copyright 2016 The etcd-operator Authors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.26.0
// protoc v3.13.0
// source: odpf/assets/facets/properties.proto
package facets
import (
_struct "github.com/golang/protobuf/ptypes/struct"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "googl... |
package wat
import (
"context"
"fmt"
"sort"
"time"
"github.com/windmilleng/wat/os/ospath"
)
// The maximum number of commands that decide should return.
// In the future, this might be specified by a flag.
const nDecideCommands = 3
// The extra weight of new duration data, to ensure new data
// isn't drowned o... |
package ydb
import (
"context"
"errors"
"net"
"path"
"strconv"
"sync"
"time"
"github.com/golang/protobuf/proto"
"google.golang.org/grpc"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
"github.com/yandex-cloud/ydb-go-sdk/internal"
"github.com/yandex-cloud/ydb-go-sdk/internal/api/protos... |
// Copyright (c) 2021 Couchbase, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed... |
package influxdb
import (
"bytes"
"compress/gzip"
"context"
"errors"
"fmt"
"io"
"io/ioutil"
"net/http"
"net/url"
"path"
"runtime"
"strings"
"sync/atomic"
"time"
"github.com/cenkalti/backoff"
"github.com/sirupsen/logrus"
"github.com/spf13/viper"
"github.com/tilinna/clock"
"github.com/hligit/gostats... |
package aws
/**
* Panther is a scalable, powerful, cloud-native SIEM written in Golang/React.
* Copyright (C) 2020 Panther Labs Inc
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation... |
package gene
import (
"errors"
"github.com/vertgenlab/gonomics/dna"
"github.com/vertgenlab/gonomics/numbers"
)
var (
ErrNoStopFound = errors.New("frameshift was unable to find a stop before the end of the gene")
)
// Deletion removes bases from the Gene, predicts the effect, and updates the Gene struct to reflec... |
package handlers
import (
"encoding/json"
"errors"
"io"
"net/http"
"os"
"path/filepath"
"io/ioutil"
"github.com/cloud-native-nordics/meetup-kit/pkg/graphql/models"
"github.com/golang/glog"
"github.com/google/uuid"
"github.com/hashicorp/go-memdb"
)
//StatsManager is responsible for managing the stats.json... |
// Package systemd implements support for writing out a
// systemd-networkd compatible set of network config files.
package systemd
import (
"fmt"
"io"
"io/ioutil"
"log"
"os"
"path"
"path/filepath"
"strings"
gnet "github.com/rackn/gohai/plugins/net"
"github.com/rackn/netwrangler/util"
)
// Systemd holds in... |
/*
Copyright 2016 The Rook Authors. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to ... |
/*Practitioner: <NAME>
Authors: <NAME> and <NAME>
Description: This program takes in roof, house size, and coordinates
to give to the user some useful information about
installing solar panels in their home.*/
/*This file is written by Sarah Hsu, except functions MakeCity(),
MakeCityMap(), and ReadFile() were written ... |
package reddit
import (
"fmt"
"github.com/HirbodBehnam/RedditDownloaderBot/config"
"github.com/HirbodBehnam/RedditDownloaderBot/util"
"github.com/PuerkitoBio/goquery"
"html"
"io"
"log"
"net/url"
"path"
"regexp"
"strconv"
"strings"
)
// qualities is the possible qualities of videos in reddit
var qualities ... |
package coolpix
import (
"context"
"encoding/binary"
"errors"
"fmt"
"math/rand"
"strings"
"time"
"github.com/go-ble/ble"
"tinygo.org/x/bluetooth"
ls_sec "github.com/attilaolah/birdcam/nikon"
)
// LocalName advertised by this camera model.
const A900ModelName = "A900"
// UUID generates Nikon vendor-specif... |
// Copyright 2021 <NAME>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writ... |
// Copyright 2015-2018 <NAME>.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in... |
package main
import (
"fmt"
"io/ioutil"
"net/http"
"os"
"path"
"path/filepath"
"regexp"
"sort"
"strconv"
"strings"
"text/template"
"github.com/northbright/pathhelper"
)
const (
redisLabsHomeURL string = "https://redislabs.com"
ebookHomeURL string = "https://redislabs.com/ebook/redis-in-... |
/*
Copyright 2019 Cisco Systems
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
d... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: GetGlobalState.proto
/*
Package GetGlobalState is a generated protocol buffer package.
It is generated from these files:
GetGlobalState.proto
It has these top-level messages:
C2S
S2C
Request
Response
*/
package GetGlobalState
import proto "github.com/... |
// Copyright 2016 The Cockroach Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or ag... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: keyvault.proto
package security
import (
context "context"
fmt "fmt"
proto "github.com/golang/protobuf/proto"
wrappers "github.com/golang/protobuf/ptypes/wrappers"
common "github.com/microsoft/moc/rpc/common"
grpc "google.golang.org/grpc"
codes "googl... |
package peco
import (
"bufio"
"bytes"
"errors"
"fmt"
"os/exec"
"regexp"
"sort"
"strings"
"unicode"
)
// These are used as keys in the config file
const (
IgnoreCaseMatch = "IgnoreCase"
CaseSensitiveMatch = "CaseSensitive"
SmartCaseMatch = "SmartCase"
RegexpMatch = "Regexp"
)
var ignoreCase... |
package main
import (
"encoding/json"
"fmt"
"io/ioutil"
"log"
"math"
"sort"
"strconv"
"strings"
"time"
)
const MinTribeSize = 10;
const MinCommonRequired = 3;
const MinReferenceRequired = 5;
const MinSetSize = 90;
const ReportTopSize = 20;
func main() {
fmt.Println("Starting tribal analysis read out");
... |
// Copyright 2018-2020 Authors of Cilium
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or ag... |
package keccak
import (
"fmt"
"github.com/samli88/go-x11-hash/hash"
)
// HashSize holds the size of a hash in bytes.
const HashSize = int(64)
// BlockSize holds the size of a block in bytes.
const BlockSize = uintptr(72)
type digest struct {
ptr uintptr
cnt uintptr
h [25]uint64
b [144]byte
}
// New return... |
/*
Copyright 2015 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... |
/*
Copyright 2019 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... |
package test
import (
"fmt"
"github.com/google/go-cmp/cmp"
"github.com/google/go-cmp/cmp/cmpopts"
"github.com/inexio/go-monitoringplugin"
"github.com/inexio/thola/internal/network"
"github.com/inexio/thola/internal/parser"
"github.com/inexio/thola/internal/request"
"github.com/mitchellh/colorstring"
"github.c... |
package modules
import (
"encoding/json"
"io"
"time"
"gitlab.com/NebulousLabs/Sia/crypto"
"gitlab.com/NebulousLabs/Sia/types"
"gitlab.com/NebulousLabs/errors"
)
// ErrHostFault is an error that is usually extended to indicate that an error
// is the host's fault.
var ErrHostFault = errors.New("host has return... |
/*
Copyright 2015 Gravitational, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, soft... |
/*
Copyright 2016 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... |
// Copyright 2021 TiKV Project Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agre... |
package apply
import (
"fmt"
"os"
"path/filepath"
"strings"
"time"
"github.com/go-git/go-billy/v5/memfs"
"github.com/kyverno/kyverno/api/kyverno/v1beta1"
"github.com/kyverno/kyverno/cmd/cli/kubectl-kyverno/utils/common"
sanitizederror "github.com/kyverno/kyverno/cmd/cli/kubectl-kyverno/utils/sanitizedError"
... |
// Copyright 2019 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by appl... |
package thorchain
import (
"errors"
"fmt"
"github.com/armon/go-metrics"
"github.com/cosmos/cosmos-sdk/telemetry"
"gitlab.com/thorchain/thornode/common"
"gitlab.com/thorchain/thornode/common/cosmos"
"gitlab.com/thorchain/thornode/x/thorchain/keeper"
)
type SwapperV75 struct {
pools Pools // caches pool ... |
// Copyright 2022 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.28.0
// protoc v3.14.0
// source: api/proto/resources.proto
pa... |
// Copyright (c) 2021 Terminus, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agree... |
// +build windows
// Package layers deals with container layer mounting/unmounting for LCOW and WCOW
package layers
import (
"context"
"fmt"
"path/filepath"
"github.com/Microsoft/hcsshim/internal/log"
"github.com/Microsoft/hcsshim/internal/ospath"
hcsschema "github.com/Microsoft/hcsshim/internal/schema2"
"git... |
package notify
import (
"bytes"
"context"
"crypto/tls"
"fmt"
"io"
"mime/quotedprintable"
"net"
"net/smtp"
"text/template"
"time"
log "github.com/go-pkgz/lgr"
"github.com/go-pkgz/repeater"
"github.com/pkg/errors"
)
// EmailParams contain settings for email notifications
type EmailParams struct {
From ... |
package cli
import (
"encoding/json"
"fmt"
"log"
"sort"
"strings"
"github.com/zigdon/spacetraders"
)
func init() {
for _, c := range []cmd{
{
Section: "Automation",
Name: "CreateTradeRoute",
Usage: "CreateTradeRoute <name> <location, cargo>...",
Help: "Create a new trade route. Ships on the... |
/*************************************************************************
* Copyright 2018 Gravwell, Inc. All rights reserved.
* Contact: <<EMAIL>>
*
* This software may be modified and distributed under the terms of the
* BSD 2-clause license. See the LICENSE file for details.
**********************************... |
// Copyright 2015 go-fuzz project authors. All rights reserved.
// Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
package main
import (
"fmt"
"log"
"net/rpc"
"path/filepath"
"sync"
"sync/atomic"
"time"
"github.com/lukaszmatczak/go-fuzz/go-fuzz/versifier"
. "g... |
package util
import (
"errors"
"fmt"
"strings"
"time"
pb "github.com/linkerd/linkerd2/controller/gen/public"
"github.com/linkerd/linkerd2/pkg/addr"
"github.com/linkerd/linkerd2/pkg/k8s"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"k8s.io/api/core/v1"
k8sErrors "k8s.io/apimachinery/pkg/ap... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: orc8r/protos/certifier.proto
package protos
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
duration "github.com/golang/protobuf/ptypes/duration"
timestamp "github.com/golang/protobuf/ptypes/timestamp"
math "math"
)
// Reference imports to ... |
// Copyright 2019 The Cockroach Authors.
//
// Licensed as a CockroachDB Enterprise file under the Cockroach Community
// License (the "License"); you may not use this file except in compliance with
// the License. You may obtain a copy of the License at
//
// https://github.com/cockroachdb/cockroach/blob/master/li... |
// Copyright 2021 Intuitive Labs GmbH. All rights reserved.
//
// Use of this source code is governed by a source-available license
// that can be found in the LICENSE.txt file in the root of the source
// tree.
package httpsp
import (
"github.com/intuitivelabs/bytescase"
)
// HdrT is used to hold the header type a... |
// Copyright 2018 Shift Devices AG
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed ... |
package core
import (
"context"
"errors"
"fmt"
"io"
"net"
"sync"
"sync/atomic"
"github.com/lucas-clemente/quic-go"
"github.com/yomorun/yomo/core/frame"
"github.com/yomorun/yomo/core/yerr"
// authentication implements, Currently, only token authentication is implemented
_ "github.com/yomorun/yomo/pkg/auth... |
package workers
import (
"encoding/json"
"fmt"
"reflect"
"strings"
log "github.com/sirupsen/logrus"
app "github.com/appdynamics/cluster-agent/appd"
m "github.com/appdynamics/cluster-agent/models"
"github.com/google/uuid"
)
const (
DRILL_DOWN_URL_TEMPLATE string = "%s#/location=ANALYTICS_ADQL_SEARCH&search... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v3/enums/google_ads_field_data_type.proto
package enums
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
_ "google.golang.org/genproto/googleapis/api/annotations"
)
// Reference imports to suppress errors if ... |
package tc
import (
"database/sql/driver"
"encoding/json"
"fmt"
"net"
"time"
"github.com/apache/trafficcontrol/lib/go-util"
)
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information... |
// Copyright 2018 The LUCI Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed... |
// Copyright (C) The Arvados Authors. All rights reserved.
//
// SPDX-License-Identifier: AGPL-3.0
// Package crunchstat reports resource usage (CPU, memory, disk,
// network) for a cgroup.
package crunchstat
import (
"bufio"
"bytes"
"errors"
"fmt"
"io"
"io/ioutil"
"log"
"os"
"strconv"
"strings"
"time"
)
... |
package main
import (
"image"
"log"
"os"
"github.com/nfnt/resize"
"github.com/rajveermalviya/go-wayland/examples/imageviewer/internal/swizzle"
"github.com/rajveermalviya/go-wayland/examples/imageviewer/internal/tempfile"
"github.com/rajveermalviya/go-wayland/wayland/client"
"github.com/rajveermalviya/go-wayla... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v1/enums/local_placeholder_field.proto
package enums // import "google.golang.org/genproto/googleapis/ads/googleads/v1/enums"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import _ "google.golang.org... |
package lnutil
import (
"bufio"
"bytes"
"encoding/binary"
"fmt"
"math/big"
"github.com/adiabat/btcd/btcec"
"github.com/adiabat/btcd/chaincfg/chainhash"
"github.com/adiabat/btcd/wire"
)
// DlcContractStatus is an enumeration containing the various statuses a
// contract can have
type DlcContractStatus int
c... |
package consumer
import (
"bufio"
"fmt"
"net"
"os"
"os/exec"
"runtime"
"strconv"
"sync"
"time"
"github.com/couchbase/eventing/common"
cb "github.com/couchbase/eventing/dcp/transport/client"
"github.com/couchbase/eventing/logging"
"github.com/couchbase/eventing/util"
"runtime/debug"
)
var (
debuggerPID... |
package main
import (
"encoding/csv"
"flag"
"fmt"
"io"
"os"
"os/user"
"path/filepath"
"sort"
"strconv"
"strings"
"time"
"github.com/mpetavy/common"
"github.com/wlbr/feiertage"
)
const mask = common.Day + common.DateSeparator + common.Month + common.DateSeparator + common.Year + common.Separator + common... |
// Copyright 2022 The CubeFS Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agree... |
// Package db implements bridge to persistent storage represented by Mongo database.
package db
import (
"context"
"fmt"
"techpay-api-graphql/internal/types"
"github.com/ethereum/go-ethereum/common"
"go.mongodb.org/mongo-driver/bson"
"go.mongodb.org/mongo-driver/mongo"
"go.mongodb.org/mongo-driver/mongo/option... |
// Copyright 2015 The Vanadium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package transcoder
import (
"fmt"
"strings"
"unicode"
"unicode/utf8"
"mojo/public/interfaces/bindings/mojom_types"
"v.io/v23/vdl"
)
// upperCame... |
/*
* Copyright 2020 Saffat Technologies, Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law... |
// Copyright 2015-Present Couchbase, Inc.
//
// Use of this software is governed by the Business Source License included
// in the file licenses/BSL-Couchbase.txt. As of the Change Date specified
// in that file, in accordance with the Business Source License, use of this
// software will be governed by the Apach... |
package main
import (
"flag"
"fmt"
"math/rand"
"net/http"
_ "net/http/pprof"
"os"
"os/signal"
"runtime"
"sort"
"strings"
"syscall"
"time"
"github.com/uber-go/zap"
"github.com/yulrizka/bot"
"github.com/yulrizka/fam100"
"golang.org/x/net/context"
)
var (
log zap.Logger
logLevel ... |
package watchdog
import (
"errors"
"fmt"
"log"
"math"
"os"
"path/filepath"
"runtime"
"runtime/debug"
"runtime/pprof"
"sync"
"time"
"github.com/elastic/gosigar"
"github.com/raulk/clock"
)
// ErrNotSupported is returned when the watchdog does not support the requested
// run mode in the current OS/arch.
v... |
package fusefrontend
// FUSE operations on file handles
import (
"bytes"
"encoding/hex"
"fmt"
"io"
"log"
"os"
"sync"
"syscall"
"time"
"github.com/hanwen/go-fuse/fuse"
"github.com/hanwen/go-fuse/fuse/nodefs"
"github.com/rfjakob/gocryptfs/internal/contentenc"
"github.com/rfjakob/gocryptfs/internal/openfi... |
// Go from multi-language-benchmark/src/havlak/go_pro
// Copyright 2011 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICEN... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: opencensus/proto/trace/v1/trace_config.proto
package v1
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = mat... |
/*
* Copyright 2019-present Ciena Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or ... |
package generate
import (
"context"
"fmt"
"net"
"sort"
"strings"
"github.com/containers/common/libimage"
"github.com/containers/podman/v3/libpod/network/types"
"github.com/containers/podman/v3/utils"
"github.com/containers/podman/v3/pkg/specgen"
"github.com/containers/podman/v3/pkg/specgenutil"
"github.co... |
// Transform a "before layout" box tree into an "after layout" tree,
// by breaking boxes across lines and pages; and determining the size and dimension
// of each box fragment.
//
// Boxes in the new tree have `used values` in their PositionX,
// PositionY, Width and Height attributes, amongst others.
// (see http://w... |
package detour
import (
"gonet/base"
"gonet/base/vector"
"gonet/server/game/lmath"
"io/ioutil"
"math"
"strings"
"sync"
"unsafe"
)
//坐标系
//Z Y(0)
//* *
//* *
//* *
//* *
//* * * * * X(Pi/2)
type (
Detour struct {
mMaxNode int
mMesh *DtNavMesh
mQuery *DtNavMeshQuer... |
// These tests instantiate in-memory-storage backend instances of dex and
// session-service, and use a standard http.Client to interacting with them.
// These interactions do properly handle redirects and cookies, so they closely
// approximate what happens in a real-world setting.
package server_test
import (
"cont... |
package s3proxytest
import (
"bufio"
"bytes"
"crypto/rand"
"crypto/sha256"
jsonlib "encoding/json"
"fmt"
"io"
"io/ioutil"
"net/http"
"net/http/httptest"
"net/url"
"os"
"strconv"
"strings"
"sync"
"testing"
"time"
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/credentials"
"github.co... |
// Copyright 2019 The Kubernetes Authors.
// SPDX-License-Identifier: Apache-2.0
package cmdeval
import (
"bytes"
"context"
"fmt"
"io"
"os"
"path/filepath"
"strings"
docs "github.com/GoogleContainerTools/kpt/internal/docs/generated/fndocs"
"github.com/GoogleContainerTools/kpt/internal/fnruntime"
"github.co... |
package docker
import (
"context"
"encoding/json"
"errors"
"fmt"
"io"
"os"
"os/signal"
"strings"
"syscall"
"time"
"github.com/docker/docker/api/types"
"github.com/docker/docker/client"
"golang.org/x/term"
"github.com/beaker/runtime"
"github.com/beaker/runtime/logging"
)
// Container wraps a Docker co... |
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: list.proto
package persistentvolumeclaim
import (
fmt "fmt"
_ "github.com/gogo/protobuf/gogoproto"
proto "github.com/gogo/protobuf/proto"
_ "github.com/mwitkow/go-proto-validators"
container "github.com/easyopsapis/easyops-api-go/protorepo-models/easy... |
// Copyright 2016 The Gosl Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package la
import (
"testing"
"github.com/cpmech/gosl/chk"
)
func TestSpUmfpack01a(tst *testing.T) {
//verbose()
chk.PrintTitle("SpUmfpack01a. real")
... |
// Copyright 2019 <NAME> <<EMAIL>>
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to
// deal in the Software without restriction, including without limitation the
// rights to use, copy, modify, merge, publish, ... |
package sectorstorage
import (
"context"
"github.com/filecoin-project/lotus/extern/sector-storage/database"
"github.com/filecoin-project/lotus/extern/sector-storage/sealtasks"
"github.com/google/uuid"
"time"
"golang.org/x/xerrors"
"github.com/filecoin-project/lotus/extern/sector-storage/stores"
)
type schedW... |
/*
* TencentBlueKing is pleased to support the open source community by making 蓝鲸智云-权限中心(BlueKing-IAM) available.
* Copyright (C) 2017-2021 THL A29 Limited, a Tencent company. All rights reserved.
* Licensed under the MIT License (the "License"); you may not use this file except in compliance with the License.
* Yo... |
package iso9660
import (
"container/list"
"errors"
"fmt"
"io"
"io/ioutil"
"math"
"os"
"path"
"runtime"
"strings"
"sync/atomic"
"time"
)
const (
primaryVolumeDirectoryIdentifierMaxLength = 31 // ECMA-119 7.6.3
primaryVolumeFileIdentifierMaxLength = 30 // ECMA-119 7.5
)
var (
// ErrFileTooLarge is ... |
// Copyright 2018 <NAME>
package den
import (
"fmt"
"image"
"image/color"
//"log"
"math/big"
"strings"
"time"
)
// conjugate power table (CPT)
type CPT struct {
degree int
cycleTypes []CycleType // index table; associates i to lambda_i
cycleTypeMap map[string]int // string form of cycle type -> index
resu... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v3/services/detail_placement_view_service.proto
package services
import (
context "context"
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
resources "google.golang.org/genproto/googleapis/ads/googleads/v3/resources"... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: yandex/cloud/endpoint/api_endpoint_service.proto
package endpoint
import (
context "context"
fmt "fmt"
proto "github.com/golang/protobuf/proto"
_ "google.golang.org/genproto/googleapis/api/annotations"
grpc "google.golang.org/grpc"
codes "google.golang... |
//go:build e2e_tests
// +build e2e_tests
package e2e
import (
"context"
"encoding/json"
"fmt"
"io"
"net/http"
"os"
"strconv"
"testing"
"time"
"github.com/blang/semver/v4"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
corev1 "k8s.io/api/core/v1"
apiextensionsv1 "k8s.io/apiex... |
// +build rpi
package broadcom
import (
"context"
"fmt"
"os"
"reflect"
"sync"
"syscall"
"time"
"unsafe"
"github.com/djthorpe/gopi/v3"
"github.com/djthorpe/gopi/v3/pkg/hw/gpio"
"github.com/djthorpe/gopi/v3/pkg/hw/platform"
"github.com/djthorpe/gopi/v3/pkg/sys/rpi"
)
type GPIO struct {
gopi.Unit
sync.RW... |
package parser
import (
"errors"
"fmt"
"github.com/zbysir/vpl/internal/util"
"strings"
)
type Prop struct {
IsStatic bool // 是否是静态的(v-bind:语法是动态, 之外是静态)
CanBeAttr bool // 是否当成attr输出
Key string
StaticVal interface{} // 静态的value, 如style和class在编译时就会被解析成map和slice
ValCode string // 如果props是动态的, valC... |
package opensea
import (
"bytes"
"context"
"encoding/json"
"fmt"
"io"
"net/http"
"sort"
"strings"
"time"
"github.com/mikeydub/go-gallery/service/persist"
"github.com/mikeydub/go-gallery/util"
)
// Assets is a list of NFTs from OpenSea
type Assets struct {
Assets []Asset `json:"assets"`
}
// Asset is an ... |
package manage_main
import (
"fmt"
"net"
"os"
"time"
"github.com/gitbufenshuo/gopen/example/jumpjump/commmsg"
"github.com/gitbufenshuo/gopen/example/jumpjump/commmsg/protodefine/pgocode/jump"
"github.com/gitbufenshuo/gopen/example/jumpjump/commmsg/server/imple"
"github.com/gitbufenshuo/gopen/example/jumpjump/... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.