Re: SLRN random-sig files, found this but stilll
Incoming from Josef Oswald:
>
> looking to set up random sig with SLRN I found this link:
>
> http://lists.infodrom.org/debian-user-de/2001/03/att-0026/01-slrn-random-sig
>
> At the end it says one need to create for each quote a single file, my
> question is:
> what name can I use and or does this scrip just take any files it finds
> and uses them as signatures?
[snip]
> $sigdir = $ENV{'HOME'} . '/.Sig';
[snip]
> if(opendir(DIR, $sigdir)) {
> @randfiles = grep( !/^\./, readdir(DIR));
>
> if(open(RAND, $sigdir . '/' . $randfiles[rand($#randfiles)])) {
That says to me it's going to take anything it finds in your ~/.Sig
directory, except the two system dotfiles ".." and ".", or anything
with a dot at the beginning of the filename. "foo" and "bar" should
be fine filenames for this, as would "foo.bar".
Too bad you couldn't do something simpler (or maybe you can; I've
never wanted to). This is all it takes for mutt:
----------------------------------------------
Note: not tested!
~/sh/mail_sig:
#!/bin/bash
cat ~/.signature
/usr/bin/fortune -s
.muttrc:
folder-hook . set signature="~/sh/mail_sig|"
----------------------------------------------
--
Any technology distinguishable from magic is insufficiently advanced.
(*) http://www.spots.ab.ca/~keeling
- -
Reply to: