File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -86,6 +86,10 @@ DOCKERFILE_FILES=()
8686while IFS= read -r -d ' ' file; do
8787 DOCKERFILE_FILES+=(" $file " )
8888done < <( find . -name ' Dockerfile*' -not -path ' ./pkg/go-containerregistry/*' -print0)
89+ WORKFLOW_FILES=()
90+ while IFS= read -r -d ' ' file; do
91+ WORKFLOW_FILES+=(" $file " )
92+ done < <( find .github/workflows -name ' *.yml' -print0 2> /dev/null || true)
8993
9094case " ${1:- } " in
9195 check)
@@ -108,6 +112,12 @@ case "${1:-}" in
108112 fi
109113 done
110114
115+ for workflow in " ${WORKFLOW_FILES[@]} " ; do
116+ if grep -q " go-version:" " $workflow " 2> /dev/null; then
117+ check_file " $workflow " " go-version: $GO_VERSION " " go-version:" " go-version: $GO_VERSION "
118+ fi
119+ done
120+
111121 if [[ " $NEEDS_UPDATE " -eq 1 ]]; then
112122 echo " "
113123 echo " Files are out of sync. Run: ./scripts/sync-go-version.sh sync"
@@ -133,6 +143,10 @@ case "${1:-}" in
133143 update_file " $dockerfile " " ARG GO_VERSION=.*" " ARG GO_VERSION=$GO_VERSION_MINOR "
134144 done
135145
146+ for workflow in " ${WORKFLOW_FILES[@]} " ; do
147+ update_file " $workflow " " go-version: .*" " go-version: $GO_VERSION "
148+ done
149+
136150 echo " "
137151 echo " Done. Review changes with: git diff"
138152 ;;
You can’t perform that action at this time.
0 commit comments