Skip to content

Check for new releases #716

Check for new releases

Check for new releases #716

###################
# ENV VARS:
# # - FULL_NAME
# # - EMAIL
# - PAT (generated at Personal Access Tokens - with workflow access checked)
###################
name: Check for new releases
# Automatically check for new releases (new versions)
on:
schedule:
- cron: "0 0 */1 * *"
jobs:
get-version:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.PAT }}
- name: Fetch release version
id: fetch-version
run: |
curl -sL https://raw.githubusercontent.com/n8n-io/n8n/master/package.json | jq -r ".version" > release-versions/n8n-latest.txt
echo ::set-output name=version::$(cat release-versions/n8n-latest.txt)
# - name: Check for modified files
# id: git-check
# run: echo ::set-output name=modified::$([ -z "`git status --porcelain`" ] && echo "false" || echo "true")
# - name: Commit latest release version
# if: steps.git-check.outputs.modified == 'true'
# run: |
# git config --global user.name '${{ secrets.FULL_NAME }}'
# git config --global user.email '${{ secrets.EMAIL }}'
# git commit -am "New release: $(cat release-versions/n8n-latest.txt)"
# git push
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: New auto release v${{steps.fetch-version.outputs.version}}