diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d5d5651ff..247dbe68b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -131,6 +131,10 @@ jobs: # ensure our vendor directory matches up with our go modules run: | go mod vendor && git diff --exit-code || (echo "Unexpected change to vendor directory. Run 'go mod vendor' locally and commit the changes" && exit 1) + - name: Check go.mod file + # ensure our go.mod file is clean + run: | + go mod tidy && git diff --exit-code || (echo "go.mod file is not clean. Run 'go mod tidy' locally and commit the changes" && exit 1) - name: Check All Auto-Generated Files # ensure all our auto-generated files are up to date run: | diff --git a/go.mod b/go.mod index b082b968b..2126b6ab3 100644 --- a/go.mod +++ b/go.mod @@ -26,7 +26,6 @@ require ( github.com/mattn/go-runewidth v0.0.15 github.com/mgutz/str v1.2.0 github.com/mitchellh/go-ps v1.0.0 - github.com/pmezard/go-difflib v1.0.0 github.com/sahilm/fuzzy v0.1.0 github.com/samber/lo v1.31.0 github.com/sanity-io/litter v1.5.2 @@ -63,6 +62,7 @@ require ( github.com/onsi/ginkgo v1.10.3 // indirect github.com/onsi/gomega v1.7.1 // indirect github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5 // indirect + github.com/pmezard/go-difflib v1.0.0 // indirect github.com/rivo/uniseg v0.4.4 // indirect github.com/sergi/go-diff v1.1.0 // indirect github.com/xanzy/ssh-agent v0.2.1 // indirect