A feature-rich command-line audio/video downloader
[devscripts/release] Check version number
Philipp Hagemeister4c0941853a71
diff --git a/devscripts/release.sh b/devscripts/release.shindex aa3119c424..2974a7c3ee 100755--- a/devscripts/release.sh+++ b/devscripts/release.sh@@ -22,6 +22,12 @@ fiif [ -z "$1" ]; then echo "ERROR: specify version number like this: $0 1994.09.06"; exit 1; fiversion="$1"+major_version=$(echo "$version" | sed -n 's#^\([0-9]*\.[0-9]*\.[0-9]*\).*#\1#p')+if test "$major_version" '!=' "$(date '+%Y.%m.%d')"; then+ echo "$version does not start with today's date!"+ exit 1+fi+if [ ! -z "`git tag | grep "$version"`" ]; then echo 'ERROR: version already present'; exit 1; fiif [ ! -z "`git status --porcelain | grep -v CHANGELOG`" ]; then echo 'ERROR: the working directory is not clean; commit or stash changes'; exit 1; fiuseless_files=$(find youtube_dl -type f -not -name '*.py')