mirror of
https://github.com/moby/moby.git
synced 2026-01-11 02:31:44 +00:00
hack/validate: only search repo-dir for modules
Minor enhancement / follow-up to c8aaeea285c63f9add09e01bd8260d1bce61a97d; make sure we never attempt to find `go.mod` files in other locations. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -16,7 +16,7 @@ if pkg-config 'libsystemd' 2> /dev/null; then
|
||||
fi
|
||||
|
||||
# Note: exclude github.com/docker/docker/man as it contains no Go code.
|
||||
mods=($(find . -name "go.mod" -type f -exec dirname {} \; | grep -v "man" | sort -u))
|
||||
mods=($(find "${REPODIR}" -name "go.mod" -type f -exec dirname {} \; | grep -v "/man" | sort -u))
|
||||
for mod in "${mods[@]}"; do
|
||||
pushd "${mod}" > /dev/null
|
||||
echo -e "\n\033[0;36mINFO\033[0m Start validation for module '${mod}' with golang-ci-lint"
|
||||
|
||||
Reference in New Issue
Block a user