remove old release script
This commit is contained in:
Родитель
d9ef9258a2
Коммит
b42648b701
|
@ -1,42 +0,0 @@
|
|||
#!/bin/bash
|
||||
# Tag and push a release.
|
||||
|
||||
set -e
|
||||
set -x
|
||||
|
||||
# Make sure we're in the project root.
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )"
|
||||
cd ${DIR}
|
||||
|
||||
# Build a new gem archive.
|
||||
rm -rf entitlements-*.gem
|
||||
|
||||
GEM_NAME='entitlements' gem build -q entitlements-app.gemspec
|
||||
gem build -q entitlements-app.gemspec
|
||||
|
||||
# Make sure we're on the main branch.
|
||||
|
||||
(git branch --no-color | grep -q '* main') || {
|
||||
echo "Only release from the main branch."
|
||||
exit 1
|
||||
}
|
||||
|
||||
# Figure out what version we're releasing.
|
||||
|
||||
tag=v`ls entitlements-app-*.gem | sed 's/^entitlements-app-\(.*\)\.gem$/\1/'`
|
||||
|
||||
# Make sure we haven't released this version before.
|
||||
|
||||
git fetch -t origin
|
||||
|
||||
(git tag -l | grep -q "$tag") && {
|
||||
echo "Whoops, there's already a '${tag}' tag."
|
||||
exit 1
|
||||
}
|
||||
|
||||
# Tag it and bag it.
|
||||
|
||||
gem push entitlements-app-*.gem && rm -f entitlements-app-*.gem
|
||||
gem push entitlements-*.gem && rm -f entitlements-*.gem
|
||||
git tag "$tag" && git push origin main && git push origin "$tag"
|
Загрузка…
Ссылка в новой задаче