weechat: refactor wee script

This commit is contained in:
Henrik Lissner 2016-12-25 19:17:35 -05:00
parent 20be98e020
commit 9204cd9649

View file

@ -4,8 +4,7 @@
# and prepends * to commands).
fifos=$(echo "$HOME/.weechat/weechat_fifo_*")
if [ -z "$fifos" ]
then
if [[ -z "$fifos" ]]; then
>&2 echo "No FIFOs. Is weechat running?"
exit 1
fi
@ -21,8 +20,7 @@ rd() {
fi | sed '/^ *\(#\|$\)/ d;s/^/*/g'
}
if [ "$1" = "-d" ]
then
if [[ "$1" = "-d" ]]; then
shift
rd $@
else