Skip to main content

Bumps package version numbers

Project description

bump

Bumps package versions.

Example

By default, running bump in a directory with a setup.py will bump the “patch” number in place:

$ bump
1.0.1
$ git diff setup.py
─────────────────────────────────────────────────
modified: setup.py
─────────────────────────────────────────────────
@ setup.py:6 @ from setuptools import setup

setup(
    name='bump',
-    version='1.0.0',
+    version='1.0.1',
    description='Bumps package version numbers',
    long_description=open('README.rst').read(),
    license='MIT',

Conveniently bump will also return the new version number, so you can use it after running the command, for example:

$ export VERSION=`bump`
$ echo "The new version is $VERSION"
The new version is 1.0.1

Options

The bump command can also bump the major or minor version numbers, or set the pre-release identifier or local version segment:

$ bump --help
Usage: bump [OPTIONS] [INPUT] [OUTPUT]

Options:
  -M, --major     Bump major number
  -m, --minor     Bump minor number
  -p, --patch     Bump patch number
  --pre TEXT      Set the pre-release identifier
  --local TEXT    Set the local version segment
  --canonicalize  Canonicalize the new version
  --help          Show this message and exit.

You can configure these options by setting them in a .bump or setup.cfg configuration file as well, so you don’t have to specify them every time:

$ cat .bump
[bump]
input = some_directory/__file__.py
minor = true
patch = false

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bump-1.1.1.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

bump-1.1.1-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file bump-1.1.1.tar.gz.

File metadata

  • Download URL: bump-1.1.1.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.2 pkginfo/1.4.2 requests/2.19.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.25.0 CPython/3.7.0

File hashes

Hashes for bump-1.1.1.tar.gz
Algorithm Hash digest
SHA256 5f065d63f9c26eb0d2efb4ad7f2dead01a3d52e45f4eea10ae3eda9d259477d3
MD5 e29588ce8ef828f489866bbf54e5d074
BLAKE2b-256 986e7ccc06d1060c87654f1da9746e7a3ddc457f1ab4b57d0393fbd6ac2ec153

See more details on using hashes here.

File details

Details for the file bump-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: bump-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.2 pkginfo/1.4.2 requests/2.19.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.25.0 CPython/3.7.0

File hashes

Hashes for bump-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c733b255eb0e8118b2dd664be4f5aa14d3593b6dbd985367c0acf62da648455d
MD5 4bf9d24c4aa2ff69f2a033019b636b1f
BLAKE2b-256 967bb1af995d148e52ff5356ea9045cdaccad0d90d3e8f2879ae76f0170d0139

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page