Skip to content

Commit 4bc887d

Browse files
committed
updated_version.sh prints the current version if no args are given.
1 parent 434768d commit 4bc887d

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

update_version.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
#!/bin/sh
2-
if [ -z $1 ]; then echo "error: $0 needs a version number as argument."; fi
3-
sed -i "s/^__version__.*/__version__ = '$1'/g" dropbox/dropbox.py
2+
if [ -z $1 ]; then
3+
echo "error: $0 needs a version number as argument. Current version: `python -c 'import dropbox; print(dropbox.__version__)'`";
4+
else
5+
sed -i "s/^__version__.*/__version__ = '$1'/g" dropbox/dropbox.py
6+
fi

0 commit comments

Comments
 (0)