I often find myself doing the following:
- Go to repo
- Open VERSION file
- Change the version number
- Add the file to git
- Commit with the message ‘Bump version to $1’
This is a tiny script which automates the above.
#!/bin/bash [ $# -eq 1 ] || exit echo $1 > VERSION git add VERSION git commit -m "Bump version to $1"
I generally alias this to something like
bump so I can quickly bump up the version number.
$ bump 1.4.1