diff options
author | Nick Mathewson <nickm@torproject.org> | 2021-05-28 08:02:08 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2021-05-28 08:02:08 -0400 |
commit | 8b6e919086ad6dde681516fe52d744afa3ffcc89 (patch) | |
tree | d934a291eb6a8bca055a22695fcc984fd5b896d4 /scripts | |
parent | 4a7379b80a3d0f61d258b26f82d894da9b8cd0f5 (diff) | |
download | tor-8b6e919086ad6dde681516fe52d744afa3ffcc89.tar.gz tor-8b6e919086ad6dde681516fe52d744afa3ffcc89.zip |
Stop using the "x$FOO" idiom in git-resquash.sh
The new version of shellcheck says that that this idiom is
unnecessary, and its presence here is making the shellcheck tests
fail.
No changes file needed, since this is not user-facing code.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/git/git-resquash.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/git/git-resquash.sh b/scripts/git/git-resquash.sh index e0f26ecdc4..f37950c9b0 100755 --- a/scripts/git/git-resquash.sh +++ b/scripts/git/git-resquash.sh @@ -7,7 +7,7 @@ set -e PARENT="$1" -if test "x$PARENT" = "x"; then +if test "$PARENT" = ""; then echo "You must specify the parent branch." exit 1 fi @@ -32,12 +32,12 @@ else USE_KEEP_BASE=1 fi -if test "x$USE_KEEP_BASE" = "x1" ; then +if test "$USE_KEEP_BASE" = "1" ; then exec git rebase -i --autosquash --keep-base "${PARENT}" else REV=$(git log --reverse --format='%H' "${PARENT}..HEAD" | head -1) - if test "x${REV}" = "x"; then + if test "${REV}" = ""; then echo "No changes here since ${PARENT}" exit 1 fi |