nmh-workers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: automatic decode mime in repl


From: Philipp Takacs
Subject: Re: automatic decode mime in repl
Date: Thu, 10 Feb 2022 15:56:51 +0100

Hi David

I don't understand why do you try to convince me from convertargs. As
said before: I have a working solution. Also convertargs will not work
in my setup. No I don't say convertargs is bad, I say my aproatch is
better. It has it own drawbacks, but in comparson they are smaller and
better to fix or workaround. Maybe I'm biased on this, but thats my view
on this. But lets look at it a bit deeper:

[2022-02-09 22:34] David Levine <levinedl@acm.org>
> Philipp wrote:
>
> > The problem I see is that convertargs looks complex.
>
> If you use a Bourne-compatible shell, would you try this, please:
>
>     source $(mhparam docdir)/contrib/replaliases
>     rtm [msg]

This is not that easy, because I use mmh. So convertargs is not there.
But I can give you my experience I have got from the nmh tests. The
test repl/test-convert fails with following error:

> /bin/sh: 1: par: not found
i> charset=; iconv -f ${charset:-us-ascii} -t utf-8 
'/home/satanist/src/nmh/test/testdir/Mail/mhbuildm4m2Df' | sed 's/^\(.\)/> \1/; 
s/^$/>/;' | par 64  >/home/satanist/src/nmh/test/testdir/Mail/mhbuildwpUMcf 
"$@": exited 127
> mhbuild: store of text/plain content failed, continuing...
> /bin/sh: 1: par: not found
> charset=; iconv -f ${charset:-us-ascii} -t utf-8 
> '/home/satanist/src/nmh/test/testdir/Mail/mhbuildgcLmQf' | sed 's/^\(.\)/> 
> \1/; s/^$/>/;' | par 64  
> >/home/satanist/src/nmh/test/testdir/Mail/mhbuildXaOu6d "$@": exited 127
> mhbuild: store of text/plain content failed, continuing...

This is probaly a bug in etc/mhn.defaults.sh and install par fixed it.
But this is a bad first experience.

> > The problem I see is that convertargs looks complex. The goal of my
> > patch is to have an easy to use solution which is enabled by default.
>
> Easy for developers or easy for users?

First for the user, but also for the developers. For a user I see a few
problems:

What needs to be done that this is enabled by default? Yes I poke on this
point, because I belive this is importend. Wheter you like it or not:
MIME messages are common and nmh is not able to reply to one in the
default configuration.

How do I create alternativ repl configurations? Like have a `replwork'
which has diffrent default switches and forms. I just see the solution
to write an alias. But I like the argv0 configuration methode and would
miss it.

How can I use it from other things then a Bourne-compatible shell? Like
fish shell, powershell, ipython or a java process. As far as I see you
would need to port contrib/replaliases to all these interfaces or use a
sh instand of calling repl directly.

As a developer I see also a few problems:

For me both arpoces are code changes[0]. convertargs changes two
programms and needs a wrapper which provides an easy interface. My
aproatch changes only repl and depends with the rest on already
implemented features.

The required wrapper also needs some maintainership. Fixing bugs,
changed interface, interfaces for other shells. Yes the wrapper is
small, but it moves parts of a core feature to a contributer script.

So in genaral convertargs looks like a stopgap solution. I wanted to
have a solution and I have this solution since 2016. Yes it's not the
best solution, but a good one. The question is: Do you want it?

Philipp

[0] Or at least my arpoatch was 2016 when I intruduced it to mmh.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]