[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: longish Local Variables in Files
From: |
Dan Jacobson |
Subject: |
Re: longish Local Variables in Files |
Date: |
Fri, 27 Aug 2004 09:13:26 +0800 |
K> Then you are out of luck: file local variables must be specified on a
K> single line.
Make sure this is documented. Wait, I demonstrated that it could be
done on two lines.
K> What's wrong with having a really long compile-command
K> line in your script?
I don't want lines to wrap etc. on my terminal or printer. Call me old
fashioned.
rms> # compile-command: "invoke-rc.d chrony restart && sleep 2`\
rms> #` && grep chrony /var/log/syslog|tail -19"
Indeed that works, no need for /bin/sh's ":", and one can even remove
the backslash. One can go on and on:
# Local Variables:
# compile-command: "p=$PWD && cd /tmp && procmail -m LOGABSTRACT=all `
#` VERBOSE=on $p/.procmailrc.local.post </dev/null `
#` bla bla"
# End:
OK, remember to document this `#` hack. As this always is sent to sh,
this should always work. And document simpler ways for those who
don't need to hide local variables in comments, e.g.,
rms> # compile-command: "invoke-rc.d chrony restart && sleep 2 \
rms> && grep chrony /var/log/syslog|tail -19"
By the way, the documentation, both of local variables and compile,
could also say compile-command is a great local variable to set.
E.g., my .crontab file has
# Local Variables:
# compile-command: "crontab .crontab"
# End: