tag-release
I'm tired of looking up the correct tag name to use, hence this script. It follows the semantic versioning rules. Should work with any semi-recent Python version.
Installation
- Python: PyPI
- Arch Linux: AUR
- Ubuntu: PPA
- Alternatively, just clone this repo and run
src/release.pyinstead oftag-release.
Usage
-
View usage info:
tag-release -h -
Make a new patch version release in the current repo. Tries to parse the latest tag (say, v2.1.3) and will add a new tag (in this case, v2.1.4).
tag-release patch -
Make a new minor version release in the current repo (v2.1.3 -> v2.2.0):
tag-release minor -
Similar for major versions (v2.1.3 -> v3.0.0):
tag-release major -
Accepts path to repository as an optional argument:
tag-release patch path/to/your/repo -
You can customize the version prefix ("v" by default). It will search for the latest tag with the given prefix then. For example, this command, given that tag "2.1.3" exists, will create tag "2.1.4":
tag-release -p '' patch -
A prefix can be anything, basically; this will create tag "release/v2.2.0" if the latest tag is "release/v2.1.3":
tag-release -p 'release/v' minor -
If no tags were found, the implicit version 0.0.0 is assumed. In a repository with no matching tags, this will create tag "v1.0.0":
tag-release major -
Customize the tag message:
tag-release -m 'Release: version {}' patch -
You can "retag" parent versions. For example, given that the latest tag is "v1.1.3", this will create/update tags "v1" & "v1.1" to point to the new tag "v1.1.4":
tag-release -r patch -
Push new/updated tags automatically using
--push(retagged tags are pushed forcefully):tag-release -u patch -
Create lightweight tags, if you wish (using annotated tags, which is the default, is almost always the preferred option):
tag-release -l patch
License
Distributed under the MIT License. See LICENSE.txt for details.
Metadata
Release files for git-tag-release 1.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| git_tag_release-1.0.4.tar.gz | 14.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| git_tag_release-1.0.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 23.1 kB
Release files / git_tag_release-1.0.4.tar.gz
| Download URL | git_tag_release-1.0.4.tar.gz |
|---|---|
| Size | 14.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
30ebb22c9cd0b9fb05712ec6391a935668026931b966f9031263e4f5f8d9cf2d
|
|
BLAKE2b-256 checksum How to use checksums |
096c7530f7b3d5832c25d03a0267a3c3512671d6950b5819d37e0c2d92349ac1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / git_tag_release-1.0.4-py3-none-any.whl
| Download URL | git_tag_release-1.0.4-py3-none-any.whl |
|---|---|
| Size | 8.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
eb4018cf0fc1680047b69a71c56e4b747eee06b502d92e33ff460e2a6251be4f
|
|
BLAKE2b-256 checksum How to use checksums |
c46adf21e14c99a639d8f4ddb48887aae6a646e82fc95330a2f29b45746eaf0a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|