text
stringlengths
3.08k
10.4k
package dataconn import ( "bytes" "context" "fmt" "github.com/golang/protobuf/proto" "github.com/zrepl/zrepl/logger" "github.com/zrepl/zrepl/replication/logic/pdu" "github.com/zrepl/zrepl/rpc/dataconn/stream" "github.com/zrepl/zrepl/transport" "github.com/zrepl/zrepl/zfs" ) // WireInterceptor has a chance ...
package node import ( "errors" "fmt" "io" "reflect" "strings" "github.com/spf13/cobra" kapi "github.com/GoogleCloudPlatform/kubernetes/pkg/api" "github.com/GoogleCloudPlatform/kubernetes/pkg/api/meta" "github.com/GoogleCloudPlatform/kubernetes/pkg/client" "github.com/GoogleCloudPlatform/kubernetes/pkg/kube...
// Copyright 2019 Istio 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 i...
//go:build linux && cgo && !agent package db import ( "context" "database/sql" "fmt" "time" "github.com/lxc/lxd/shared" ) // Code generation directives. // //go:generate -command mapper lxd-generate db mapper -t snapshots.mapper.go //go:generate mapper reset -i -b "//go:build linux && cgo && !agent" // //go:ge...
package sqlstore import ( "context" "testing" "time" "github.com/grafana/grafana/pkg/infra/log" "github.com/grafana/grafana/pkg/services/annotations" "github.com/grafana/grafana/pkg/setting" "github.com/stretchr/testify/require" ) func TestAnnotationCleanUp(t *testing.T) { fakeSQL := InitTestDB(t) t.Cleanu...
package main import ( "context" "io" "log" "os" "path/filepath" "runtime" "strings" "sync" "time" "github.com/cheggaaa/pb" proto "github.com/mattn/ft/proto" "github.com/urfave/cli" "google.golang.org/grpc" "google.golang.org/grpc/credentials" ) type downloader struct { dir string client proto....
package main import ( "database/sql" "encoding/json" "errors" "flag" "fmt" "io/ioutil" "net/http" "os" "path" "runtime" "strconv" "strings" _ "github.com/go-sql-driver/mysql" ) type configuration struct { ServerPort int `json:"server_port"` Username string `json:"mysql_username"` Password stri...
package types import ( "errors" "fmt" "strings" "time" sdk "github.com/cosmos/cosmos-sdk/types" ) // Market an asset in the pricefeed type Market struct { MarketID string `json:"market_id" yaml:"market_id"` BaseAsset string `json:"base_asset" yaml:"base_asset"` QuoteAsset string ...
// Code generated by MockGen. DO NOT EDIT. // Source: github.com/web-platform-tests/wpt.fyi/shared (interfaces: GitHubOAuth) // Package sharedtest is a generated GoMock package. package sharedtest import ( context "context" gomock "github.com/golang/mock/gomock" github "github.com/google/go-github/v28/github" sha...
// Copyright 2017 Percona LLC // // 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 wr...
/* * @Author: Edward https://github.com/crazybber * @Date: 2020-09-22 22:28:55 * @Last Modified by: Eamon * @Last Modified time: 2020-09-22 22:39:47 * @Description: Current file for graph database(dgraph) using */ package rbac import ( "context" rbac "github.com/micro-community/micro-starter/protos/rbac" "g...
package util import ( "errors" "github.com/Shopify/sarama" "github.com/stretchr/testify/assert" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/kubernetes/fake" "knative.dev/eventing-kafka/pkg/channel/distributed/common/kafka/constants" logtesting "knative.dev/pkg/lo...
// Package grpcsystem manages connecting, loading, monitoring, and disconnecting // of gRPC plugins. package grpcsystem import ( "sync" "time" "github.com/ambientkit/ambient" "github.com/ambientkit/ambient/pkg/grpcp" hplugin "github.com/hashicorp/go-plugin" ) //go:generate go run github.com/vburenin/ifacemaker ...
// Copyright (C) The Arvados Authors. All rights reserved. // // SPDX-License-Identifier: Apache-2.0 package health import ( "context" "encoding/json" "errors" "fmt" "net/http" "net/url" "sync" "time" "git.curoverse.com/arvados.git/sdk/go/arvados" "git.curoverse.com/arvados.git/sdk/go/auth" ) const defaul...
// Package request provides the HTTP request functionality for the PHPIPAM API. package request import ( "bytes" "encoding/json" "fmt" "io/ioutil" "net/http" "github.com/youkoulayley/phpipam-sdk-go/phpipam/session" ) // APIResponse represents a PHPIPAM response body. Both successful and // unsuccessful request...
// Copyright 2015 Globo.com. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package main import ( "encoding/json" "flag" "fmt" "io" "log" "net/http" "os" "sync" "time" "github.com/tsuru/tsuru/db/storage" "gopkg.in/tylerb/gracefu...
package testkit import ( "crypto/rand" "crypto/rsa" "crypto/sha256" "crypto/x509" "crypto/x509/pkix" "encoding/base64" "encoding/hex" "encoding/pem" "strings" "testing" "github.com/stretchr/testify/require" ) const ( rsaKeySize = 2048 ) // Create Key generates rsa.PrivateKey func CreateKey(t *testing.T)...
package lua import ( "fmt" "strings" ) const ( VarArgHasArg uint8 = 1 VarArgIsVarArg uint8 = 2 VarArgNeedsArg uint8 = 4 ) type DbgLocalInfo struct { Name string StartPc int EndPc int } type DbgCall struct { Name string Pc int } type FunctionProto struct { SourceName string LineDefined ...
package main import ( _ "embed" "fmt" "math" "sort" . "github.com/beanz/advent/lib-go" ) //go:embed input.txt var input []byte type VisitKey struct { a1, a2 Point } type Game struct { a map[Point]int bb *BoundingBox vc map[VisitKey]bool best Point debug bool } func (g *Game) String() string ...
package buildpack import ( "fmt" "io/ioutil" "os" "path/filepath" "sort" "strings" "github.com/BurntSushi/toml" "github.com/pkg/errors" "github.com/buildpacks/lifecycle/api" "github.com/buildpacks/lifecycle/launch" ) type LayersDir struct { Path string layers []Layer name string Buildpack...
// // Copyright (c) 2018 Intel Corporation // Copyright 2015-2017 CNI 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 // // U...
/* Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 */ package pvtstatepurgemgmt import ( proto "github.com/golang/protobuf/proto" "github.com/sinochem-tech/fabric/common/flogging" "github.com/sinochem-tech/fabric/common/ledger/util" "github.com/sinochem-tech/fabric/common/ledger/util...
/* * Copyright (c) 2011 <NAME> <<EMAIL>> * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCL...
// Copyright (c) 2017 Zededa, Inc. // SPDX-License-Identifier: Apache-2.0 // Determine differences in terms of the set of files in the configDir // vs. the statusDir. // On startup report the intial files in configDir as "modified" and report any // which exist in statusDir but not in configDir as "deleted". Then watc...
package model import ( "net/url" xtime "go-common/library/time" ) // Chall is the row view for every challenge type Chall struct { Cid int64 `json:"cid" gorm:"column:id"` Gid int64 `json:"gid" gorm:"column:gid"` Oid int64 `json:"oid" gorm:"column:oid"` O...
package eval import ( "bufio" "fmt" "io" "os" "strings" "sync" "github.com/elves/elvish/pkg/diag" ) // Frame contains information of the current running function, aknin to a call // frame in native CPU execution. A Frame is only modified during and very // shortly after creation; new Frame's are "forked" when...
// Copyright (c) 2020, The OTNS Authors. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are met: // 1. Redistributions of source code must retain the above copyright // notice, this list of conditi...
// Package ais_test contains AIS integration tests. /* * Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved. */ package ais_test import ( "fmt" "os" "os/exec" "path/filepath" "strings" "testing" "github.com/NVIDIA/aistore/cmn" "github.com/NVIDIA/aistore/tutils" ) const ( // Public object name to ...
package metadata import ( "context" "errors" "fmt" "io/ioutil" "os" "path/filepath" "github.com/containerd/containerd/remotes" imgreference "github.com/openshift/library-go/pkg/image/reference" "github.com/operator-framework/operator-registry/pkg/image/containerdregistry" "github.com/sirupsen/logrus" utile...
package main import ( "fmt" "path/filepath" "strings" "github.com/holiman/uint256" "github.com/spf13/cobra" "github.com/spf13/viper" tcmd "github.com/tendermint/tendermint/cmd/tendermint/commands" "github.com/tendermint/tendermint/libs/cli" "github.com/tendermint/tendermint/node" "github.com/tendermint/ten...
//Package vrpc provides support for automatically logging RPC Calls //from a RPC Client to a RPC Server package vrpc import ( "bufio" "encoding/gob" "io" "log" "net" "net/rpc" "github.com/DistributedClocks/GoVector/govec" ) //RPCDial connects to a RPC server at the specified network address. The //logger is p...
package main import ( "bytes" "flag" "fmt" "net/http" "os" "os/signal" "strings" "syscall" "time" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/push" io_prometheus_client "github.com/prometheus/client_model/go" "github.com/prometheus/common/expfmt" "git...
package main import ( "encoding/json" "flag" "fmt" "io/ioutil" "log" "math" "net/http" "os" "path/filepath" "github.com/dtylman/gitmoo-goog/downloader" "github.com/dtylman/gitmoo-goog/version" "golang.org/x/net/context" "golang.org/x/oauth2" "golang.org/x/oauth2/google" photoslibrary "google.golang.org...
// Copyright (c) 2018 Uber Technologies, Inc. // // 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...
// Copyright 2019-2022 The Liqo 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...
package neo4j import ( "context" "fmt" "github.com/ONSdigital/dp-graph/v2/graph/driver" "github.com/ONSdigital/dp-graph/v2/models" "github.com/ONSdigital/dp-graph/v2/neo4j/mapper" "github.com/ONSdigital/dp-graph/v2/neo4j/query" "github.com/ONSdigital/log.go/log" ) // Type check to ensure that Neo4j implements...
// Copyright 2016 <NAME>. All rights reserved. // Use of this source code is governed by a MIT-style // license that can be found in the LICENSE file. package routing import ( "net/http" ) // Context represents the contextual data and environment while processing an incoming HTTP request. type Context struct { Req...
package cloudresources import ( "context" "fmt" "strings" crov1alpha1 "github.com/integr8ly/cloud-resource-operator/apis/integreatly/v1alpha1" integreatlyv1alpha1 "github.com/integr8ly/integreatly-operator/apis/v1alpha1" "github.com/integr8ly/integreatly-operator/pkg/resources" l "github.com/integr8ly/integre...
/* * Copyright 2019 ForgeRock AS * * 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 ...
/* Copyright 2018 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 ruler import ( "context" "errors" "time" "github.com/go-kit/kit/log" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/prometheus/notifier" "github.com/prometheus/prometheus/pkg/exemplar" "github.com/prometheus/prometheus/pkg/labels" "github.com/prometheus/prometheus/pkg/value" ...
package healthcheck import ( "context" "flag" "fmt" "net/http" "os" "os/signal" "sync" "syscall" "time" "github.com/buildbuddy-io/buildbuddy/server/interfaces" "github.com/buildbuddy-io/buildbuddy/server/util/log" "github.com/buildbuddy-io/buildbuddy/server/util/status" "golang.org/x/sync/errgroup" ) va...
// Copyright (c) 2017 Uber Technologies, 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 a...
// Package prime provides representations of classes of prime numbers. package prime import ( "fmt" "math/big" "github.com/mmcloughlin/addchain/internal/bigint" "github.com/mmcloughlin/addchain/internal/polynomial" ) // References: // // [crandallprime] <NAME>. Method and apparatus for public key exchange in a ...
package main import ( "bytes" "fmt" "github.com/gin-gonic/gin" "io" "io/ioutil" "mime/multipart" "net/http" "net/http/httptest" "os" "strings" "testing" "github.com/stretchr/testify/assert" ) const ( TempFile = "temp.txt" URL = "/files" ) // The function performs a test of the function makeDirIfNotExi...
/* Copyright 2020 The Nocalhost 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, soft...
package cmd import ( "bytes" "fmt" "io" "os" "strings" "text/template" "github.com/linkerd/linkerd2/cli/install" "github.com/linkerd/linkerd2/pkg/k8s" "github.com/linkerd/linkerd2/pkg/version" log "github.com/sirupsen/logrus" "github.com/spf13/cobra" ) type installCNIPluginConfig struct { Namespace ...
package luar import ( "fmt" "github.com/camsiabor/golua/lua" "path/filepath" "runtime" "strings" ) const LUA_PATH = "LUA_PATH" const LUA_CPATH = "LUA_CPATH" const LUA_PATH_ABS = "LUA_PATH_ABS" const LUA_CPATH_ABS = "LUA_CPATH_ABS" func GetLuaPath(luaPath, luaCPath string) (luaPathAbs, luaCPathAbs, luaPathFull, ...
package fragment import ( "bytes" "encoding/binary" "fmt" "io" "github.com/xackery/quail/common" "github.com/xackery/quail/dump" ) // SkeletonHierarchy information type SkeletonHierarchy struct { name string } func LoadSkeletonHierarchy(r io.ReadSeeker) (common.WldFragmenter, error) { v := &SkeletonHierarch...
package events import ( "encoding/json" "fmt" "os" "time" "github.com/containers/storage/pkg/stringid" "github.com/hpcloud/tail" "github.com/pkg/errors" ) // ErrNoJournaldLogging indicates that there is no journald logging // supported (requires libsystemd) var ErrNoJournaldLogging = errors.New("No support fo...
package utils_go import ( "crypto/rand" "fmt" "github.com/shopspring/decimal" "math/big" "reflect" "regexp" "strconv" "strings" "time" ) const ( Day = time.Hour * 24 DaySecond = Day / time.Second Month = Day * 30 MonthSecond = DaySecond * 30 Year ...
package fauth import ( "context" "errors" "github.com/lestrrat-go/jwx/jwk" "github.com/lestrrat-go/jwx/jwt" "strconv" "github.com/go-redis/redis/v8" "gitlab.duolainc.com/devops/fgo/client/fhttp" "gitlab.duolainc.com/devops/fgo/core/flog" "net/url" "path" "strings" "time" ) const PackageName = "client.fau...
//(yet another) simple utility to rebuild/reload your Go program when source changes // Copyright 2019 by <EMAIL> package main import ( "fmt" "github.com/radovskyb/watcher" "io" "io/ioutil" "os" "os/exec" "regexp" "strconv" "strings" "syscall" "time" ) var ( w *watcher.Watcher woff bool wbu...
// Copyright Chaos Mesh 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 w...
// +build go1.10 /* * * Copyright 2020 gRPC 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 appli...
// Copyright (c) 2020 Cisco and/or its affiliates. // // 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 app...
package logicad import ( "encoding/json" "fmt" "net/http" "github.com/mxmCherry/openrtb/v14/openrtb2" "github.com/prebid/prebid-server/adapters" "github.com/prebid/prebid-server/config" "github.com/prebid/prebid-server/errortypes" "github.com/prebid/prebid-server/openrtb_ext" ) type LogicadAdapter struct { ...
package version import ( "errors" "fmt" "time" "github.com/keptn/keptn/cli/pkg/logging" "github.com/keptn/keptn/cli/pkg/config" "github.com/hashicorp/go-version" ) type availableNewestVersions struct { stable newestVersions prerelease newestVersions } type newestVersions struct { // A version is comp...
package ui import ( "fmt" "github.com/Yeicor/sdfx-ui/internal" "github.com/cenkalti/backoff/v4" "github.com/hajimehoshi/ebiten" "io" "log" "net" "net/http" "net/rpc" "os" "os/exec" "os/signal" "strconv" "syscall" "time" ) const changeEventThrottle = 100 * time.Millisecond func (r *Renderer) runRendere...
// Copyright 2019 Yunion // // 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 writi...
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. package cloudfront import ( "context" "github.com/aws/aws-sdk-go-v2/aws" "github.com/aws/aws-sdk-go-v2/internal/awsutil" "github.com/aws/aws-sdk-go-v2/private/protocol" "github.com/aws/aws-sdk-go-v2/private/protocol/restxml" ) // This action ...
// Package conn holds a streaming ingest connetion. package conn import ( "bytes" "context" "fmt" "io/ioutil" "net/http" "net/url" "path" "regexp" "strings" "sync" "github.com/Azure/azure-kusto-go/kusto" "github.com/Azure/azure-kusto-go/kusto/data/errors" "github.com/Azure/azure-kusto-go/kusto/ingest/int...
package main import ( "errors" "fmt" "image" "io" "os" "github.com/as/a/dump" "github.com/as/ui/col" "github.com/as/ui/tag" ) var ErrBadDump = errors.New("bad dump file") func Load(g *Grid, file string) (e error) { defer func() { dump.Printf("load: err: %v", e) }() fd, err := os.Open(file) if err != ...
package main import ( "github.com/gregjones/httpcache" "github.com/gregjones/httpcache/diskcache" "github.com/spf13/viper" "github.com/tedpearson/weather2influxdb/http" "github.com/tedpearson/weather2influxdb/influx" "github.com/tedpearson/weather2influxdb/source" "github.com/tedpearson/weather2influxdb/weather...
// 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 ...
package controllers import ( "context" "fmt" _ "github.com/StephanHCB/go-autumn-logging-rlog" generatorgit "github.com/StephanHCB/go-generator-git" "github.com/go-logr/logr" "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" "k8s.io/apimachinery/pkg/runtime" ctrl "sigs.k8s.io/controller-run...
/* This is the smtpd daemon launcher ./smtpd -config=etc/smtpd.conf -logfile=smtpd.log & */ package main import ( "flag" "fmt" golog "log" "os" "os/signal" "runtime" "syscall" "time" "github.com/shidec/smtpd/config" "github.com/shidec/smtpd/data" "github.com/shidec/smtpd/log" "github....
package main import ( "./feiwu" "./model" "./webserver" "encoding/binary" "fmt" "log" "net" "os" "os/signal" "strings" "syscall" "time" ) const ( RED = "\x1b[31;1m" GREEN = "\x1b[32;1m" YELLOW = "\x1b[33;1m" ) func listNetworkInterfaces() { interfaces, err := net.Interfaces() if err != nil { f...
package game import ( "image/color" "math/rand" "time" "github.com/oakmound/lowrez17/game/menu" "github.com/oakmound/lowrez17/game/sfx" "github.com/oakmound/oak" "github.com/oakmound/oak/physics" "github.com/oakmound/oak/render" "github.com/oakmound/oak/render/mod" ) type Body struct { overlay ...
// Copyright 2016-2018, Pulumi 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 main import ( "log" "os" "time" "github.com/influxdata/influxdb/client/v2" "github.com/ivopetiz/go-binance/binance" "github.com/jyap808/go-bittrex" "github.com/jyap808/go-cryptopia" "github.com/jyap808/go-poloniex" "github.com/shopspring/decimal" ) func decimalToFloat(val decimal.Decimal) float64 { ...
// Copyright 2017 <NAME>. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. // Test concurrency primitives: power series. package ps // =========================================================================== // Specific power series /* -...
package transaction import ( "github.com/nicolaferraro/datamesh/context/projection" "github.com/nicolaferraro/datamesh/protobuf" "errors" "github.com/nicolaferraro/datamesh/common" "github.com/nicolaferraro/datamesh/notification" "github.com/golang/glog" "context" "time" ) const ( MaxTransactionShift = 50 M...
// The MIT License // // Copyright (c) 2020 Temporal Technologies Inc. All rights reserved. // // Copyright (c) 2020 Uber Technologies, Inc. // // 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 Soft...
/* SPDX-License-Identifier: Apache-2.0 Copyright Contributors to the Submariner project. 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 requ...
/* * Copyright (C) 2018 The ontology Authors * This file is part of The ontology library. * * The ontology is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (a...
// Code generated by smithy-go-codegen DO NOT EDIT. package glacier import ( "context" awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" "github.com/aws/aws-sdk-go-v2/aws/signer/v4" glaciercust "github.com/aws/aws-sdk-go-v2/service/glacier/internal/customizations" smithy "github.com/awslabs/smithy-go" ...
package local import ( "context" "fmt" "log" "os" "strings" "github.com/hashicorp/errwrap" "github.com/hashicorp/go-multierror" "github.com/hashicorp/terraform/backend" "github.com/hashicorp/terraform/command/format" clistate "github.com/hashicorp/terraform/command/state" "github.com/hashicorp/terraform/co...
package jenkins import ( "encoding/json" "fmt" "io/ioutil" "sort" "strings" "unicode/utf8" "github.com/jenkins-x/jx/pkg/log" "github.com/jenkins-x/jx/pkg/util" "github.com/pkg/errors" ) const ( // DefaultUpdateCenterURL the LTS update center metadata URL DefaultUpdateCenterURL = "https://updates.jenkins.i...
// Copyright © 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 wri...
package errbox import ( "fmt" "path/filepath" "runtime" "strings" ) // StackErr is an error with stack trace. type StackErr struct { cause error // the original error annotation []stackAnnotation // annotation of the error fields map[string]interface{} // optional fields attached...
// Copyright (c) 2017 Western Digital Corporation or its affiliates. All rights reserved. // SPDX-License-Identifier: MIT package curator import ( "testing" "github.com/westerndigitalcorporation/blb/pkg/testutil" "github.com/westerndigitalcorporation/blb/internal/core" "github.com/westerndigitalcorporation/blb/...
package camera import ( "bytes" "github.com/centretown/tiny-fabb/forms" "github.com/golang/glog" "github.com/mattn/go-mjpeg" "gocv.io/x/gocv" ) type LocalSettings struct { FrameWidth float64 `json:"frameWidth"` FrameHeight float64 `json:"frameHeight"` FrameRate float64 `json:"framerate"` Format ...
package generator import ( "bytes" "github.com/qichengzx/gopress/config" "html/template" "math" "os" "path/filepath" "strconv" "time" ) type PageNav struct { PageCount int PageSlice []int } // TODO need a better way to handle pagnition func (pn *PageNav) Handler() *PageNav { page := make([]int, pn.PageCou...
package run import ( "bytes" "context" "errors" "fmt" "io" "io/ioutil" "os" "os/exec" "path/filepath" "regexp" "time" "github.com/hashicorp/terraform-exec/tfexec" "github.com/utilitywarehouse/terraform-applier/log" "github.com/utilitywarehouse/terraform-applier/metrics" "github.com/utilitywarehouse/ter...
package github import ( "context" "fmt" "log" "os" "strconv" "time" "gopkg.in/src-d/go-billy.v4/memfs" "github.com/google/go-github/github" "golang.org/x/oauth2" "gopkg.in/src-d/go-git.v4" "gopkg.in/src-d/go-git.v4/config" "gopkg.in/src-d/go-git.v4/plumbing" "gopkg.in/src-d/go-git.v4/plumbing/object" ...
/* Copyright (c) 2019 Red Hat, 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, software...
// Copyright (c) 2017-2018 Zededa, Inc. // SPDX-License-Identifier: Apache-2.0 package baseosmgr import ( "fmt" "time" "github.com/lf-edge/eve/pkg/pillar/types" uuid "github.com/satori/go.uuid" ) // Really a constant var nilUUID uuid.UUID func checkContentTreeStatus(ctx *baseOsMgrContext, baseOsUUID uuid.UUID...
//Package whatsapp provides a developer API to interact with the WhatsAppWeb-Servers. package whatsapp import ( "fmt" "net/http" "net/url" "sync" "time" "github.com/gorilla/websocket" log "maunium.net/go/maulogger/v2" ) type metric byte const ( debugLog metric = iota + 1 queryResume queryReceipt queryMed...
// Copyright 2017 The Cockroach Authors. // // Use of this software is governed by the Business Source License // included in the file licenses/BSL.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 Apache License, ...
/* Copyright (C) 2021 Accurics, 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 wr...
package main import ( "context" "flag" stdlog "log" "os" "strconv" "github.com/PacktPublishing/Go-for-DevOps/chapter/11/petstore/internal/server" "github.com/PacktPublishing/Go-for-DevOps/chapter/11/petstore/internal/server/log" "github.com/PacktPublishing/Go-for-DevOps/chapter/11/petstore/internal/server/sto...
package models import ( "strconv" "time" "github.com/beego/beego/v2/adapter/logs" _ "github.com/beego/beego/v2/adapter/orm" types "github.com/yinrenxin/hgoj/models/types" "github.com/yinrenxin/hgoj/syserror" ) type Problem struct { ProblemId int32 `orm:"auto"` Title string `orm:"size(200);"`...
//: ---------------------------------------------------------------------------- //: Copyright (C) 2017 Verizon. All Rights Reserved. //: All Rights Reserved //: //: file: memcache.go //: details: handles template caching in memory with sharding feature //: author: <NAME> //: date: 02/01/2017 //: //: Licensed u...
package parse import ( "fmt" "go/ast" "go/parser" "go/token" "log" "strings" "unicode" _ "code.google.com/p/go.tools/go/gcimporter" "code.google.com/p/go.tools/go/types" ) type Function struct { Name string Params []Param IsError bool Comment string } type Param struct { Name string Type ...
//implementation of tf-idf (term frequency–inverse document frequency) ranking // // <wikipedia> term frequency–inverse document frequency, is a numerical statistic that is intended to reflect how important a word is to a document // in a collection or corpus.[1]:8 It is often used as a weighting factor in information...
/* * This file is part of the KubeVirt project * * 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 la...
/* 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, ...
/* * Copyright 2021 Comcast Cable Communications Management, LLC * * 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...
// Copyright 2020 <NAME>.A.S. Atos Technologies - Bull, R<NAME> Jaures, B.P.68, 78340, Les Clayes-sous-Bois, France. // // 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....