GNU bug report logs - #66663
30.0.50; Allow dir locals file selection in *-dir-local-variable functions

Previous Next

Package: emacs;

Reported by: Mauro Aranda <maurooaranda <at> gmail.com>

Date: Sat, 21 Oct 2023 12:10:02 UTC

Severity: wishlist

Tags: patch

Fixed in version 30.0.50

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


Message #19 received at 66663 <at> debbugs.gnu.org (full text, mbox):

From: Mauro Aranda <maurooaranda <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 66663 <at> debbugs.gnu.org, juri <at> linkov.net
Subject: Re: bug#66663: 30.0.50; Allow dir locals file selection in
 *-dir-local-variable functions
Date: Sat, 21 Oct 2023 11:06:28 -0300
[Message part 1 (text/plain, inline)]
On 21/10/23 10:49, Mauro Aranda wrote:
> On 21/10/23 09:45, Eli Zaretskii wrote:
>  >> Cc: Juri Linkov <juri <at> linkov.net>
>  >> Date: Sat, 21 Oct 2023 09:16:28 -0300
>  >> From: Mauro Aranda <maurooaranda <at> gmail.com>
>  >>
>  >> +Since both @file{.dir-locals.el} and @file{.dir-locals-2.el} file
>  >> +might exist in the same directory, there may be some clash about 
which
>  >> +file you want to modify when executing the above three commands.  To
>  >> +solve that, all three of them take a prefix argument, to indicate
>  >> +which file you want to modify.  When both files exist, a prefix
>  >> +argument means to prefer to modify @file{.dir-locals.el} instead of
>  >> +@file{.dir-locals-2.el}.  When one of the files doesn't exist, and
>  >> +you're adding a variable or copying the file-local variables, a 
prefix
>  >> +argument means to modify (i.e., create) the file that doesn't yet
>  >> +exist.
>  >
>  > I think a better UI is to ask the user when the command is invoked
>  > with a prefix argument.
>
> Yes, that makes sense.  I'll try that approach.

I reworked the patch to implement that UI instead.  Patch attached.
[0001-Allow-specifying-the-dir-locals-file-to-edit-Bug-666.patch (text/x-patch, attachment)]

This bug report was last modified 1 year and 209 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.