Get latest V8 stable version #2417
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Get latest V8 stable version | |
on: | |
schedule: | |
- cron: '0 */12 * * *' | |
push: | |
branches: [ master ] | |
paths: | |
- 'get_version.py' | |
- '.github/workflows/get_version.yml' | |
jobs: | |
version_finder: | |
name: Get version number | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
token: ${{ secrets.ACCESS_TOKEN }} | |
- run: | | |
cd $GITHUB_WORKSPACE | |
pip install pandas | |
version=$(python ./get_version.py) | |
if [ $? -eq 0 ]; then | |
git pull | |
echo $version > V8_VERSION | |
if ( git update-index -q --refresh && git diff-index --quiet HEAD -- ); then | |
echo "V8 version is already up to date" | |
exit 0 | |
fi | |
git config --global user.name 'V8 version finder' | |
git config --global user.email 'v8_version_finder@localhost' | |
git commit -am "Update V8_VERSION to $version" | |
git push | |
else | |
echo "Failed to retrieve V8 version" | |
exit 1 | |
fi |