summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Pokorný <jpokorny@redhat.com>2012-03-12 10:50:09 +0100
committerJan Pokorný <jpokorny@redhat.com>2012-03-12 10:50:09 +0100
commit66dea6e8938baa42714d5e4e407e02f128ba5a24 (patch)
tree0a6c3a4f0c1dc80ee56495b2f2382f904e334084
parent2415c8a37d4a06ca7f474909d21313e20f22f67d (diff)
downloadwatch-bz-66dea6e8938baa42714d5e4e407e02f128ba5a24.tar.gz
watch-bz-66dea6e8938baa42714d5e4e407e02f128ba5a24.tar.xz
watch-bz-66dea6e8938baa42714d5e4e407e02f128ba5a24.zip
fix problem with dependency on CWD
Signed-off-by: Jan Pokorný <jpokorny@redhat.com>
-rwxr-xr-xwatch-bz6
1 files changed, 4 insertions, 2 deletions
diff --git a/watch-bz b/watch-bz
index 7aca6fa..39ab50b 100755
--- a/watch-bz
+++ b/watch-bz
@@ -1,5 +1,4 @@
#!/bin/bash
-
# jpokorny@redhat.com (will be pleased to know about further enhancements)
# usage:
@@ -11,6 +10,9 @@
# (or pass such string as a 1st argument)
# - optionally set BZUSER to avoid the need to login manually before
# the "watch session"; you can set BZPASSWORD as well but be careful!
+
+HERE=$(dirname $0)
+
BUGZILLA=$(which bugzilla 2>/dev/null)
# example defaults, modify via ~/.watchbzrc
@@ -86,6 +88,6 @@ watch -t --interval $REFRESH_INTERVAL \
-e \"s/requires_release_note/RN/\" \
-e \"s/rhel-//\" \
-e \"s/None//\" \
- | ./table-data $SEP | cut -c-$WIDTH"
+ | ${HERE}/table-data $SEP | cut -c-$WIDTH"
# todo: colours for priorities (rhbz#801626)
#-e 's/\(urgent\)/\^\[\[31m\1\^\[\[0m/' \