From: Mauro Aranda <maurooaranda@gmail.com>
To: Drew Adams <drew.adams@oracle.com>,
Michael Albinus <michael.albinus@gmx.de>
Cc: Eli Zaretskii <eliz@gnu.org>,
"wyuenho@gmail.com" <wyuenho@gmail.com>,
"63891@debbugs.gnu.org" <63891@debbugs.gnu.org>
Subject: bug#63891: 29.0.91; customize-save-variable should not save all variables if a custom file exists
Date: Sun, 29 Oct 2023 07:33:29 -0300 [thread overview]
Message-ID: <6a0bbea0-eb6e-48bb-9aa6-d86be8e5d228@gmail.com> (raw)
In-Reply-To: <SJ0PR10MB54882196AB57347050CC07A8F3A2A@SJ0PR10MB5488.namprd10.prod.outlook.com>
On 28/10/23 23:20, Drew Adams wrote:
>> > 2. Emacs should make available features I noted in
>> > previous posts, such as a function to consider a
>> > change to an option value (by program) to not be a
>> > change. This lets code change a value but not
>> > have Customize consider that a change has been
>> > made - so the change won't be saved automatically
>> > or reported as having occurred.
>>
>> I wonder what does this mean in terms of the
>> possible states for a user option. AFAICT,
>> none of the current possible states (STANDARD,
>> SAVED, CHANGED, SET) fit in your description.
>>
>> STANDARD: No, standard value and current value
>> don't match.
>> SAVED: No, that setting wasn't saved.
>> CHANGED: No, because you're saying that Custom
>> shouldn't consider the change.
>> SET: No, because the code needs to use
>> customize-set-variable, but that
>> wouldn't be Custom ignoring the change.
>
> I use my library `cus-edit+.el', which changes
> some of the `cus-edit.el' code. See, e.g.,
> function `custom-consider-variable-unchanged'.
> Doc string:
>
> Consider this variable as being unchanged now.
> This does not save the current value; it just
> considers the value to be unchanged. If no
> further changes are made to this variable, then
> after doing this, `customize-customize' will not
> display this variable, since it was considered
> unchanged.
'customize-customized', right?
> The cus-edit+.el code is here:
>
> http://www.emacswiki.org/emacs-en/download/cus-edit%2b.el
I tried to visit this link with eww, but got 404 Not Found.
> And here is some info about it:
>
> http://www.emacswiki.org/CustomizingAndSaving#CustomizePlus
Same here.
Anyway, I read custom-consider-variable-unchanged, and it looks to me
that it would have the same problem when saving an unrelated variable,
because of the way custom-save-all works. I want to work on improving
the saving mechanism so that problem disappears, but ISTM that this
bug report is about a different bug: a misuse of custom-set-variables.
> About considering some customized state to be
> "unchanged", see this post to bug 19328 thread.
>
> https://debbugs.gnu.org/cgi/bugreport.cgi?bug=19328#47
Thank you. I read the "Dealing with Spurious Changes" section from
cus-edit+.el. Part 2 and Part 3 sound interesting to me. It seems to
me that adding an ignore mechanism would be useful, in general.
> I don't claim that what I did in `cus-edit+.el'
> is the only or the best way to fix the problems
> it addresses. It might be a starting point for
> someone with a better idea or understanding of
> the custom code/behavior.
It's certainly useful to me to know about your approach.
I guess at this point I need to hear from Michael to understand better
about this 2 defcustoms in particular, and what are the expectations
after modifying them. I certainly wish the code goes back to using
customize-set-variable or something similar, rather than
custom-set-variables.
next prev parent reply other threads:[~2023-10-29 10:33 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <ae449be5-9a4c-4e7e-b624-deae8a27fbbb@gmail.com>
2023-10-27 10:57 ` bug#63891: 29.0.91; customize-save-variable should not save all variables if a custom file exists Mauro Aranda
2023-10-27 11:51 ` Michael Albinus
2023-10-27 15:44 ` Mauro Aranda
2023-10-28 9:58 ` Mauro Aranda
2023-10-28 18:22 ` Drew Adams
2023-10-28 22:32 ` Mauro Aranda
2023-10-29 2:20 ` Drew Adams
2023-10-29 10:33 ` Mauro Aranda [this message]
2023-10-29 11:07 ` Michael Albinus
2023-10-29 11:50 ` Mauro Aranda
2023-06-04 12:36 Jimmy Yuen Ho Wong
2023-06-04 12:56 ` Eli Zaretskii
2023-06-04 13:02 ` Jimmy Wong
2023-06-04 13:23 ` Eli Zaretskii
2023-06-04 14:00 ` Jimmy Wong
2023-06-04 14:26 ` Eli Zaretskii
2023-06-04 16:49 ` Jimmy Wong
2023-06-06 12:01 ` Michael Albinus
2023-06-06 12:20 ` Eli Zaretskii
2023-06-06 12:36 ` Michael Albinus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6a0bbea0-eb6e-48bb-9aa6-d86be8e5d228@gmail.com \
--to=maurooaranda@gmail.com \
--cc=63891@debbugs.gnu.org \
--cc=drew.adams@oracle.com \
--cc=eliz@gnu.org \
--cc=michael.albinus@gmx.de \
--cc=wyuenho@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.