emacs-devel
[Top][All Lists]
Advanced

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

Re: xdg.el and eww custom load


From: Basil L. Contovounesios
Subject: Re: xdg.el and eww custom load
Date: Thu, 01 Nov 2018 18:54:22 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

"Garreau, Alexandre" <address@hidden> writes:

> Le 01/11/2018 à 14h29, Basil L. Contovounesios a écrit :
>> "Garreau, Alexandre" <address@hidden> writes:
>>> On 2018-10-31 at 12:41, Basil L. Contovounesios wrote:
>>>>>> But you wouldn't want to use this to set the value of
>>>>>> eww-download-directory in its defcustom declaration
>>>>>
>>>>> Why so?
>>>>
>>>> Simply loading a package should have as few effects and be as fast as
>>>> possible.  Think, for example, of loading eww.el for the purposes of
>>>> testing on various environments both local and remote.  I'm sure there
>>>> are more serious dangers than I'm letting on.
>>>
>>> But getting incorrect behavior is bad as well…
>>> Parameters/customizations are here for something, and enforcing a
>>> broken (I mean unrelevant, disadapted, arbitrary) default to the user,
>>> or require them to (arbitrarily and statically) replicate some external
>>> config (user dirs) into their custom emacs config seems wrong toward
>>> this, to me.
>>
>> I never said the default can't be improved; I merely cautioned against
>> invoking a subprocess in a defcustom.  Obviously there are several
>> workarounds for this, e.g. by predicating some representative value on
>> the result of executable-find, as per mm-url-program. in
>> lisp/gnus/mm-url.el.
>
> I don’t understand how this is a workaround: they just store a command
> name as is.  and call it later.

It defers invoking a subprocess until it is actually needed, rather than
during evaluation of a defcustom.

> But we don’t want to call the command each time we save something, do
> we?

I don't see why the result can't be saved for subsequent reuse.

> And if so what to do with `eww-download-directory'?  obsolete it to
> replace it with a same-name function?

I don't see what would make it obsolete.

>>>>> Wow that’s awesome: replacing .emacs.d with something following xdg (why
>>>>> not .config/emacs/?) so to cleanse home, I’ve dreamt it (I also dreamt
>>>>> of an “external” customization method for defcustom where it would go
>>>>> get its default or saved custom values from external non-elisp files
>>>>> instead (or exteral programs), such as the xdg ones), but procrastinated
>>>>> to suggest it.  He did it.
>>>
>>> So that still applies?
>>
>> I don't know what you're referring to.
>
> To previous paragraph: suggesting to do that instead of .emacs/.emacs.d
> in ~.
>
> So in the end your config is in .config/emacs/*.el (or
> .config/emacs.el), your data is in .local/share/emacs/, etc.  And your
> home is less bloated, and users are more aware of where are canonical
> programs config and data as they’re all in the same place (that ought to
> be uniformized with other windows programs behavior, of course).
>
> Since it hasn’t been implemented it is still time to suggest it.

Sure, you can always revive the aforementioned emacs-devel thread.

-- 
Basil



reply via email to

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