-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtbump.toml
53 lines (43 loc) · 1.25 KB
/
tbump.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# Uncomment this if your project is hosted on GitHub:
github_url = "https://github.com/softbutterfly/django-sb-simple-migrations"
[version]
current = "2.0.0"
# Example of a semver regexp.
# Make sure this matches current_version before
# using tbump
regex = '''
(?P<major>\d+)
\.
(?P<minor>\d+)
\.
(?P<patch>\d+)
(
-
(?P<channel>alpha|beta|rc)
(?P<release>\d+)
)?
'''
[git]
message_template = "Bump to {new_version}"
tag_template = "{new_version}"
[[file]]
src = 'pyproject.toml'
search = 'version = "{current_version}"'
[[file]]
src = 'pyproject.toml'
search = '{current_version}.tar.gz'
[[before_commit]]
name = "Update change log"
cmd = "sed -z \"s/## \\[Unreleased\\]/## [Unreleased]\\n\\n## [{new_version}] - $(date '+%Y-%m-%d')/g\" -i CHANGELOG.md"
[[before_commit]]
name = "Update version.py"
cmd = "echo $(echo \"{new_version}\" | sed -r 's/([0-9]+)\\.([0-9]+)\\.([0-9]+)/VERSION = (\"\\1\", \"\\2\", \"\\3\")/g') > culqi/version.py"
[[before_commit]]
name = "Update version.py"
cmd = "find ./tests/cassettes -type f -exec sed -i -e 's#Culqi-API-Python/{current_version}#Culqi-API-Python/{new_version}#g' {{}} \\;"
[[after_push]]
name = "Build package"
cmd = "poetry build"
[[after_push]]
name = "Publish to PyPI"
cmd = "poetry publish"