This repository was archived by the owner on Aug 25, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +15
-2
lines changed
Expand file tree Collapse file tree 1 file changed +15
-2
lines changed Original file line number Diff line number Diff line change 99import getpass
1010import tempfile
1111import importlib
12+ import subprocess
1213import contextlib
1314import configparser
1415import pkg_resources
@@ -530,8 +531,17 @@ async def run(self):
530531 )
531532 main_package = pathlib .Path (main_package )
532533 skel = main_package / "dffml" / "skel"
534+ version_files = map (
535+ lambda path : pathlib .Path (* path .split ("/" )).resolve (),
536+ filter (
537+ bool ,
538+ subprocess .check_output (["git" , "ls-files" , "*/version.py" ])
539+ .decode ()
540+ .split ("\n " ),
541+ ),
542+ )
533543 # Update all the version files
534- for version_file in main_package . rglob ( "**/version.py" ) :
544+ for version_file in version_files :
535545 # Ignore skel
536546 if skel in version_file .parents :
537547 self .logger .debug (
@@ -542,7 +552,10 @@ async def run(self):
542552 # check we're in the right package, skip if not.
543553 setup_filepath = version_file .parent .parent / "setup.py"
544554 with chdir (setup_filepath .parent ):
545- name = SetupPyKWArg .get_kwargs (setup_filepath )["name" ]
555+ try :
556+ name = SetupPyKWArg .get_kwargs (setup_filepath )["name" ]
557+ except Exception as error :
558+ raise Exception (setup_filepath ) from error
546559 if self .only and name not in self .only :
547560 self .logger .debug (
548561 "Verison file not in only %s" , version_file
You can’t perform that action at this time.
0 commit comments