diff options
author | Dan Callahan <danc@element.io> | 2021-10-22 23:07:23 +0100 |
---|---|---|
committer | Dan Callahan <danc@element.io> | 2021-10-22 23:08:55 +0100 |
commit | d7141e0b8b945047b37b8ca093ed0bfd63724a25 (patch) | |
tree | aa05884eef374f88734a767287b6ffef4445fcb5 /scripts-dev/check-newsfragment | |
parent | Fix Shellcheck SC2129: Consider using {..} >> file (diff) | |
download | synapse-d7141e0b8b945047b37b8ca093ed0bfd63724a25.tar.xz |
Fix Shellcheck SC2006: Use $(...) notation
Use $(...) notation instead of legacy backticked `...`. https://github.com/koalaman/shellcheck/wiki/SC2006 Signed-off-by: Dan Callahan <danc@element.io>
Diffstat (limited to 'scripts-dev/check-newsfragment')
-rwxr-xr-x | scripts-dev/check-newsfragment | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts-dev/check-newsfragment b/scripts-dev/check-newsfragment index 5fc68e3213..af4de345df 100755 --- a/scripts-dev/check-newsfragment +++ b/scripts-dev/check-newsfragment @@ -42,9 +42,9 @@ echo "--------------------------" echo matched=0 -for f in `git diff --name-only FETCH_HEAD... -- changelog.d`; do +for f in $(git diff --name-only FETCH_HEAD... -- changelog.d); do # check that any modified newsfiles on this branch end with a full stop. - lastchar=`tr -d '\n' < "$f" | tail -c 1` + lastchar=$(tr -d '\n' < "$f" | tail -c 1) if [ "$lastchar" != '.' ] && [ "$lastchar" != '!' ]; then echo -e "\e[31mERROR: newsfragment $f does not end with a '.' or '!'\e[39m" >&2 echo -e "$CONTRIBUTING_GUIDE_TEXT" >&2 |