aboutsummaryrefslogtreecommitdiffstats
path: root/tools/gen-bugnote
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2018-06-07 15:03:48 -0700
committerGerald Combs <gerald@wireshark.org>2018-06-11 16:35:08 +0000
commitbfb7028ba971deb2d3edf7f573b3183ef67ce5c2 (patch)
treeb845aff5f434f165205ad563678c573ccdf5bbd1 /tools/gen-bugnote
parent0e3901d82f31e46d4e21539c2b16b22c2e42f17e (diff)
More shellcheck fixes.
Change-Id: Iee9e464b3935d4c8a09fa9954f73496eae33f30f Reviewed-on: https://code.wireshark.org/review/28092 Reviewed-by: Gerald Combs <gerald@wireshark.org>
Diffstat (limited to 'tools/gen-bugnote')
-rwxr-xr-xtools/gen-bugnote8
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/gen-bugnote b/tools/gen-bugnote
index dc0a073b89..b39ba9195b 100755
--- a/tools/gen-bugnote
+++ b/tools/gen-bugnote
@@ -10,7 +10,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
#
-bz_url_pfx="https://bugs.wireshark.org/bugzilla/show_bug.cgi?id="
+bz_url_pfx="https://bugs.wireshark.org/bugzilla/show_bug.cgi"
bug_id="$1"
recode_cmd="cat"
@@ -33,12 +33,12 @@ case "$OSTYPE" in
esac
if [ -z "$bug_id" ] ; then
- echo "Usage: " `basename $0` " <bug id>"
+ echo "Usage: $( basename "$0" ) <bug id>"
exit 1
fi
bug_title=$(
- curl -s -o - "https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=$bug_id" \
+ curl -s -o - "${bz_url_pfx}?id=$bug_id" \
| grep -i '<title>' \
| sed \
-e 's/{/\\{/' \
@@ -48,7 +48,7 @@ bug_title=$(
-e 's/\\/{backslash}/' \
)
-echo -e "* $bug_title (wsbuglink:$bug_id[])\n" \
+echo -e "* $bug_title (wsbuglink:${bug_id}[])\\n" \
| $recode_cmd \
| $clipboard_cmd