diff --git a/TODO b/TODO index c0153b8..2764923 100644 --- a/TODO +++ b/TODO @@ -2,7 +2,6 @@ Before new_layout branch merge ============================== * README.md update (pull-request #145) * Script to automatically update file contents: - version : ISSUE_TEMPLATE.md, version.py contributors : AUTHORS diff --git a/devscripts/bump-version.sh b/devscripts/bump-version.sh new file mode 100755 index 0000000..5640e85 --- /dev/null +++ b/devscripts/bump-version.sh @@ -0,0 +1,57 @@ +#!/bin/bash + +# Author: Sotiris Papadopoulos +# Last-Revision: 2017-04-17 +# Script to bump the version and automatically update related files +# +# Usage: ./bump_version.sh + +PACKAGE="youtube_dl_gui" + +FILES=`cat <" + exit 1 +fi + +cd .. + +new_version=$1 +cur_version=`grep version "$PACKAGE/version.py" | cut -d"'" -f2` + +echo "Current version = $cur_version" +echo "New version = $new_version" +echo + +if version_le $new_version $cur_version; then + echo "New version must be greater than the current version, exiting..." + exit 1 +fi + +for file in $FILES; do + update_version $cur_version $new_version $file +done + +echo "Done"