Skip to content

lemz90/pubspec-version

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pubver

CLI tool to set/bump the version key in pubspec.yaml. Semver-compliant*.

Installing

You can install the package from the command line:

pub global activate pubspec_version

This will add the pubver binary to your ~/.pub-cache/bin.

Usage

Bumping the version

pubver bump <part>

where <part> can be either breaking, major, minor or patch.

Examples

Before Command After
1.2.3 pubver bump breaking 2.0.0
0.2.1 pubver bump breaking 0.3.0
0.2.1 pubver bump major 1.0.0
0.2.1 pubver bump minor 0.3.0
0.2.1 pubver bump patch 0.2.2

Setting the version

pubver set <version>

where <version> can be any arbitrary version.

Output

The tool prints the new version to stdout. This allows post processing, e.g. making a git commit.

git ci . -m "Release $(pubver bump breaking)"

*almost. It uses pub_semver which is a bit different.

About

A CLI tool to set/bump the `version` key in pubspec.yaml.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Dart 100.0%