소스 검색

run_trunnel.sh: Use 'find -exec' instead of a 'for' loop

This fixes shellcheck warnings SC2044 and SC2006.
rl1987 6 년 전
부모
커밋
a0dd6bfdb0
1개의 변경된 파일1개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 3
      scripts/codegen/run_trunnel.sh

+ 1 - 3
scripts/codegen/run_trunnel.sh

@@ -9,9 +9,7 @@ OPTIONS="--require-version=1.5.1"
 
 # Get all .trunnel files recursively from that directory so we can support
 # multiple sub-directories.
-for file in `find ./src/trunnel/ -name '*.trunnel'`; do
-  python -m trunnel ${OPTIONS} "$file"
-done
+find ./src/trunnel/ -name '*.trunnel' -exec python -m trunnel ${OPTIONS} {} \;
 
 python -m trunnel ${OPTIONS} --write-c-files --target-dir=./src/ext/trunnel/