-
Notifications
You must be signed in to change notification settings - Fork 0
/
howto.txt
103 lines (100 loc) · 3.58 KB
/
howto.txt
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
* Release checklist
- Run twice
$ make pre-commit
- Remove old branches
$ git branch
$ git branch -D [branch name]
- Check that the current virtualenv is activated and matches the current branch
- Sanitize a semantic version str
$ python src/drain_swamp/cli_igor.py pretag "1.0.0"
- Check current version. Do not use, `python setup.py --version`
Initial version, manually edit _version.py
$ [means to initialize _version.py needed]
or for pre-release or post-release development versions
$ python src/drain_swamp/cli_igor.py current
If not in dev mode, in venv, update ``[prog name]._version.py`` as needed
- What would the next version be?
Do not use if initial version like, ``v1.0.1-1-g3893340``
$ python src/drain_swamp/cli_igor.py cheats --kind="tag"
or
$ python src/drain_swamp/cli_igor.py cheats --kind="current"
- start branch for release work
$ make relbranch
- Edit supported Python version numbers. Search for "PYVERSIONS".
- README.rst
- docs/index.rst
- Update sphinx conf.py CHANGES.rst, and NOTICE.txt with release facts. Supply "next version":
Seed CHANGES.rst
$ python src/drain_swamp/cli_igor.py seed
Edit CHANGES.rst, NOTICE.txt and docs/conf.py
$ python src/drain_swamp/cli_igor.py edits --kind="1.0.0"
or
$ python src/drain_swamp/cli_igor.py edits --kind="current"
If doc?/conf.py snippet has a snippet id
$ python src/drain_swamp/cli_igor.py edits --kind="1.0.0" --snip="snippet_id"
- Look over CHANGES.rst
Takes time. Rewrite commit messages to be accessible by normies. Rewrite it again.
- Update README.rst
- "New in x.y:"
- Update docs
- IF PRE-RELEASE:
- Version of latest stable release in docs/index.rst
- Make sure the docs are cogged:
$ make prebuild
- Don't forget the man page: docs/drain-swamp.1.txt
- Check that the docs build correctly:
$ tox -e docs
or
$ cd docs && make doctest; cd - &>/dev/null
$ cd docs && make linkcheck; cd - &>/dev/null
$ cd docs && make html; cd - &>/dev/null
$ cd docs && make pdf; cd - &>/dev/null
- tox will affect _version.py, revert version str back to tagged version
- commit the release-prep changes
$ make relcommit1
or
$ git status
$ git add [whatever]
$ git commit -S -m ""
- Done with changes to source files
- check them in on the release prep branch
- wait for ci to finish
- merge to master
$ git branch
$ git switch master
$ git merge -S -m "Your merge commit message" [source_branch]
- Check web connection then push. Don't trigger a release until a tag push
- check build sdist **BEFORE** push. Catch issues in build backend
$ git push
- Start the kits:
- Build drain-swamp
$ python -m build -C--kind="1.0.0" -C--set-lock="0"
- Build other package
$ export DS_CONFIG_SETTINGS=/tmp/setuptools-build.toml
$ cat <<-EOF > "$DS_CONFIG_SETTINGS"
[project]
name = "whatever"
version = "99.99.99a1.dev6"
[tool.config-settings]
kind="1.0.0"
set-lock="0"
EOF
$ python -m build
- Build drain-swamp as-is
$ export DS_CONFIG_SETTINGS=/tmp/setuptools-build.toml
$ cat <<-EOF > "$DS_CONFIG_SETTINGS"
[project]
name = "whatever"
version = "99.99.99a1.dev6"
[tool.config-settings]
kind="tag"
set-lock="0"
EOF
$ python -m build
Trigger the kit GitHub Action (no CI integration yet)
$ make kits_build (make debug=1 prep_kit)
- Tag the tree
$ make tag
or
$ git tag -as -m "Version 1.0.0" 1.0.0
# git push --follow-tags