versionbump

module
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 11, 2019 License: Apache-2.0

README

versionbump

versionbump is a tool to automatically bump version contained in a file.

Usage

% versionbump --help
Usage:
    versionbump (major|minor|patch) [--checktags] <file>
    versionbump list <file>

Options:
    -h --help       Show this screen.
    --version       Show version.
    -c --checktags  Avoid bumping if current version is not tagged.
    <file>          Name of file.
    major           major bump.
    minor           minor bump.
    patch           patch bump.
    list            Show version from file.

Examples

Minor Version Bump

% cat ./VERSION
1.0.0
% versionbump minor ./VERSION 
% cat ./VERSION
1.1.0

Version Embeded in a Makefile

# Makefile
PROJECT = someproject
COMMITSHA = $(shell git rev-parse --short HEAD)
VERSION = 2.1.0 

release:
    git tag $(VERSION)
    git push --tags

Update Version

versionbump list ./Makefile
2.1.0
versionbump major ./Makefile
versionbump list ./Makefile
3.0.0
# Makefile
PROJECT = someproject
COMMITSHA = $(shell git rev-parse --short HEAD)
VERSION = 3.0.0 

release:
    git tag $(VERSION)
    git push --tags

Directories

Path Synopsis
cmd
versionbump
This file is generated do not edit
This file is generated do not edit
pkg
versionbump
Code to automatically bump versions
Code to automatically bump versions

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL