newlist patch for beta 5
Hello,
Newlist has a problem.
When run in interactive mode, it will output the necessary entries
for the Sendmail 'aliases' file. That is very nice.
However, I am not usually in an X-Window session, so I can't use a
mouse to cut'n'paste those entries into my /etc/aliases. It's very annoying.
The attached version will print all *informational* messages to
stderr, not stdout. Only the 'aliases' entries are printed to stdout. So now, all I need to do is
./newlist >> /etc/aliases
(or ./newlist > tempfile.txt ; cat tempfile >> /etc/aliases. You
get the idea.) I will still get prompted (if in interactive mode), but the prompts will be printed to stderr, and all the aliases will go to stdout (and hence redirect into my file).
If I run in non-interactive mode, and put all the necessary
variables on the command line, then the only output (to stdout) is the aliases. All other behaviour is unchanged.
This also makes it much easier to write automated shell scripts
and CGI programs to create new lists, because there's no messy sed to parse out the informational messages.
The attached file is the new version of newlist, created off
2.0beta5. Feel free to create a diff of it if that is your preferred format.
Note that I presented this same patch for beta2 but it was never
incorporated, so I assume the maintainers aren't interested in this feature. In short: You have to grab this and keep updating it yourself if you want to use it in future versions of MailMan.
Thanks, Derek Simkowiak dereks@kd-dev.com
Note that I presented this same patch for beta2 but it was never
incorporated, so I assume the maintainers aren't interested in this feature. In short: You have to grab this and keep updating it yourself if you want to use it in future versions of MailMan.
Did you put it up on sourceforge? Barry's mailbox is pretty swamped, if the patch didn't make it into the sourceforge patch database, chances are he just lost track of it.
participants (2)
-
Derek Simkowiak
-
Ron Jarrell