Skip to content

Commit

Permalink
remove vendoring, use Go modules
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/sriov-network-device-plugin#544

Signed-off-by: Jay Pipes <[email protected]>
  • Loading branch information
jaypipes committed May 25, 2024
1 parent 9f5c023 commit 8740dd3
Show file tree
Hide file tree
Showing 4,514 changed files with 1 addition and 1,512,162 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 0 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ jobs:

- name: Run Revive Action by pulling pre-built image
uses: docker://morphy/revive-action:v2
with:
exclude: "./vendor/..."

- name: Run go fmt
run: go fmt ./...
Expand Down
2 changes: 0 additions & 2 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# This is an example goreleaser.yaml file with some sane defaults.
# Make sure to check the documentation at http://goreleaser.com
env:
- GO111MODULE=on
before:
hooks:
- go mod download
Expand Down
1 change: 0 additions & 1 deletion cmd/multus-shim/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ import (
)

func main() {
// Init command line flags to clear vendored packages' one, especially in init()
flag.CommandLine = flag.NewFlagSet(os.Args[0], flag.ExitOnError)

// add version flag
Expand Down
2 changes: 0 additions & 2 deletions cmd/multus/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ import (
)

func main() {

// Init command line flags to clear vendored packages' one, especially in init()
flag.CommandLine = flag.NewFlagSet(os.Args[0], flag.ExitOnError)

// add version flag
Expand Down
21 changes: 1 addition & 20 deletions hack/test-go.sh
Original file line number Diff line number Diff line change
@@ -1,23 +1,4 @@
#!/usr/bin/env bash
set -e

# this if... will be removed when gomodules goes default
if [ "$GO111MODULE" == "off" ]; then
echo "Warning: this will be deprecated in near future so please use go modules!"

ORG_PATH="gopkg.in/k8snetworkplumbingwg"
REPO_PATH="${ORG_PATH}/multus-cni"

if [ ! -h gopath/src/${REPO_PATH} ]; then
mkdir -p gopath/src/${ORG_PATH}
ln -s ../../../.. gopath/src/${REPO_PATH} || exit 255
fi

export GO15VENDOREXPERIMENT=1
export GOBIN=${PWD}/bin
export GOPATH=${PWD}/gopath
bash -c "umask 0; cd ${GOPATH}/src/${REPO_PATH}; PATH=${GOROOT}/bin:$(pwd)/bin:${PATH} go test -v -covermode=count -coverprofile=coverage.out ./..."
else
# test with go modules
bash -c "umask 0; go test -v -race -covermode=atomic -coverprofile=coverage.out ./..."
fi
bash -c "umask 0; go test -v -race -covermode=atomic -coverprofile=coverage.out ./..."
1 change: 0 additions & 1 deletion images/Dockerfile.openshift
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ FROM local/okdbuilder:latest as builder
ADD . /usr/src/multus-cni

WORKDIR /usr/src/multus-cni
ENV GO111MODULE=off
RUN ./hack/build-go.sh

FROM quay.io/openshift/origin-base:latest
Expand Down
1 change: 0 additions & 1 deletion vendor/github.com/Masterminds/semver/v3/.gitignore

This file was deleted.

27 changes: 0 additions & 27 deletions vendor/github.com/Masterminds/semver/v3/.golangci.yml

This file was deleted.

214 changes: 0 additions & 214 deletions vendor/github.com/Masterminds/semver/v3/CHANGELOG.md

This file was deleted.

19 changes: 0 additions & 19 deletions vendor/github.com/Masterminds/semver/v3/LICENSE.txt

This file was deleted.

30 changes: 0 additions & 30 deletions vendor/github.com/Masterminds/semver/v3/Makefile

This file was deleted.

Loading

0 comments on commit 8740dd3

Please sign in to comment.