Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-24 Thread Bruno Haible
Hi Collin, > Can you apply this patch for me? Thanks, applied, with a tweak: I don't like the variable name 'group' here. I know that 'tuple' is not possible either. But a couple of lines below we call it a 'row', and that fits better (imagining the ignorelist as a matrix). > Then I am not

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-24 Thread Collin Funk
On 3/24/24 4:05 PM, Bruno Haible wrote: > Oh, indeed. If filetable['added'] and filetable['removed'] are the same, > no wonder that you are seeing nonsense in the .gitignore files... Yes, I didn't notice it because I thought the issue was in my interpretation of the 'sed' and 'join' commands in

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-24 Thread Bruno Haible
Collin Funk wrote: > See this decade old typo: > > diff --git a/pygnulib/GLImport.py b/pygnulib/GLImport.py > index d417137df6..2434e5f506 100644 > --- a/pygnulib/GLImport.py > +++ b/pygnulib/GLImport.py > @@ -1393,7 +1393,7 @@ AC_DEFUN([%s_FILE_LIST], [\n''' % macro_prefix > # Treat

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-24 Thread Collin Funk
On 3/23/24 7:15 PM, Bruno Haible wrote: > :-D Well, that's the principle of a von-Neumann computer: that a program > (consisting of instructions) can assemble other instructions, to form a new > program. For CPU instructions, it's a well-known technique. For 'sed' > programs, apparently not...

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-23 Thread Bruno Haible
Collin Funk wrote: > sed -e 's,/,\\/,g' -e 's,^,/^,' -e 's,$,\$/d,' < "$tmp"/ignore-removed > if test -n "$anchor"; then sed -e 's,/,\\/,g' -e > "s,^,/^${doubly_escaped_anchor}," -e 's,$,$/d,' < "$tmp"/ignore-removed; fi > > Which uses sed expressions to create sed expressions right? Like this:

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-23 Thread Collin Funk
Hi Bruno, On 3/23/24 3:49 AM, Bruno Haible wrote: > What's still missing, is the handling of 'files_removed'. > GLImport.py lines 804..820 ought to match gnulib-tool.sh lines 6253..6273. Sorry I haven't fixed this yet. I'm pretty sure I have been overthinking this issue for the past hour or two

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-23 Thread Bruno Haible
3 +1,10 @@ +2024-03-23 Bruno Haible + + gnulib-tool.py: Refactor. + * pygnulib/GLImport.py (GLImport._done_dir_, + GLImport._update_ignorelist_, GLImport.execute): Rename some variables. + (GLImport._update_ignorelist_): Use constants.substart. + 2024-03-23 Collin Funk gnulib-tool.py: Follow g

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 69.

2024-03-22 Thread Collin Funk
something like this in init.sh? I'm not sure if this would also apply to the test directory tests. CollinFrom b163f88f90453f20564960265a3cb5236c33ba85 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Fri, 22 Mar 2024 19:43:41 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-20 Thread Bruno Haible
I wrote: > So, it's OK to undocument these options in gnulib-tool.sh. Done: 2024-03-20 Bruno Haible gnulib-tool.sh: Undocument the --[no-]cache-modules options. Reported by Collin Funk in .

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 68.

2024-03-19 Thread Bruno Haible
> This patch patch should apply cleanly for you. Thanks. Applied. Bruno

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 68.

2024-03-19 Thread Collin Funk
lin Funk Date: Tue, 19 Mar 2024 12:09:57 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 68. Follow gnulib-tool change 2022-07-31 Akim Demaille gnulib-tool: add support for --automake-subdir-tests * pygnulib/main.py (main): Add support for --automake-subdir-tests. * pygnu

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 68.

2024-03-19 Thread Bruno Haible
Hi Collin, > Here is two patches. The first adds '--automake-subdir-tests' which is > used by GNU Bison. In GLImport.py: # Determine whether --automake-subdir/--automake-subdir-tests are supported. if self.config['automake_subdir'] and self.config['automake_subdir_tests']: I

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-19 Thread Bruno Haible
Collin Funk wrote: > $ diff -u python.help shell.help > --- python.help 2024-03-19 10:09:46.255348603 -0700 > +++ shell.help 2024-03-19 10:09:37.986334838 -0700 > @@ -79,6 +79,8 @@ > directory. >--local-dir=DIRECTORY Specify a local override directory where

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 68.

2024-03-19 Thread Collin Funk
2024 12:09:57 -0700 Subject: [PATCH 1/2] gnulib-tool.py: Follow gnulib-tool changes, part 68. Follow gnulib-tool change 2022-07-31 Akim Demaille gnulib-tool: add support for --automake-subdir-tests * pygnulib/main.py (main): Add support for --automake-subdir-tests. * pygnulib/GLInfo.py

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-19 Thread Collin Funk
Hi Bruno, On 3/19/24 8:47 AM, Bruno Haible wrote: > Tom Dickey's packages (GNU ncurses, lynx, etc.) and GNU clisp still use > configure.in. Interesting, good to know. It seems working on gnulib-tool is a good way for me to explore all the GNU packages. Speaking of which, I was working on

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-19 Thread Bruno Haible
Collin Funk wrote: > I forgot about the existence of the 'configure.in' file. ... > The only reason I know that it exists is because I looked through some > 4.4BSD sources at one point. It had some GNU software that used that > name. Tom Dickey's packages (GNU ncurses, lynx, etc.) and GNU clisp

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-19 Thread Collin Funk
Bruno Haible writes: > In common talk, "I made an error" and "I made a mistake" are synonymous. > But when talking about a program, there's a difference between "an error" > and "a mistake". I agree, that would be a more accurate description. I didn't put too much thought into it. I was in

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-19 Thread Bruno Haible
Hi Collin, > Two simple patches. This just makes it so that the library Makefile > is output after gnulib-comp.m4. > ... > but the removal of the temporary file is done inside of the parent, > outside of the loop. Therefore only the second temporary file would be > deleted. Thanks! Both patches

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 66.

2024-03-19 Thread Bruno Haible
Hi Collin, Thanks; applied as well. > Also, I am aware that the conditional that I changed in > GLTestDir.execute() can be simplified to: > > # Determine final file list. > if not single_configure: > main_modules = modules > tests_modules = [ module >

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 65.

2024-03-19 Thread Bruno Haible
Hi Collin, The patch is mostly good; I've applied it. One point needs attention, still: In gnulib-tool.sh the code looks at configure.ac and, if that does not exist, at configure.in: # Prefer configure.ac to configure.in. if test -f "$destdir"/configure.ac; then

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 67.

2024-03-18 Thread Collin Funk
-0700 Subject: [PATCH 3/4] gnulib-tool.py: Follow gnulib-tool changes, part 67. Follow gnulib-tool change 2022-03-01 Paul Eggert Create lib/Makefile.am after gnulib-comp.m4 * pygnulib/GLImport.py (GLImport.execute): Create library makefile after creating gnulib-comp.m4. --- ChangeLog

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 66.

2024-03-18 Thread Collin Funk
it harder to cross reference if someone new wants to mess with gnulib-tool.py. :) CollinFrom cab20e9eafaa717132c4c085a88cb86cf66a6efb Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Mon, 18 Mar 2024 16:26:34 -0700 Subject: [PATCH 2/2] gnulib-tool.py: Follow gnulib-tool changes, part 66. Follow

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 65.

2024-03-18 Thread Collin Funk
23:46 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 65. Follow gnulib-tool change 2021-12-19 Bruno Haible gnulib-tool: Don't insist on ACLOCAL_AMFLAGS. * pygnulib/GLImport.py (GLImport.execute): Don't add extra '-I' before m4 directory in ACLOCAL_AMFLAGS. Prefer '0' in

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 64.

2024-03-18 Thread Collin Funk
Hi Bruno, On 3/18/24 4:05 AM, Bruno Haible wrote: > Thanks a lot. Yes, things get tricky if, after after some refactoring, the > function names don't fit the semantics any more. Yeah, how we have it now should match gnulib-tool.sh, but the naming is a bit misleading. I'll keep it in the back of

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 64.

2024-03-18 Thread Bruno Haible
Hi Collin, > after the change that this patch is following the function names are > slightly misleading since: > > GLModule.isNonTests() != (not GLModule.isTests()) > > Instead we have 3 separate unique operations in gnulib-tool.sh: > > 1. func_verify_tests_module > 2.

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 64.

2024-03-17 Thread Collin Funk
01 From: Collin Funk Date: Sun, 17 Mar 2024 20:09:12 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 64. Follow gnulib-tool change 2021-12-25 Bruno Haible gnulib-tool: Respect applicability 'all' without --single-configure. * pygnulib/GLModuleSystem.py (GLModule.isT

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Collin Funk
On 3/17/24 6:31 PM, Bruno Haible wrote: > Well, one can also see it the other way around: With single quotes > everywhere, it's more consistent. LOL, fair enough. > Feel free to find more arguments for one or the other. I'm undecided, > but it would be a major change, so one should think about

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Bruno Haible
Collin Funk wrote: > Emacs and vim both agree at least. > > def test_emacs(value): > '''This is a Python comment. > Here1''' > > def test_vim(value): > '''This is a Python comment. > Here2''' Likewise with kate and Eclipse. > Since we have agreed upon single quotes for actual

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Collin Funk
On 3/17/24 5:57 PM, Bruno Haible wrote: > Yes, we can do that. In the commit today, however, I wanted to close one issue > without possibly opening another one. No worries, there is no rush. > It is also worth testing various editors (gedit, kate, emacs, eclipse, > PyCharm, etc.): Where do they

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Bruno Haible
Hi Collin, > Unrelated to the newline change itself, but something I noticed that I > would like to bring up: > > def lines_to_multiline(lines): > '''lines_to_multiline(List[str]) -> str > > Combine the lines to a single string, terminating each line with a newline > character.''' >

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Collin Funk
Hi Bruno, On 3/17/24 4:49 PM, Bruno Haible wrote: > It is not good if, each time we deal with a list of lines, we have to give > extra thought to the case of 0 lines. This is only a recipe for > inconsistencies. Yes, this change looks much better. Having 'if len(lines) > 0: ...' everwhere looks

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Basil L. Contovounesios
Collin Funk [2024-03-17 15:03 -0700] wrote: > +if len(cleansed) > 0: > +return '\n'.join(cleansed) > +else: > +return '' FWIW '\n'.join([]) is '', so perhaps it isn't necessary to check len(cleansed). Thanks, -- Basil

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Bruno Haible
Collin Funk wrote: > > FWIW '\n'.join([]) is '', so perhaps it isn't necessary to check > > len(cleansed). > > Oops, you are correct. Thanks, that should make the code look nicer. I > think I originally had '\n'.join(cleansed) + '\n', where the goal was > to remove the + '\n' but I removed it.

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Bruno Haible
Hi Collin, > This patch is just one added function. Can you double check that I > understood your 'sed' wizardry correctly Bruno? Yes. You even added support for nested 'if's, which the original doesn't have. Nice. > I placed the sed command and a modified version of my Python function in > two

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Collin Funk
+ '\n' but I removed it. Good catch. I've attached the updated patch. CollinFrom cb06a3a076e67c146ffdbda7fbe2a14c048bca91 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sun, 17 Mar 2024 14:51:18 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63. Follow gnulib-tool chang

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63.

2024-03-17 Thread Collin Funk
for it CollinFrom 6b1cd6387931af81388574826ba38fe466da7233 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sun, 17 Mar 2024 14:51:18 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 63. Follow gnulib-tool change 2020-12-28 Bruno Haible gnulib-tool: Fix logic whether to add

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 62.

2024-03-17 Thread Bruno Haible
Collin Funk wrote: > Just adds ensure_writable after copying files. Thanks! Applied. Bruno

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 62.

2024-03-17 Thread Collin Funk
Pretty small patch. Just adds ensure_writable after copying files. Collin >From 224c3c910f88d22b825ad93e189ef6102487ad5a Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sun, 17 Mar 2024 10:03:54 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 62. Follow gnulib-t

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 61.

2024-03-17 Thread Bruno Haible
Hi Collin, All three patches applied. Thanks! > And then diff'ing the shell and python output before part 60, after part > 60, and then after this patch: > > $ ls -l *.diff > -rw-r--r--. 1 collin collin 1745735 Mar 16 20:00 0001-pre60.diff > -rw-r--r--. 1 collin collin 1745735 Mar 16 20:03

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 61.

2024-03-16 Thread Collin Funk
0 2001 From: Collin Funk Date: Sat, 16 Mar 2024 19:56:42 -0700 Subject: [PATCH 2/2] gnulib-tool.py: Follow gnulib-tool changes, part 61. Follow gnulib-tool change 2022-01-09 Bruno Haible Remove influence of Automake conditionals on conditional dependencies. * py

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 60.

2024-03-16 Thread Collin Funk
-16 Collin Funk + + gnulib-tool.py: Follow gnulib-tool changes, part 60. + Follow gnulib-tool change + 2019-11-18 Bruno Haible + gnulib-tool: Fix build error on macOS with --conditional-dependencies. + * pygnulib/GLModuleSystem.py (GLModuleTable.add_dummy): Ignore modules + that are conditiona

Re: gnulib-tool.py: Follow gnulib-tool changes, part 59.

2024-03-16 Thread Bruno Haible
Collin Funk wrote: > This patch just modifies the timestamp of 'config.h.in' after > executing 'autoheader'. > > I've used the Pathlib touch function which I will admit looks a bit > strange [1]. I've tested it and it should update the timestamps > properly though. Thanks! Applied. I see

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-16 Thread Bruno Haible
Hi Collin, > From > experimenting, I've confirmed that calling an invalid program will > throw 'FileNotFoundError'. Other errors should fail loudly so they are > not ignored. Yes, that's how exception-related programming should be done. Thanks. Applied. Bruno

gnulib-tool.py: Follow gnulib-tool changes, part 59.

2024-03-16 Thread Collin Funk
ATCH] gnulib-tool.py: Follow gnulib-tool changes, part 59. Follow gnulib-tool change 2017-10-29 Bruno Haible gnulib-tool: Avoid unnecessary config.h.in remaking in testdirs. * pygnulib/GLTestDir.py (GLTestDir.execute): Touch the 'config.h.in' file after executing 'autoheader' to update it'

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-16 Thread Collin Funk
Hi Bruno, On 3/16/24 9:22 AM, Bruno Haible wrote: > I don't know. Maybe it is related to > https://stackoverflow.com/questions/16981921/relative-imports-in-python-3 ? The import stuff always caused me issues in the past when I used Python. The way we have it now works so I will continue to use

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-16 Thread Bruno Haible
Hi Collin, > This is somewhat related since it deals with imports, but is there a > reason why we don't just import things from modules directly? > > Right now we have: > > from . import constants > # Define global constants. > APP = constants.APP > DIRS = constants.DIRS

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-16 Thread Collin Funk
Hi Bruno, On 3/16/24 6:14 AM, Bruno Haible wrote: > Oh, I had not seen that the use of 'classes.' was so inconsistent. > Haven't made up my mind yet, regarding when 'classes.' should be used or not. This is somewhat related since it deals with imports, but is there a reason why we don't just

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-16 Thread Bruno Haible
Hi Collin, > Let me know how this looks. I've imported CopyAction to main and use > that in a similar way to what you wrote. Nice work. Thanks! Applied. > I've used the name copymode instead of copyaction to match > gnulib-tool.sh. Yes, good. I had forgotten about the distinction between

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-15 Thread Collin Funk
f94b28db067de7d83ccb4630de2e1c4227 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Fri, 15 Mar 2024 19:58:27 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58. Follow gnulib-tool change 2017-05-21 Bruno Haible gnulib-tool: Add options to create hard links. *

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-15 Thread Bruno Haible
Hi Collin, > This patch implements --hardlink and --local-hardlink. Thanks; that's major (and tricky), indeed. > Notice the arguments '-s --hardlink --symlink -h'. I tried to make > sure gnulib-tool.py behaved similarly to gnulib-tool.sh in this case. > > I beleive the correct behavior is to

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 58.

2024-03-15 Thread Collin Funk
hink that covers all of the strange hackery for this patch. [1] https://docs.python.org/3/library/argparse.html CollinFrom 3eeea5b376c5e0eceb5378bbbc3876ddbfbdca7c Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Fri, 15 Mar 2024 06:38:48 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 57.

2024-03-15 Thread Bruno Haible
Collin Funk wrote: > Oops, in the commit before I added some comments directly from > gnulib-tool to main.py as well. Feel free to change them No hurry, no problem. Such comments can stay as they are, in the short term. Bruno

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 57.

2024-03-14 Thread Collin Funk
Hi Bruno, On 3/14/24 7:23 PM, Bruno Haible wrote: > Thanks! Applied, with a tiny comment change: I removed the dollars from > # Remove $handledmodules from $inmodules. Oops, in the commit before I added some comments directly from gnulib-tool to main.py as well. Feel free to change them if

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 57.

2024-03-14 Thread Bruno Haible
Hi Collin, > This patch implements the --extract-recursive-link-directive and > --extract-recursive-link-directive options. Thanks! Applied, with a tiny comment change: I removed the dollars from # Remove $handledmodules from $inmodules. Bruno

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 57.

2024-03-14 Thread Collin Funk
rim > test-shell 2>&1 git diff --no-index test-python test-shell CollinFrom 6847254ed7ed967725f90755962034af10147996 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Thu, 14 Mar 2024 18:41:05 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 57. Follow gnulib-tool chang

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 56.

2024-03-12 Thread Bruno Haible
Hi Collin, > This patch adds the reminders to use AC_PROG_CC macro instead of > the obsolete AC_PROG_CC_STDC or AC_PROG_CC_C99. > > This change is pretty small so it seemed like a good place to remove > the exit() from GLImport.execute(). Nice! Thanks, patch applied. > The only spooky line is:

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 56.

2024-03-12 Thread Collin Funk
[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 56. Follow gnulib-tool change 2021-04-26 Paul Eggert gnulib-tool: port better to current Autoconf * pygnulib/GLImport.py (GLImport.execute): Remove exit() call before printing reminders. Suggest replacing AC_PROG_CC_STDC and AC_PROG_CC_C99,

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 55.

2024-03-12 Thread Bruno Haible
Collin Funk wrote: > I've attached a fix. Thanks! Applied. Bruno

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 55.

2024-03-12 Thread Collin Funk
ter we want to print. + 2024-03-12 Collin Funk gnulib-tool.py: Follow gnulib-tool changes, part 55. diff --git a/pygnulib/GLEmiter.py b/pygnulib/GLEmiter.py index c403df6141..bd678fc4af 100644 --- a/pygnulib/GLEmiter.py +++ b/pygnulib/GLEmiter.py @@ -617,9 +617,9 @@ USE_MS

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 55.

2024-03-12 Thread Collin Funk
Hi Bruno, On 3/12/24 9:52 AM, Bruno Haible wrote: > It works well in this case. But it becomes hairy when, in the mixed > autoconf/shell code that is emitted, there is a shell variable reference > ${foo} > because Python will interpret this as a reference to the Python variable > foo.

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 55.

2024-03-12 Thread Bruno Haible
Collin Funk wrote: > I've attached a pretty simple patch that fixes an item in > gnulib-tool.py.TODO. It fixes a lot of the remaining lines in the diff > between gnulib-tool and gnulib-tool.py which is nice. Thanks! Applied. > I decided to change GLEmiter.initmacro_end to use f-strings. It seems

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 55.

2024-03-11 Thread Collin Funk
ell and checked with and without --libtool since that affects the output of a change in GLEmiter.initmacro_end. CollinFrom 5afda4bcd2671f6c62fb5d067c58d398123830f0 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Mon, 11 Mar 2024 18:50:28 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-11 Thread Collin Funk
Hi Bruno, On 3/11/24 4:32 AM, Bruno Haible wrote: > Another GNU package in the same realm is GNU Bison. If you like regular > expression and automata theory, you will like GNU Bison as well. Thanks for the suggestion. I've never gotten around to using YACC or GNU Bison, surprisingly. I'll find

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 53, 54.

2024-03-11 Thread Collin Funk
On 3/11/24 5:37 AM, Bruno Haible wrote: > There is a pitfall with the list.join('\n') idiom: it's mainly designed for > non-empty lists. I therefore add the patch below. Ah, I see what you mean. I didn't even think of this case... Good catch. Thanks. Collin

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 52.

2024-03-11 Thread Collin Funk
On 3/11/24 4:57 AM, Bruno Haible wrote: > This looks good to me. 'sed' accepts POSIX BREs, where '(' and '[' stand for > the literal '(' and '[' characters unless escaped. Thanks for double checking for me. > Also, I applied the attached follow-up, in order to make the logic of the code > easier

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 53, 54.

2024-03-11 Thread Bruno Haible
Hi Collin, > > - A function _eliminate_NMD_from_line that takes a single line as argument > > and return a line or None. > > - A function _eliminate_NMD that invokes _eliminate_NMD_from_line on each > > line of the snippet, and combines the results? > > I tried to implement it as you

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 52.

2024-03-11 Thread Bruno Haible
port.py (GLImport.__init__): Reorder assignments and + conditions slightly. + 2024-03-11 Collin Funk gnulib-tool.py: Follow gnulib-tool changes, part 52. diff --git a/pygnulib/GLImport.py b/pygnulib/GLImport.py index de2961c55e..1dabccd201 100644 --- a/pygnulib/GLImport.py +++ b/pygnulib/GLImpor

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-11 Thread Bruno Haible
Hi Collin, > The POSIX BRE vs. ERE along with backreferences, assertions, lazy vs. > greedy matching allowed by some languages adds multiple layers of > complexity which starts to hurt my brain. :) Yes, the many variants of regular expressions are complicated... > The DFA module also looks

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 53, 54.

2024-03-11 Thread Collin Funk
docs.python.org/3/tutorial/datastructures.html#list-comprehensions [2] https://docs.python.org/3/library/__future__.html CollinFrom 49596fc1f103f5bdff2529c3506c6eb783f4de4d Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Mon, 11 Mar 2024 00:06:18 -0700 Subject: [PATCH 3/4] gnulib-tool.py: Follow gnulib-tool chan

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 52.

2024-03-10 Thread Collin Funk
not do it this patch since it would make the changes harder to follow. CollinFrom c0772b3fe45a61dc686ce945e6decfb7ff4a84c4 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sun, 10 Mar 2024 21:50:59 -0700 Subject: [PATCH 2/2] gnulib-tool.py: Follow gnulib-tool changes, part 52. Follow gnulib-tool chang

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-10 Thread Collin Funk
Hi Bruno, On 3/10/24 3:51 PM, Bruno Haible wrote: > I prefer comparing with '' explicitly. It's clearer about the intent. > It avoids an implicit conversion from str to bool. Sure, makes sense. I'll keep that in mind in the future. > Regarding the regex change: In a group '(...)' one needs to

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-10 Thread Bruno Haible
Hi Collin, > Hopefully this patch should be better. Thanks, much better. I applied it, together with this follow-up: 2024-03-10 Bruno Haible gnulib-tool.py: Tweak last commit. * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Avoid an implicit str to bool conversion.

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-10 Thread Collin Funk
p.org/onlinepubs/9699919799/utilities/test.html CollinFrom ef34572ca72ad1bb825dcae17b1472db63c779d3 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sun, 10 Mar 2024 14:07:35 -0700 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51. Follow gnulib-tool change 2021-12-15 Br

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 53, 54.

2024-03-10 Thread Collin Funk
Hi Bruno, > Also, please don't drop comments that are present in the original code, such > as: > > # Replace NMD, so as to remove redundant "$(MKDIR_P) '.'" invocations. > # The logic is similar to how we define gl_source_base_prefix. Sure. I remember seeing that comment in the shell

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 53, 54.

2024-03-10 Thread Bruno Haible
Hi Collin, Re 0003 (part 53): In the function _eliminate_NMD, the list accumulation expressions are a bit complex. Here, I feel, a better indentation is not even enough. Can you refactor this as follows: - A function _eliminate_NMD_from_line that takes a single line as argument and return a

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 52.

2024-03-10 Thread Bruno Haible
Hi Collin, This one looks good, except please reformat the line automake_options = {x for y in configure_ac_automake_options for x in y.split()} as suggested for part 51. Bruno

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-10 Thread Bruno Haible
Hi Collin, > I've implemented the initial support for --automake-subdir in > gnulib-tool.py. It is a larger patch so let me know if you have any > questions. Thanks. Though, it would be nice to improve a couple of things: 1) This form of conditional expression base =

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 53, 54.

2024-03-10 Thread Collin Funk
05b9fa Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sun, 10 Mar 2024 00:43:20 -0800 Subject: [PATCH 3/5] gnulib-tool.py: Follow gnulib-tool changes, part 53. Follow gnulib-tool change 2021-12-21 Bruno Haible Optimize redundant 'mkdir -p .' invocations. * pygnulib/GLEmiter.py (_eliminate_NMD

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 52.

2024-03-09 Thread Collin Funk
done soon. CollinFrom 081643519481b02362cbc5a9530e13aba2bfcb9b Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Sat, 9 Mar 2024 20:05:10 -0800 Subject: [PATCH 2/2] gnulib-tool.py: Follow gnulib-tool changes, part 52. Follow gnulib-tool change 2021-12-15 Bruno Haible automake-subdir support: Look for

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51.

2024-03-09 Thread Collin Funk
: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 51. Follow gnulib-tool change 2021-12-15 Bruno Haible Accommodate non-recursive Automake in a less hacky way. * pygnulib/GLConfig.py (GLConfig.__init__): Add 'automake_subdir' to the parameter list. (GLConfig.default): Set t

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 50.

2024-03-09 Thread Bruno Haible
Hi Collin, > Assuming that there are no other issues with this patch There are no issues :) > can you check > the commit message and ChangeLog entry before pushing? I noticed that > the ChangeLog entry disagrees with the git log and gnulib-tool.py.TODO > for one of the commits. I'm new to the

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 49.

2024-03-09 Thread Bruno Haible
> > another TODO item referencing a separate patch needed for > > test-driver distributed with a specific version of Automake. ... > > Patch for this attached as promised. Thanks; applied. Bruno

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 50.

2024-03-09 Thread Collin Funk
02 -0800 Subject: [PATCH 3/3] gnulib-tool.py: Follow gnulib-tool changes, part 50. Follow gnulib-tool changes 2021-12-12 Bruno Haible gnulib-tool: Try to support non-recursive-gnulib-prefix-hack with tests. 2021-12-13 Bruno Haible gnulib-tool: Fix mistake in last commit. * pygnulib/GLImpo

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 48.

2024-03-09 Thread Bruno Haible
Hi Collin, > Here is a patch removing one more item from gnulib-tool.py.TODO. Thanks! Applied. > I saw another TODO item referencing a separate patch needed for > test-driver distributed with a specific version of Automake. Yes; that one will be an easy extension of what you added today. > It

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 49.

2024-03-08 Thread Collin Funk
figured I'd mention it in case this > test fails due to that issue. Patch for this attached as promised. CollinFrom 9a17a6ddaab49f0b9e5c70421db97a5d5cd5d0af Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Fri, 8 Mar 2024 22:30:03 -0800 Subject: [PATCH 2/2] gnulib-tool.py: Follow gnulib-tool c

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 48.

2024-03-08 Thread Collin Funk
d1ea931648a Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Fri, 8 Mar 2024 20:59:16 -0800 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 48. Follow gnulib-tool change 2019-01-23 Bruno Haible gnulib-tool: Support running testdirs on Android. * pygnulib/GLError.py (G

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 47.

2024-03-08 Thread Collin Funk
On 3/8/24 4:02 AM, Bruno Haible wrote: > Thanks for mentioning this; I did not know about this property of 'import *' > statements. I didn't know about the import property until recently either. I always knew of the naming convention though. I don't think we use 'import *' anywhere and I tend to

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 47.

2024-03-08 Thread Bruno Haible
Hi Collin, > Here is a patch that implements the '%reldir%' replacements when > generating GNU Make output instead of Automake. It seems fairly > straightforward unless I missed something. Thanks. I applied both patches. > Side note, I would like to start making the code _slightly_ more >

[PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 47.

2024-03-08 Thread Collin Funk
escriptive-naming-styles CollinFrom 9f290777ec05cb5e81d77d54b69cd68b68fbcf49 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Fri, 8 Mar 2024 01:43:26 -0800 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 47. Follow gnulib-tool changes 2021-12-15 Bruno Haible Fix creatio

Re: gnulib-tool.py: Follow gnulib-tool changes, part 45, 46.

2024-03-07 Thread Bruno Haible
Hi Collin, > Hi, here is two patches. The first implements the > '--tests-makefile-name' options. Are there any packages that use this > option? I couldn't seem to find anything from Debian and GitHub code > search outside of Gnulib itself or mirrors. Yes, so far,

gnulib-tool.py: Follow gnulib-tool changes, part 45, 46.

2024-03-06 Thread Collin Funk
-tool.py: Follow gnulib-tool changes, part 45. Follow gnulib-tool changes 2021-12-12 Bruno Haible gnulib-tool: Support different basenames for the lib/,tests/ Makefiles. 2022-01-08 Bruno Haible gnulib-tool: Fix "Don't forget" messages (regression 2021-12-12). * pygnulib/GLConfig.p

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Collin Funk
Hi Bruno, On 3/6/24 3:22 AM, Bruno Haible wrote: > Thanks, applied. (With an extra newline, just to make it clear that the > %s/%s/%s.%s arguments are the same in all three cases. Could be simplified > in the future, but that's not a priority now.) I assumed the intent of the original code was

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Bruno Haible
Hi Collin, > While running that I noticed this in gltests/Makefile.am: > > -LDADD = ../gllib/libgnu.a libtests.a ../gllib/libgnu.a > +LDADD = ../gllib/libgnu.a > > I've copied the logic for this from gnulib-tool and the attached patch > fixes this. Thanks, applied. (With an extra newline, just

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Bruno Haible
Collin Funk wrote: > These two patches add the notice banners when running 'make all' and > 'make check'. Thanks! Applied. Bruno

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Collin Funk
b/ChangeLog @@ -1,3 +1,9 @@ +2024-03-06 Collin Funk + + gnulib-tool.py: Fix value of LDADD for libtests. + * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Fix value of LDADD + to match gnulib-tool. + 2024-03-06 Collin Funk gnulib-tool.py: Follow gnulib-tool changes, part 44

Re: gnulib-tool.py: Follow gnulib-tool changes, part 42.

2024-03-06 Thread Bruno Haible
Collin Funk wrote: > Here is two patches. The first fixes on item in gnulib-tool.py.TODO. Thanks. Applied. Since I misunderstood the 'gentests' description when I read it, I'm clarifying it. > I thought I remembered seeing a good test case for this on the mailing > list but the archives seem to

gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Collin Funk
the dummy module and the tests are vc-list-files. CollinFrom 1ec490bdc80f64d63ce7177114fcecfc50d460db Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Tue, 5 Mar 2024 23:47:08 -0800 Subject: [PATCH 3/4] gnulib-tool.py: Follow gnulib-tool changes, part 43. Follow gnulib-tool change 2021-06-10 Bruno

gnulib-tool.py: Follow gnulib-tool changes, part 42.

2024-03-05 Thread Collin Funk
: [PATCH 1/2] gnulib-tool.py: Follow gnulib-tool changes, part 42. Follow gnulib-tool change 2019-02-15 Bruno Haible gnulib-tool: Support --import with just a few tests, not --with-tests. * pygnulib/GLImport.py (GLImport.execute): Use 'gentests' instead of 'inctests' when generating files

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 41.

2024-03-05 Thread Bruno Haible
Collin Funk wrote: > I've attached a patch that uses the condition: > > if dictionary['var'] == 'SUBDIRS' and dictionary['dotfirst']: > > which should match the original commit. Yes, this looks good. Applied; thanks! Bruno

Re: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 41.

2024-03-05 Thread Collin Funk
rst']: which should match the original commit. CollinFrom c7257b6ae39c23425db09fff5a6dcf0fae45de01 Mon Sep 17 00:00:00 2001 From: Collin Funk Date: Tue, 5 Mar 2024 16:30:20 -0800 Subject: [PATCH] gnulib-tool.py: Follow gnulib-tool changes, part 41. Follow gnulib-tool chang

  1   2   >