Commit 2244d34c authored by Francois-Rene Rideau's avatar Francois-Rene Rideau
Browse files

Tweak release scripts

parent 09b9b8a4
......@@ -18,9 +18,6 @@ lisp ?= sbcl
install: archive-copy
bump_revision: FORCE
bin/bump-revision-and-tag.sh
archive: FORCE
sbcl --userinit /dev/null --sysinit /dev/null --load bin/make-helper.lisp \
--eval "(rewrite-license)" --eval "(quit)"
......
......@@ -4,7 +4,7 @@
# exit code is 1 if it cannot be found
tag=`git describe --tags`
tag=`git describe --tags --match '[0-9].[0-9][0-9][0-9]'`
if [ "$tag" == "" ]; then
exit 1
fi
......
......@@ -4,7 +4,7 @@
# annotated tag
tag=`git describe --tags`
tag=`git describe --tags --match '[0-9].[0-9][0-9][0-9]'`
if [ "$tag" == "" ]; then
echo "Unable to find most recent tag, exiting"
exit 1
......
#!/bin/sh
# make sure that there are no pending comments
# make sure you're on master
branch=` git branch | grep "\* "`
if [ "$branch" != "* master" ]; then
echo "error: git branch is $branch, not master"
exit -1
fi
tag=`git describe --tag`
if [ "$tag" == "" ]; then
echo "error: git tag not found"
exit -1
fi
major=`expr //$tag : '//\(.*\)\.'`
minor=`expr //$tag : '.*\.\(.*\)'`
minor=`echo "$minor" | gawk -F - '{print $1}'`
if [ "$major" == "" ]; then
echo "error: unable to parse major version in $tag"
exit -1
fi
if [ "$minor" == "" ]; then
echo "error: unable to parse minor version in $tag"
exit -1
fi
bumped=`expr $minor + 1`
if [ ! "$?" == "0" ]; then
echo "Unable to compute new version from $minor"
exit -2
fi
new_version="$major.$bumped"
cp asdf.lisp asdf.bak
perl -pi -e "s/(\(asdf-version \")[^\"]*(\"\))/\${1}$new_version\${2}/" asdf.lisp
if [ ! "$?" == "0" ]; then
echo "Unable to perl replace version"
exit -3
fi
echo "Update reversion and commit"
git add asdf.lisp
if [ ! "$?" == "0" ]; then
echo "Unable to git add"
exit -4
fi
git commit -m "update ASDF version to $new_version"
if [ ! "$?" == "0" ]; then
echo "Unable to git commit"
exit -5
fi
bin/tag-release.sh $new_version
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment