diff --git a/opam-release.sh b/opam-release.sh new file mode 100755 index 0000000..78937d5 --- /dev/null +++ b/opam-release.sh @@ -0,0 +1,60 @@ +#!/usr/bin/env bash +set -e +# set -x + +if [ -z $1 ] || [ -z $2 ] || [ -z $3 ] || [ -z $4 ] || \ + [ $1 == "--help" ] || [ $1 == "-h" ] +then cat < $P/opam + echo "" >> $P/opam + echo "url {" >> $P/opam + echo " src: \"$URL\"" >> $P/opam + echo " checksum: \"sha256=$SUM\"" >> $P/opam + echo "}" >> $P/opam + + opam lint --check-upstream $P/opam + + git -C $COA add $P/opam +done +git -C $COA commit -m "Release $PROJECT $VERSION" +git -C $COA push origin -f $BRANCH + +echo "**********************************************************************" +echo "Create a pull request by visiting" +echo "https://github.com/$GITHUBUSER/opam-coq-archive/pull/new/$BRANCH" +echo "**********************************************************************"