1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-26 20:34:47 +01:00
psalm/bin/travis-deploy-phar.sh
Barney Laurance eecd21a7d5 Add executable PHP files to PHAR distribution
Previously a user of the phar distribution would have to invoke psalm as
`vendor/bin/psalm.phar`. This is different to the command given in
the psalm documentation, `vendor/bin/psalm`

I also copied all files from the psalm/phar repo into
assets/psalm-phar, so that development can be concentrated in this repo.

The travis-deploy-phar.sh should copy any changes made back into the
psalm/phar.git repo.
2019-06-07 06:52:07 -04:00

18 lines
510 B
Bash
Executable File

#!/usr/bin/env bash
git clone https://${GITHUB_TOKEN}@github.com/psalm/phar.git > /dev/null 2>&1
cd phar
rm -rf !(".git")
cp ../build/psalm.phar ../build/psalm.phar.asc ../assets/psalm-phar/* .
mv dot-gitignore .gitignore
git config user.email "travis@travis-ci.org"
git config user.name "Travis CI"
git add --all .
git commit -m "Updated Psalm phar to commit ${TRAVIS_COMMIT}"
git push --quiet origin master
if [[ "$TRAVIS_TAG" != '' ]] ; then
git tag "$TRAVIS_TAG"
git push origin "$TRAVIS_TAG"
fi