]> git.ozlabs.org Git - next-scripts/commitdiff
fix some shellcheck warnings
authorStephen Rothwell <sfr@canb.auug.org.au>
Thu, 24 Nov 2022 23:54:40 +0000 (10:54 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 24 Nov 2022 23:54:40 +0000 (10:54 +1100)
common.sh

index 53bcaa94bc18f02f9145cf207a2fe17c82d8be86..7529de3445b492866591cc75e129a92fa1bfbb9d 100644 (file)
--- a/common.sh
+++ b/common.sh
@@ -6,7 +6,7 @@
 [ "$_next_common_included" ] && return 0
 _next_common_included=1
 
-bin_dir=$(realpath $(dirname "$0"))
+bin_dir=$(realpath "$(dirname "$0")")
 top_dir=$(dirname "$bin_dir")
 
 [ "$LOG_FILE" ] || LOG_FILE="$top_dir/merge.log"
@@ -51,17 +51,17 @@ export NEXT_J_FACTOR="$j_factor"
 # Support functions
 get_contacts()
 {
-       awk -F '\t' '/^[^#]/ && $3=="'"$1"'" { print $1; }' $CTRL_FILE
+       awk -F '\t' '/^[^#]/ && $3=="'"$1"'" { print $1; }' #$CTRL_FILE"
 }
 
 get_url()
 {
-       awk -F '\t' '/^[^#]/ && $3=="'"$1"'" { print $4; }' $CTRL_FILE
+       awk -F '\t' '/^[^#]/ && $3=="'"$1"'" { print $4; }' #$CTRL_FILE"
 }
 
 get_build_flag()
 {
-       awk -F '\t' '/^[^#]/ && $3=="'"$1"'" { print $6; }' $CTRL_FILE
+       awk -F '\t' '/^[^#]/ && $3=="'"$1"'" { print $6; }' #$CTRL_FILE"
 }
 
 check_unmerged_files()
@@ -74,7 +74,7 @@ check_unmerged_files()
        if [ "$um_files" ] && [ -f "../merge-files/$tree" ]; then
                rm_files=$(grep -F "$um_files" "../merge-files/$tree")
                if [ "$rm_files" ]; then
-                       "$bin_dir/do_rm" $rm_files
+                       "$bin_dir/do_rm" "$rm_files"
                fi
        fi
 }