[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Persistence of variables
From: |
Marcin Borkowski |
Subject: |
Re: Persistence of variables |
Date: |
Sun, 25 Mar 2018 19:15:14 +0200 |
User-agent: |
mu4e 1.1.0; emacs 27.0.50 |
On 2018-03-21, at 23:16, Joost Kremers <joostkremers@fastmail.fm> wrote:
> On Wed, Mar 21 2018, tomas@tuxteam.de wrote:
>> On Wed, Mar 21, 2018 at 08:12:40AM -0700, Drew Adams wrote:
>>> If you only want to save one variable, just use an option.
>>
>> Of course!
>>
>> What Drew said. The whole thing was in front of us all, we
>> just had to squint the right way.
>
> Well, that depends on the variable. Options (i.e., those defined with
> defcustom) are really meant for user customisation: meant to be set
> explicitly by the user, and meant to be forgotten once set. If you
> want to save a variable that changes regularly and that the user
> doesn't set explicitly, then a user option is a bad fit. IMHO the best
> way to deal with that is indeed to use a separate file and to provide
> a user option to set the file path & name. That way, users can decide
> for themselves if they want to keep the file under version control,
> sync it across machines, or not.
And this is exactly my use-case: a variable whose value will be
periodically changed. And I don't like the hassle of having an option
to a separate file with just this one variable... Of course, if the
only user beside me won't like Emacs messing around with his init.el,
I'll do it that way.
Thanks!
--
Marcin Borkowski
http://mbork.pl
- Re: Persistence of variables, (continued)
- Re: Persistence of variables, Emanuel Berg, 2018/03/21
- Message not available
- Re: Persistence of variables, Emanuel Berg, 2018/03/21
- Re: Persistence of variables, Eric Abrahamsen, 2018/03/21
- Re: Persistence of variables, Marcin Borkowski, 2018/03/21
- RE: Persistence of variables, Drew Adams, 2018/03/21
- Re: Persistence of variables, tomas, 2018/03/21
- Re: Persistence of variables, Joost Kremers, 2018/03/21
- Re: Persistence of variables,
Marcin Borkowski <=
- RE: Persistence of variables, Drew Adams, 2018/03/25
- Message not available
- Re: Persistence of variables, Emanuel Berg, 2018/03/27
- Re: Persistence of variables, Marcin Borkowski, 2018/03/28
- Message not available
- Re: Persistence of variables, Emanuel Berg, 2018/03/28
- Message not available
- Re: Persistence of variables, Emanuel Berg, 2018/03/21
- Message not available
- Re: Persistence of variables, Robert L., 2018/03/24
- Re: Persistence of variables, Marcin Borkowski, 2018/03/25
- Re: Persistence of variables, Eric Abrahamsen, 2018/03/25
- Re: Persistence of variables, Marcin Borkowski, 2018/03/28
- Message not available
- Re: Persistence of variables, Emanuel Berg, 2018/03/21