Skip to content

Commit

Permalink
remove vendoring, use Go modules by default
Browse files Browse the repository at this point in the history
Removes the vendor/ directory and all vestiges of life before Go modules.

Issue k8snetworkplumbingwg#544

Signed-off-by: Jay Pipes <[email protected]>
  • Loading branch information
jaypipes committed Apr 7, 2024
1 parent e6ead1e commit 999ef39
Show file tree
Hide file tree
Showing 3,774 changed files with 5 additions and 1,406,770 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
1 change: 0 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
run:
timeout: 3m
skip-dirs:
- vendor/
- .github/
- deployments/
- docs/
Expand Down
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ ORG_PATH=github.com/k8snetworkplumbingwg
BUILDDIR=$(CURDIR)/build
REPO_PATH=$(ORG_PATH)/$(PACKAGE)
BASE=$(GOPATH)/src/$(REPO_PATH)
PKGS = $(or $(PKG),$(shell cd $(BASE) && env GOPATH=$(GOPATH) go list ./... | grep -v "^$(PACKAGE)/vendor/"))
GOFILES = $(shell find . -name *.go | grep -vE "(\/vendor\/)|(_test.go)")
PKGS = $(or $(PKG),$(shell cd $(BASE) && env GOPATH=$(GOPATH) go list ./...))
GOFILES = $(shell find . -name *.go | grep -v "_test.go")
# Test artifacts and settings
TESTPKGS = $(shell env GOPATH=$(GOPATH) go list -f '{{ if or .TestGoFiles .XTestGoFiles }}{{ .ImportPath }}{{ end }}' $(PKGS))
TIMEOUT = 15
Expand Down Expand Up @@ -117,7 +117,7 @@ test-coverage: fmt lint test-coverage-tools | $(BASE) ; $(info Running coverage
$Q cd $(BASE) && for pkg in $(TESTPKGS); do \
go test \
-coverpkg=$$(go list -f '{{ join .Deps "\n" }}' $$pkg | \
grep '^$(PACKAGE)/' | grep -v '^$(PACKAGE)/vendor/' | \
grep '^$(PACKAGE)/' | \
tr '\n' ',')$$pkg \
-covermode=$(COVERAGE_MODE) \
-coverprofile="$(COVERAGE_DIR)/coverage/`echo $$pkg | tr "/" "-"`.cover" $$pkg ;\
Expand All @@ -135,13 +135,13 @@ lint: | $(BASE) $(GOLINT) ; $(info Running golint...) @ ## Run golint on all so

.PHONY: fmt
fmt: ; $(info running gofmt...) @ ## Run gofmt on all source files
@ret=0 && for d in $$(go list -f '{{.Dir}}' ./... | grep -v /vendor/); do \
@ret=0 && for d in $$(go list -f '{{.Dir}}' ./...); do \
gofmt -l -w $$d/*.go || ret=$$? ; \
done ; exit $$ret

.PHONY: deps-update
deps-update: ; $(info Updating dependencies...) @ ## Update dependencies
@go mod tidy && go mod vendor
@go mod tidy

.PHONY: image
image: | $(BASE) ; $(info Building Docker image...) @ ## Build SR-IOV Network device plugin docker image
Expand Down
2 changes: 0 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -79,5 +79,3 @@ require (
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)

replace github.com/gogo/protobuf => github.com/gogo/protobuf v1.3.2
102 changes: 0 additions & 102 deletions vendor/github.com/Mellanox/rdmamap/.golangci.yml

This file was deleted.

12 changes: 0 additions & 12 deletions vendor/github.com/Mellanox/rdmamap/.travis.yml

This file was deleted.

201 changes: 0 additions & 201 deletions vendor/github.com/Mellanox/rdmamap/LICENSE

This file was deleted.

Loading

0 comments on commit 999ef39

Please sign in to comment.