aboutsummaryrefslogtreecommitdiff
path: root/slack_last_update.sh
diff options
context:
space:
mode:
Diffstat (limited to 'slack_last_update.sh')
-rwxr-xr-xslack_last_update.sh15
1 files changed, 10 insertions, 5 deletions
diff --git a/slack_last_update.sh b/slack_last_update.sh
index 696bed5..1f04cb6 100755
--- a/slack_last_update.sh
+++ b/slack_last_update.sh
@@ -15,21 +15,26 @@
# it depends on what the error actually was.
# This script can be tested from the command line, but in production it
-# will be executed from an irssi script, which will use the exit status
-# to decide whether the channel /topic should be updated.
+# will be executed from an irssi script, so it's got no need for options
+# or verbose output. Actually, the irssi script currently doesn't even
+# look at the exit status (other than to check for an error), so even
+# that could be removed to simplify things.
# For the morbidly curious: I intend this to be executed by bash,
# but it also works with Slackware 14.2's ash and ksh, and dash from
-# SBo. But *not* zsh: somehow $RANGE gets expanded to a quoted string,
+# SBo. But *not* zsh: $RANGE gets expanded to a quoted string,
# so curl gets executed as:
# curl --silent '--range 0-28' http://...
# and quite properly complains:
# curl: option --range 0-28: is unknown
-# I'm not a zsh guy, if you are & have a fix, let me know.
+# I'm not a zsh guy, but I did some research... either have to use the
+# syntax $=range (zsh-specific) or check for ZSH_* in the environment
+# and do 'setopt shwordsplit'. Pretty sure this means I shall never
+# again care whether one of my shell scripts fails on zsh.
### Config stuff.
-# Where the date get stored
+# Where the date gets stored.
DATEFILE="$HOME/.slack_last_update"
# Use the primary site, not a mirror.