-
Notifications
You must be signed in to change notification settings - Fork 22
42 lines (36 loc) · 1.03 KB
/
get_version.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
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