[Users] Better defaults for clawsker

Ricardo Mones ricardo at mones.org
Fri Jan 4 18:08:08 CET 2019


On Mon, 31 Dec 2018 14:21:50 +0100
"H.Merijn Brand" <h.m.brand at xs4all.nl> wrote:

> On Sun, 23 Dec 2018 11:38:45 +0100, Ricardo Mones <ricardo at mones.org>
> wrote:
> 
> > On Fri, 21 Dec 2018 21:51:09 +0100
> > "H.Merijn Brand" <h.m.brand at xs4all.nl> wrote:
> >   
> > > Now simpler and without syntax error    
> > 
> > Added to master, thanks! :-)  
> 
> 👍
> 
> A few more remarks
> 
> • hashbang

Applied, thanks for this suggestion!

> 
> • PREFIX
> 
>   Again, I don't think /usr/local is a good default. The script itself
>   uses the File::Which module to find out, so why not use the same for
>   the transistion?
> 
>   PREFIX ?= /usr/local
> 
>> 
>   PREFIX ?= $(shell perl -MFile::Which -E'say which ("claws-mail") =~
> s{/[^/]+\z}{}r')
> 
>   or
> 
>   PREFIX ?= $(shell which claws-mail | perl -pe's{/[^/]+\z}{}')

Not sure about this one. The '/usr/local' has been traditionally the default
for unspecified prefixes and it's the default for Claws Mail IIRC.

Also, trying to derive claws-mail prefix from "whiching" the claws-mail
command may fail easily (symlinks, wrapper scripts)... I think the binary
would need a --prefix option which printed configured prefix, that way it
would be more difficult to fool it.

best regards,
-- 
  Ricardo Mones 
  ~
  You have the capacity to learn from mistakes. You'll learn a lot 
  today.                                           /usr/games/fortune

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: Firma digital OpenPGP
URL: <http://lists.claws-mail.org/pipermail/users/attachments/20190104/9de143d7/attachment.sig>


More information about the Users mailing list