From 760255fb70b3c10ff31d4a6720abe3bbb19c5475 Mon Sep 17 00:00:00 2001 From: Charles Tapley Hoyt Date: Fri, 25 Jan 2019 13:51:07 +0100 Subject: [PATCH] Add bumpversion configuration --- .bumpversion.cfg | 33 +++++++++++++++++++++++++++++++++ src/nrl/constants.py | 5 +++++ 2 files changed, 38 insertions(+) create mode 100644 .bumpversion.cfg create mode 100644 src/nrl/constants.py diff --git a/.bumpversion.cfg b/.bumpversion.cfg new file mode 100644 index 0000000..68ad4e6 --- /dev/null +++ b/.bumpversion.cfg @@ -0,0 +1,33 @@ +[bumpversion] +current_version = 0.0.1-dev +commit = True +tag = False +parse = (?P\d+)\.(?P\d+)\.(?P\d+)(?:-(?P[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+(?P[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))? +serialize = + {major}.{minor}.{patch}-{release}+{build} + {major}.{minor}.{patch}+{build} + {major}.{minor}.{patch}-{release} + {major}.{minor}.{patch} + +[bumpversion:part:release] +optional_value = production +first_value = dev +values = + dev + production + +[bumpverion:part:build] +values = [0-9A-Za-z-]+ + +[bumpversion:file:setup.cfg] +search = version = {current_version} +replace = version = {new_version} + +[bumpversion:file:docs/source/conf.py] +search = release = '{current_version}' +replace = release = '{new_version}' + +[bumpversion:file:src/nrl/constants.py] +search = VERSION = '{current_version}' +replace = VERSION = '{new_version}' + diff --git a/src/nrl/constants.py b/src/nrl/constants.py new file mode 100644 index 0000000..cdc0b1c --- /dev/null +++ b/src/nrl/constants.py @@ -0,0 +1,5 @@ +# -*- coding: utf-8 -*- + +"""Constants for NRL.""" + +VERSION = '0.0.1-dev'