Hello, Michael Convey <[email protected]> wrote: |The syntax per the man page suggests: | |$ mailx -s test -c recip1 recip2 recip3 | |Sends this mail as follows: | |To: recip2 recip3 | |Cc: recip1 | |Does mail distinguish 'Cc:' and 'Bcc:' from 'To:' by a spa\ |ce? In other words, is the only way to have multiple Cc: a\ |nd multiple Bcc: to use commas with |no spaces? | |For example: | |$ mail -s test -c recip1,recip2,recip3 -b recip4,recip5,recip6 recip7 | |##no spaces between the -c recipients and no spaces betwee\ |n the -b recipients## | |results in: | |To: recip7 | |Cc: recip1 recip2 recip3 | |Bcc: recip4 recip5 recip6
The short answer is: maybe use -c multiple times instead, that worked already with BSD Mail 8.1[.1] from 1996-06-14. Note now i'm talking even more S-nail rather than Heirloom mailx, i've changed -- hopefully improved -- some things along the 2833 commits i went. E.g., we support complete name specifications (Michael Convey <[email protected]>), so that spaces alone don't suffice. So it depends on the content of the receivers and where you do it (command line in your case). In general such input is first quick+dirty checked for special characters, and then a(n) (hopefully) adquate parsing method is used: if the data contains any of , " \ ( < | then it'll be splitted on commas only, otherwise on space, tabulator or comma. ..Looking back into Heirloom he calls names.c:extract() for the -c command line, and that splits on " \t,(" (the second is tabulator). |Does the 'To:' recipient alway have to be the last argumen\ |t on the command line? For Heirloom the answer should be "yes". S-nail can be given Mail-Transfer-Agent arguments after a -- separator, but these will be ignored unless the *expandargv* variable is set (that can also take values "fail" or "restrict"). Note that S-nail also supports a -. option, which forcefully turns on send mode and ends option processing, so that anything in between -. and -- is treated as recipients for To:, and only. --steffen ------------------------------------------------------------------------------ _______________________________________________ nail-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nail-devel
