diff --git a/.bumpversion.cfg b/.bumpversion.cfg index 80df7fad..e39aa71a 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,7 +1,7 @@ [bumpversion] commit = True tag = True -current_version = 1.0.2-dev +current_version = 1.0.3 parse = (?P\d+)\.(?P\d+)\.(?P\d+)(\-(?P[a-z]+))? serialize = {major}.{minor}.{patch}-{release} diff --git a/CHANGELOG.md b/CHANGELOG.md index fd3c6908..21ffb3be 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,6 @@ **unreleased** +**v1.0.3** +**v1.0.3-dev** **v1.0.2-dev** **v1.0.1** diff --git a/bumpversion/__init__.py b/bumpversion/__init__.py index ce53557b..c44680b4 100644 --- a/bumpversion/__init__.py +++ b/bumpversion/__init__.py @@ -1,3 +1,3 @@ -__version__ = "1.0.2-dev" +__version__ = "1.0.3" __license__ = "MIT" __title__ = "bumpversion" diff --git a/bumpversion/cli.py b/bumpversion/cli.py index b107e10d..ce93e2e1 100644 --- a/bumpversion/cli.py +++ b/bumpversion/cli.py @@ -596,6 +596,7 @@ def _determine_vcs_dirty(possible_vcses, defaults): try: vcs.assert_nondirty() except WorkingDirectoryIsDirtyException as e: + vcs.commit_files_extended = e.message.split('\n')[1:] if not defaults["allow_dirty"]: logger.warning( "%s\n\nUse --allow-dirty to override this if you know what you're doing.", @@ -673,6 +674,15 @@ def _commit_to_vcs(files, context, config_file, config_file_exists, vcs, args, "Would prepare" if not do_commit else "Preparing", vcs.__name__, ) + + if hasattr(vcs, 'commit_files_extended'): + repr = re.compile('^(?P[A-Z]+\s)(?:\s*.*\s->\s)?(?P.*)$') + for path in vcs.commit_files_extended: + change = repr.match(path).groupdict() + filename = change.get('path').lstrip().rstrip() + if filename not in commit_files: + commit_files.append(filename) + for path in commit_files: logger.info( "%s changes in file '%s' to %s", diff --git a/setup.py b/setup.py index b1402ced..9fc8341f 100644 --- a/setup.py +++ b/setup.py @@ -12,7 +12,7 @@ setup( name='bump2version', - version='1.0.2-dev', + version='1.0.3', url='https://github.com/c4urself/bump2version', author='Christian Verkerk', author_email='christianverkerk@ymail.com',