Skip to content

Commit

Permalink
all: replace import path to 'github.com/google/gnostic'
Browse files Browse the repository at this point in the history
Signed-off-by: Koichi Shiraishi <[email protected]>
  • Loading branch information
zchee committed Sep 26, 2021
1 parent 22cc4cb commit 05ffbf4
Show file tree
Hide file tree
Showing 62 changed files with 121 additions and 121 deletions.
4 changes: 2 additions & 2 deletions apps/disco/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ import (

"github.com/docopt/docopt-go"
"github.com/golang/protobuf/proto"
"github.com/googleapis/gnostic/conversions"
discovery "github.com/googleapis/gnostic/discovery"
"github.com/google/gnostic/conversions"
discovery "github.com/google/gnostic/discovery"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion apps/parse-linter-output/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"os"

lint "github.com/googleapis/gnostic/metrics/lint"
lint "github.com/google/gnostic/metrics/lint"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion apps/petstore-builder/petstore-v2.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
package main

import (
v2 "github.com/googleapis/gnostic/openapiv2"
v2 "github.com/google/gnostic/openapiv2"
)

func buildDocumentV2() *v2.Document {
Expand Down
2 changes: 1 addition & 1 deletion apps/petstore-builder/petstore-v3.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
package main

import (
v3 "github.com/googleapis/gnostic/openapiv3"
v3 "github.com/google/gnostic/openapiv3"
)

func buildDocumentV3() *v3.Document {
Expand Down
2 changes: 1 addition & 1 deletion apps/protoc-gen-openapi/generator/openapi-v3.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"sort"
"strings"

v3 "github.com/googleapis/gnostic/openapiv3"
v3 "github.com/google/gnostic/openapiv3"
"google.golang.org/genproto/googleapis/api/annotations"
"google.golang.org/protobuf/compiler/protogen"
"google.golang.org/protobuf/proto"
Expand Down
2 changes: 1 addition & 1 deletion apps/protoc-gen-openapi/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
package main

import (
"github.com/googleapis/gnostic/apps/protoc-gen-openapi/generator"
"github.com/google/gnostic/apps/protoc-gen-openapi/generator"
"google.golang.org/protobuf/compiler/protogen"
)

Expand Down
4 changes: 2 additions & 2 deletions apps/report-messages/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ import (
"os"

"github.com/golang/protobuf/proto"
"github.com/googleapis/gnostic/printer"
"github.com/google/gnostic/printer"

plugins "github.com/googleapis/gnostic/plugins"
plugins "github.com/google/gnostic/plugins"
)

func readMessagesFromFileWithName(filename string) *plugins.Messages {
Expand Down
4 changes: 2 additions & 2 deletions apps/report/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ import (
"os"

"github.com/golang/protobuf/proto"
"github.com/googleapis/gnostic/printer"
"github.com/google/gnostic/printer"

pb "github.com/googleapis/gnostic/openapiv2"
pb "github.com/google/gnostic/openapiv2"
)

func readDocumentFromFileWithName(filename string) (*pb.Document, error) {
Expand Down
4 changes: 2 additions & 2 deletions apps/vocabulary-operations/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ import (
"strings"

"github.com/golang/protobuf/proto"
metrics "github.com/googleapis/gnostic/metrics"
vocabulary "github.com/googleapis/gnostic/metrics/vocabulary"
metrics "github.com/google/gnostic/metrics"
vocabulary "github.com/google/gnostic/metrics/vocabulary"
)

// openVocabularyFiles uses standard input to create a slice of
Expand Down
2 changes: 1 addition & 1 deletion compiler/extensions.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (

"github.com/golang/protobuf/proto"
"github.com/golang/protobuf/ptypes/any"
extensions "github.com/googleapis/gnostic/extensions"
extensions "github.com/google/gnostic/extensions"
yaml "gopkg.in/yaml.v3"
)

Expand Down
2 changes: 1 addition & 1 deletion compiler/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"sort"
"strconv"

"github.com/googleapis/gnostic/jsonschema"
"github.com/google/gnostic/jsonschema"
"gopkg.in/yaml.v3"
)

Expand Down
4 changes: 2 additions & 2 deletions conversions/openapiv2.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ import (
"log"
"net/url"

openapi2 "github.com/googleapis/gnostic/openapiv2"
discovery "github.com/googleapis/gnostic/discovery"
openapi2 "github.com/google/gnostic/openapiv2"
discovery "github.com/google/gnostic/discovery"
)

func addOpenAPI2SchemaForSchema(d *openapi2.Document, name string, schema *discovery.Schema) {
Expand Down
4 changes: 2 additions & 2 deletions conversions/openapiv3.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
"net/url"
"strings"

openapi3 "github.com/googleapis/gnostic/openapiv3"
discovery "github.com/googleapis/gnostic/discovery"
openapi3 "github.com/google/gnostic/openapiv3"
discovery "github.com/google/gnostic/discovery"
)

func pathForMethod(path string) string {
Expand Down
2 changes: 1 addition & 1 deletion discovery/discovery.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package discovery_v1

import (
"fmt"
"github.com/googleapis/gnostic/compiler"
"github.com/google/gnostic/compiler"
"gopkg.in/yaml.v3"
"regexp"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion discovery/document.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
package discovery_v1

import (
"github.com/googleapis/gnostic/compiler"
"github.com/google/gnostic/compiler"
)

// FetchDocumentBytes downloads the bytes of a discovery document from a URL.
Expand Down
2 changes: 1 addition & 1 deletion discovery/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
"errors"
"strings"

"github.com/googleapis/gnostic/compiler"
"github.com/google/gnostic/compiler"
)

// APIsListServiceURL is the URL for the Google APIs Discovery Service
Expand Down
2 changes: 1 addition & 1 deletion generate-gnostic/domain.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"sort"
"strings"

"github.com/googleapis/gnostic/jsonschema"
"github.com/google/gnostic/jsonschema"
)

// Domain models a collection of types that is defined by a schema.
Expand Down
2 changes: 1 addition & 1 deletion generate-gnostic/generate-compiler.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"sort"
"strings"

"github.com/googleapis/gnostic/printer"
"github.com/google/gnostic/printer"
)

// patternNames hands out unique names for a given string.
Expand Down
14 changes: 7 additions & 7 deletions generate-gnostic/generate-extension.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ import (
"sort"
"strings"

"github.com/googleapis/gnostic/compiler"
"github.com/googleapis/gnostic/jsonschema"
"github.com/googleapis/gnostic/printer"
"github.com/google/gnostic/compiler"
"github.com/google/gnostic/jsonschema"
"github.com/google/gnostic/printer"
)

var protoOptionsForExtensions = []ProtoOption{
Expand Down Expand Up @@ -272,7 +272,7 @@ func generateExtension(schemaFile string, outDir string) error {
"fmt",
"regexp",
"strings",
"github.com/googleapis/gnostic/compiler",
"github.com/google/gnostic/compiler",
"gopkg.in/yaml.v3",
})
goFilename := path.Join(protoOutDirectory, outFileBaseName+".go")
Expand All @@ -287,7 +287,7 @@ func generateExtension(schemaFile string, outDir string) error {
// TODO: This path is currently fixed to the location of the samples.
// Can we make it relative, perhaps with an option or by generating
// a go.mod file for the generated extension handler?
outDirRelativeToPackageRoot := "github.com/googleapis/gnostic/extensions/sample/" + outDir
outDirRelativeToPackageRoot := "github.com/google/gnostic/extensions/sample/" + outDir

var extensionNameKeys []string
for k := range extensionNameToMessageName {
Expand Down Expand Up @@ -315,8 +315,8 @@ func generateExtension(schemaFile string, outDir string) error {
extMainCode := fmt.Sprintf(additionalCompilerCodeWithMain, cases)
imports := []string{
"github.com/golang/protobuf/proto",
"github.com/googleapis/gnostic/extensions",
"github.com/googleapis/gnostic/compiler",
"github.com/google/gnostic/extensions",
"github.com/google/gnostic/compiler",
"gopkg.in/yaml.v3",
outDirRelativeToPackageRoot + "/" + "proto",
}
Expand Down
2 changes: 1 addition & 1 deletion generate-gnostic/generate-proto.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"fmt"
"strings"

"github.com/googleapis/gnostic/printer"
"github.com/google/gnostic/printer"
)

// ProtoOption represents an option to be added to generated .proto files.
Expand Down
4 changes: 2 additions & 2 deletions generate-gnostic/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (
"runtime"
"strings"

"github.com/googleapis/gnostic/jsonschema"
"github.com/google/gnostic/jsonschema"
)

// License is the software license applied to generated code.
Expand Down Expand Up @@ -193,7 +193,7 @@ func generateOpenAPIModel(version string) error {
"gopkg.in/yaml.v3",
"strings",
"regexp",
"github.com/googleapis/gnostic/compiler",
"github.com/google/gnostic/compiler",
}
// generate the compiler
log.Printf("Generating compiler support code")
Expand Down
2 changes: 1 addition & 1 deletion generate-gnostic/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"fmt"
"strings"

"github.com/googleapis/gnostic/jsonschema"
"github.com/google/gnostic/jsonschema"
)

/// Type Modeling
Expand Down
2 changes: 1 addition & 1 deletion gnostic.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import (
"fmt"
"os"

"github.com/googleapis/gnostic/lib"
"github.com/google/gnostic/lib"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion gnostic_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"strings"
"testing"

"github.com/googleapis/gnostic/lib"
"github.com/google/gnostic/lib"
)

func isURL(path string) bool {
Expand Down
4 changes: 2 additions & 2 deletions jsonwriter/writer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ package jsonwriter_test
import (
"testing"

"github.com/googleapis/gnostic/compiler"
"github.com/googleapis/gnostic/jsonwriter"
"github.com/google/gnostic/compiler"
"github.com/google/gnostic/jsonwriter"

"gopkg.in/yaml.v3"
)
Expand Down
14 changes: 7 additions & 7 deletions lib/gnostic.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ import (
"time"

"github.com/golang/protobuf/proto"
"github.com/googleapis/gnostic/compiler"
discovery_v1 "github.com/googleapis/gnostic/discovery"
"github.com/googleapis/gnostic/jsonwriter"
openapi_v2 "github.com/googleapis/gnostic/openapiv2"
openapi_v3 "github.com/googleapis/gnostic/openapiv3"
plugins "github.com/googleapis/gnostic/plugins"
surface "github.com/googleapis/gnostic/surface"
"github.com/google/gnostic/compiler"
discovery_v1 "github.com/google/gnostic/discovery"
"github.com/google/gnostic/jsonwriter"
openapi_v2 "github.com/google/gnostic/openapiv2"
openapi_v3 "github.com/google/gnostic/openapiv3"
plugins "github.com/google/gnostic/plugins"
surface "github.com/google/gnostic/surface"
"gopkg.in/yaml.v3"
)

Expand Down
4 changes: 2 additions & 2 deletions linters/go/gnostic-lint-descriptions/linter_v2.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
package main

import (
openapi "github.com/googleapis/gnostic/openapiv2"
plugins "github.com/googleapis/gnostic/plugins"
openapi "github.com/google/gnostic/openapiv2"
plugins "github.com/google/gnostic/plugins"
)

// DocumentLinter contains information collected about an API description.
Expand Down
4 changes: 2 additions & 2 deletions linters/go/gnostic-lint-descriptions/linter_v3.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
package main

import (
openapi "github.com/googleapis/gnostic/openapiv3"
plugins "github.com/googleapis/gnostic/plugins"
openapi "github.com/google/gnostic/openapiv3"
plugins "github.com/google/gnostic/plugins"
)

// DocumentLinter contains information collected about an API description.
Expand Down
6 changes: 3 additions & 3 deletions linters/go/gnostic-lint-descriptions/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ package main

import (
"github.com/golang/protobuf/proto"
openapiv2 "github.com/googleapis/gnostic/openapiv2"
openapiv3 "github.com/googleapis/gnostic/openapiv3"
plugins "github.com/googleapis/gnostic/plugins"
openapiv2 "github.com/google/gnostic/openapiv2"
openapiv3 "github.com/google/gnostic/openapiv3"
plugins "github.com/google/gnostic/plugins"
)

type DocumentLinter interface {
Expand Down
6 changes: 3 additions & 3 deletions linters/go/gnostic-lint-paths/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ package main

import (
"github.com/golang/protobuf/proto"
openapiv2 "github.com/googleapis/gnostic/openapiv2"
openapiv3 "github.com/googleapis/gnostic/openapiv3"
plugins "github.com/googleapis/gnostic/plugins"
openapiv2 "github.com/google/gnostic/openapiv2"
openapiv3 "github.com/google/gnostic/openapiv3"
plugins "github.com/google/gnostic/plugins"
)

func checkPathsV2(document *openapiv2.Document, messages []*plugins.Message) []*plugins.Message {
Expand Down
4 changes: 2 additions & 2 deletions metrics/lint/aip-linterv2.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ package linter
import (
"fmt"

rules "github.com/googleapis/gnostic/metrics/rules"
pb "github.com/googleapis/gnostic/openapiv2"
rules "github.com/google/gnostic/metrics/rules"
pb "github.com/google/gnostic/openapiv2"
)

// fillProtoStructure takes a slice of rules and coverts them to a slice of
Expand Down
4 changes: 2 additions & 2 deletions metrics/lint/aip-linterv3.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ import (
"fmt"
"os"

rules "github.com/googleapis/gnostic/metrics/rules"
openapi_v3 "github.com/googleapis/gnostic/openapiv3"
rules "github.com/google/gnostic/metrics/rules"
openapi_v3 "github.com/google/gnostic/openapiv3"
)

// processParametersV2 loops over the parameters of component and creates a
Expand Down
2 changes: 1 addition & 1 deletion metrics/vocabulary/difference.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
package vocabulary

import (
metrics "github.com/googleapis/gnostic/metrics"
metrics "github.com/google/gnostic/metrics"
)

// mapDifference finds the difference between two Vocabularies.
Expand Down
4 changes: 2 additions & 2 deletions metrics/vocabulary/discovery.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
package vocabulary

import (
discovery_v1 "github.com/googleapis/gnostic/discovery"
metrics "github.com/googleapis/gnostic/metrics"
discovery_v1 "github.com/google/gnostic/discovery"
metrics "github.com/google/gnostic/metrics"
)

func (vocab *Vocabulary) processMethodDiscovery(operation *discovery_v1.Method) {
Expand Down
Loading

0 comments on commit 05ffbf4

Please sign in to comment.