Skip to content

Commit cdc6f51

Browse files
author
Ingo Fruend
committed
Automatic version bumps
1 parent c217b20 commit cdc6f51

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

Diff for: publish.sh

+13-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,19 @@
22

33
set -xe
44

5-
VERSION=$1
5+
cp setup.cfg setup.cfg_backup
6+
7+
function cleanup () {
8+
mv setup.cfg_backup setup.cfg
9+
}
10+
11+
trap cleanup ERR
12+
13+
# bump version
14+
sed -r 's/version = ([0-9]+)/echo "version = $((\1+1))"/e' setup.cfg > setup.cfg_new
15+
mv setup.cfg_new setup.cfg
16+
17+
VERSION=$(awk '/version = [0-9]+/ { print $3 }' setup.cfg)
618

719
SOURCEDIST=csvmodel-${VERSION}.tar.gz
820
BINDIST=csvmodel-${VERSION}-py3-none-any.whl

0 commit comments

Comments
 (0)