mirror of
https://github.com/unpoller/unpoller.git
synced 2026-10-22 05:09:10 +02:00
Pass in build env from file.
This commit is contained in:
@@ -3,26 +3,27 @@
|
||||
# Deploys a new homebrew formula file to golift/homebrew-tap.
|
||||
# Requires SSH credentials in ssh-agent to work.
|
||||
# Run by Travis-CI when a new release is created on GitHub.
|
||||
APP=unpacker-poller
|
||||
|
||||
source ../.metadata.sh
|
||||
|
||||
if [ -z "$VERSION" ]; then
|
||||
VERSION=$TRAVIS_TAG
|
||||
fi
|
||||
VERSION=$(echo $VERSION|tr -d v)
|
||||
|
||||
make ${APP}.rb VERSION=$VERSION
|
||||
make ${BINARY}.rb VERSION=$VERSION
|
||||
|
||||
if [ -z "$VERSION" ]; then
|
||||
VERSION=$(grep -E '^\s+url\s+"' ${APP}.rb | cut -d/ -f7 | cut -d. -f1,2,3)
|
||||
VERSION=$(grep -E '^\s+url\s+"' ${BINARY}.rb | cut -d/ -f7 | cut -d. -f1,2,3)
|
||||
fi
|
||||
|
||||
rm -rf homebrew-mugs
|
||||
git config --global user.email "${APP}@auto.releaser"
|
||||
git config --global user.name "${APP}-auto-releaser"
|
||||
git config --global user.email "${BINARY}@auto.releaser"
|
||||
git config --global user.name "${BINARY}-auto-releaser"
|
||||
git clone git@github.com:golift/homebrew-mugs.git
|
||||
|
||||
cp ${APP}.rb homebrew-mugs/Formula
|
||||
cp ${BINARY}.rb homebrew-mugs/Formula
|
||||
pushd homebrew-mugs
|
||||
git commit -m "Update ${APP} on Release: ${VERSION}" Formula/${APP}.rb
|
||||
git commit -m "Update ${BINARY} on Release: ${VERSION}" Formula/${BINARY}.rb
|
||||
git push
|
||||
popd
|
||||
|
||||
Reference in New Issue
Block a user