Skip to content

Commit c713dba

Browse files
authored
Fix _version.py file version bump (#207)
1 parent 8ec997e commit c713dba

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

scripts/bump_version.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,10 @@ def bump(force, skip_if_dirty, spec):
9696
f" expected __version__ assignment in the first line, found {variable}"
9797
)
9898
current = current.strip("'\"")
99-
version_spec = increment_version(current, spec)
99+
if spec in VERSION_SPEC:
100+
version_spec = increment_version(current, spec)
101+
else:
102+
version_spec = spec
100103
version_file.write_text(f'__version__ = "{version_spec}"\n')
101104

102105
# bump the local package.json file

0 commit comments

Comments
 (0)