From: Bruno Haible Date: Wed, 13 Nov 2024 01:36:11 +0000 (+0100) Subject: gnulib-tool.py: Fix logic of --remove-import option. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=e5f02da11eec307a10cad759bf7db74a656d89ac;p=gnulib.git gnulib-tool.py: Fix logic of --remove-import option. Reported by Gavin Smith in . * pygnulib/GLImport.py (GLImport.__init__): Compute the modules to keep correctly. --- diff --git a/ChangeLog b/ChangeLog index 6840768b00..b331423142 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2024-11-12 Bruno Haible + + gnulib-tool.py: Fix logic of --remove-import option. + Reported by Gavin Smith in + . + * pygnulib/GLImport.py (GLImport.__init__): Compute the modules to keep + correctly. + 2024-11-12 Bruno Haible bootstrap: Tweak GNULIB_REFDIR related changes. diff --git a/pygnulib/GLImport.py b/pygnulib/GLImport.py index 32ab54b29a..5d60bd908d 100644 --- a/pygnulib/GLImport.py +++ b/pygnulib/GLImport.py @@ -258,7 +258,7 @@ class GLImport: elif self.mode == MODES['remove-import']: modules = [ module for module in old - if module in new ] + if not module in new ] elif self.mode == MODES['update']: modules = self.cache.getModules()