Skip to content

Commit

Permalink
Automator: update common-files@master in istio/proxy@master (#4219)
Browse files Browse the repository at this point in the history
  • Loading branch information
istio-testing authored Nov 17, 2022
1 parent 71853d5 commit f32ad5f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion common/.commonfiles.sha
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7daae52a89ec997031e2701ed907a04248fc3f63
1390d51f762f8626a582b524fcaec400484f0f90
4 changes: 2 additions & 2 deletions common/Makefile.common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ lint-helm:
@${FINDFILES} -name 'Chart.yaml' -print0 | ${XARGS} -L 1 dirname | xargs -r helm lint --strict

lint-copyright-banner:
@${FINDFILES} \( -name '*.go' -o -name '*.cc' -o -name '*.h' -o -name '*.proto' -o -name '*.py' -o -name '*.sh' \) \( ! \( -name '*.gen.go' -o -name '*.pb.go' -o -name '*_pb2.py' \) \) -print0 |\
@${FINDFILES} \( -name '*.go' -o -name '*.cc' -o -name '*.h' -o -name '*.proto' -o -name '*.py' -o -name '*.sh' -o -name '*.rs' \) \( ! \( -name '*.gen.go' -o -name '*.pb.go' -o -name '*_pb2.py' \) \) -print0 |\
${XARGS} common/scripts/lint_copyright_banner.sh

fix-copyright-banner:
@${FINDFILES} \( -name '*.go' -o -name '*.cc' -o -name '*.h' -o -name '*.proto' -o -name '*.py' -o -name '*.sh' \) \( ! \( -name '*.gen.go' -o -name '*.pb.go' -o -name '*_pb2.py' \) \) -print0 |\
@${FINDFILES} \( -name '*.go' -o -name '*.cc' -o -name '*.h' -o -name '*.proto' -o -name '*.py' -o -name '*.sh' -o -name '*.rs' \) \( ! \( -name '*.gen.go' -o -name '*.pb.go' -o -name '*_pb2.py' \) \) -print0 |\
${XARGS} common/scripts/fix_copyright_banner.sh

lint-go:
Expand Down
2 changes: 1 addition & 1 deletion common/scripts/fix_copyright_banner.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ WD=$(cd "$WD"; pwd)

for fn in "$@"; do
if ! grep -L -q -e "Apache License, Version 2" -e "Copyright" "${fn}"; then
if [[ "${fn}" == *.go ]]; then
if [[ "${fn}" == *.go || "${fn}" == *.rs ]]; then
newfile=$(cat "${WD}/copyright-banner-go.txt" "${fn}")
echo "${newfile}" > "${fn}"
echo "Fixing license: ${fn}"
Expand Down

0 comments on commit f32ad5f

Please sign in to comment.