nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] changes to mark.man

2017-03-19 19:17:20
Ralph Corderoy wrote:
P.S. The Mail-Followup-To header is set;  that might help your replies
to hit the list.  :-)

I sat down today and cobbled togther the following 'rep' command,
which will (hopefully) Do The Right Thing depending on which +folder
I'm in, without my having to think about it. That is to say, a
simple 'repl' on your current message addresses my reply to you,
while a 'repl -group' sends to the list, and I have had 'repll'
aliased to 'reply -group' but I can never remember to use it, for
I am a simple-minded fool, often in a hurry. Now I just have to
type 'rep', no matter where I am or who I'm replying to and we
should all be happier!

#!/usr/local/bin/dash

repl=/usr/local/bin/repl
repll="/usr/local/bin/repl -group"

case $(folder -fast) in
        lists|obsd|nmh) list=1 ;;
        *) : ;;
esac

if [ $# -eq 0 ] ; then
    scan cur > /dev/null 2>&1
    err=$?
    case "$err" in
        0) cur=$(basename "$(mhpath cur)") ;;
        1) echo "no cur" ; exit ;;
        *) exit ;;
    esac
        if [ $list -eq 1 ] ; then
                $repll "$cur"
        else
                $repl "$cur"
        fi
else
        if [ $list -eq 1 ] ; then
                $repll "$@"
        else
                $repl "$@"
        fi
fi

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>