gnulib-tool.py: Reduce code duplication in file name transformations.
commit9af79f662e6a8a07488ff5ec729b09599500531a
authorCollin Funk <collin.funk1@gmail.com>
Thu, 25 Apr 2024 22:30:29 +0000 (25 15:30 -0700)
committerCollin Funk <collin.funk1@gmail.com>
Fri, 26 Apr 2024 01:53:01 +0000 (25 18:53 -0700)
tree4febbe47f8ebe7922a59809fe250265050e13040
parent7941742a51e468b0f4ba07c395d0a46528352a81
gnulib-tool.py: Reduce code duplication in file name transformations.

* pygnulib/functions.py: New file for shared functions between modules.
Add a function based on functions removed from GLImport and GLTestDir.
Accepts a single file name instead of a list.
* pygnulib/GLImport.py (GLImport.prepare): Use the new function.
(GLImport.rewrite_new_files, GLImport.rewrite_old_files): Remove
functions.
* pygnulib/GLTestDir.py (GLTestDir.execute): Use the new function.
(GLTestDir.rewrite_files): Remove functions.
* pygnulib/main.py (main): Remove unused function import. Use the new
function.
ChangeLog
pygnulib/GLImport.py
pygnulib/GLTestDir.py
pygnulib/functions.py [new file with mode: 0644]
pygnulib/main.py