[tor-commits] [tor/master] Fix shellcheck warnings in fixup_filenames.sh
nickm at torproject.org
nickm at torproject.org
Wed May 1 13:11:25 UTC 2019
commit 55b4f02ba6cbbd4cae942a9e84e48e237d8e38aa
Author: rl1987 <rl1987 at sdf.lonestar.org>
Date: Mon Apr 15 12:13:35 2019 +0300
Fix shellcheck warnings in fixup_filenames.sh
---
changes/ticket30078 | 3 +++
src/test/fuzz/fixup_filenames.sh | 6 +++---
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/changes/ticket30078 b/changes/ticket30078
new file mode 100644
index 000000000..5ab5abdbf
--- /dev/null
+++ b/changes/ticket30078
@@ -0,0 +1,3 @@
+ o Code simplification and refactoring (shell scripts):
+ - Fix shellcheck warnings in src/test/fuzz/fixup_filenames.sh. Resolves
+ issue 30078.
diff --git a/src/test/fuzz/fixup_filenames.sh b/src/test/fuzz/fixup_filenames.sh
index 68efc1abc..f730d532a 100755
--- a/src/test/fuzz/fixup_filenames.sh
+++ b/src/test/fuzz/fixup_filenames.sh
@@ -8,9 +8,9 @@ if [ ! -d "$1" ] ; then
fi
for fn in "$1"/* ; do
- prev=`basename "$fn"`
- post=`sha256sum "$fn" | sed -e 's/ .*//;'`
- if [ "$prev" == "$post" ] ; then
+ prev=$(basename "$fn")
+ post=$(sha256sum "$fn" | sed -e 's/ .*//;')
+ if [ "$prev" = "$post" ] ; then
echo "OK $prev"
else
echo "mv $prev $post"
More information about the tor-commits
mailing list