Skip to content

Commit 20f0db8

Browse files
committed
update makefile
1 parent 98a3a81 commit 20f0db8

File tree

3 files changed

+39
-10
lines changed

3 files changed

+39
-10
lines changed

Makefile

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -167,34 +167,34 @@ publish: dist publish-confirm ## package and upload a release
167167
bumpversion-release: ## Merge main to stable and bumpversion release
168168
git checkout stable || git checkout -b stable
169169
git merge --no-ff main -m"make release-tag: Merge branch 'main' into stable"
170-
bumpversion release
170+
bump-my-version bump release
171171
git push --tags origin stable
172172

173173
.PHONY: bumpversion-release-test
174174
bumpversion-release-test: ## Merge main to stable and bumpversion release
175175
git checkout stable || git checkout -b stable
176176
git merge --no-ff main -m"make release-tag: Merge branch 'main' into stable"
177-
bumpversion release --no-tag
177+
bump-my-version bump release --no-tag
178178
@echo git push --tags origin stable
179179

180180
.PHONY: bumpversion-patch
181181
bumpversion-patch: ## Merge stable to main and bumpversion patch
182182
git checkout main
183183
git merge stable
184-
bumpversion --no-tag patch
184+
bump-my-version bump patch --no-tag
185185
git push
186186

187187
.PHONY: bumpversion-candidate
188188
bumpversion-candidate: ## Bump the version to the next candidate
189-
bumpversion candidate --no-tag
189+
bump-my-version bump candidate --no-tag
190190

191191
.PHONY: bumpversion-minor
192192
bumpversion-minor: ## Bump the version the next minor skipping the release
193-
bumpversion --no-tag minor
193+
bump-my-version bump minor --no-tag
194194

195195
.PHONY: bumpversion-major
196196
bumpversion-major: ## Bump the version the next major skipping the release
197-
bumpversion --no-tag major
197+
bump-my-version bump major --no-tag
198198

199199
.PHONY: bumpversion-revert
200200
bumpversion-revert: ## Undo a previous bumpversion-release

deepecho/version/__init__.py

Lines changed: 0 additions & 2 deletions
This file was deleted.

pyproject.toml

Lines changed: 33 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ dev = [
5252

5353
# general
5454
'setuptools<49.2',
55-
'bumpversion>=0.5.3,<0.6',
55+
'bump-my-version>=0.18.3,<1',
5656
'pip>=9.0.1',
5757
'watchdog>=0.8.3,<0.11',
5858

@@ -122,7 +122,7 @@ namespaces = false
122122
]
123123

124124
[tool.setuptools.dynamic]
125-
version = {attr = 'deepecho.version.__version__'}
125+
version = {attr = 'deepecho.__version__'}
126126

127127
[tool.isort]
128128
include_trailing_comment = true
@@ -135,6 +135,37 @@ use_parentheses = true
135135
[tool.pytest.ini_options]
136136
collect_ignore = ['pyproject.toml']
137137

138+
[tool.bumpversion]
139+
current_version = '0.5.1'
140+
parse = '(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)'
141+
serialize = [
142+
'{major}.{minor}.{patch}-{release}{candidate}',
143+
'{major}.{minor}.{patch}'
144+
]
145+
search = '{current_version}'
146+
replace = '{new_version}'
147+
regex = false
148+
ignore_missing_version = false
149+
tag = true
150+
sign_tags = false
151+
tag_name = 'v{new_version}'
152+
tag_message = 'Bump version: {current_version} → {new_version}'
153+
allow_dirty = false
154+
commit = true
155+
message = 'Bump version: {current_version} → {new_version}'
156+
commit_args = ''
157+
158+
[tool.bumpversion.parts.release]
159+
values = [
160+
'dev',
161+
'release'
162+
]
163+
optional_value = 'release'
164+
165+
[tool.bumpversion.files]
166+
pyproject.toml = {search = 'current_version="{current_version}"', replace = 'current_version="{new_version}"'}
167+
"deepecho/__init__.py" = {search = '__version__ = "{current_version}"', replace = '__version__ = "{new_version}"'}
168+
138169
[build-system]
139170
requires = ['setuptools', 'wheel']
140171
build-backend = 'setuptools.build_meta'

0 commit comments

Comments
 (0)