check #2135
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: check | |
on: | |
schedule: | |
- cron: "0 */12 * * *" | |
jobs: | |
new-release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
token: ${{ secrets.PAT }} | |
- name: get-latest-version | |
run: | | |
VERSION="$(wget 2>/dev/null http://www.foobar2000.org/download -qSO- | grep foobar2000_v | awk '{print $3}'|sed '2,3d;s|v||;s|</a><br/>||;s|</a>||')" | |
last=$(tail -n1 .build.s | awk '{print $4}') | |
if [ "$last" != "$VERSION" ]; then | |
echo "$(date -u --rfc-3339=seconds) Version $VERSION" >> .build.s | |
fi | |
- uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
commit_message: Trigger build for new version | |
branch: master | |
# new-beta-release: | |
# runs-on: ubuntu-latest | |
# | |
# steps: | |
# - uses: actions/checkout@v2 | |
# with: | |
# token: ${{ secrets.PAT }} | |
# ref: beta | |
# - name: get-latest-version | |
# run: | | |
# VERSION="$(wget 2>/dev/null http://www.foobar2000.org/download -qSO- | grep getfile | tail -n1 | sed 's|v| |;s| b|-b|' | awk '{print $3 $4}')" | |
# VERSION_CHECK="$(wget 2>/dev/null http://www.foobar2000.org/download -qSO- | grep getfile | tail -n1 | sed 's|v| |;s| b|-b|' | awk '{print $3 $4}' | wc -l)" | |
# last=$(tail -n1 .build.b | awk '{print $4}') | |
# | |
# if [ "$VERSION_CHECK" -eq 1 ]; then | |
# if [ "$last" != "$VERSION" ]; then | |
# echo "$(date -u --rfc-3339=seconds) Version $VERSION" >> .build.b | |
# fi | |
# else | |
# echo "No beta update released." | |
# fi | |
# - uses: stefanzweifel/git-auto-commit-action@v4 | |
# with: | |
# commit_message: Trigger build for new version | |
# branch: beta |