2021-07-26 04:25:32 -05:00
|
|
|
name: Bump version
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
schedule:
|
|
|
|
- cron: '0 0 * * *'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
bump-version:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2024-01-26 16:20:48 -06:00
|
|
|
uses: actions/checkout@v4
|
2021-07-26 04:25:32 -05:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
- name: Take last commit
|
|
|
|
id: log
|
2022-10-21 10:00:46 -05:00
|
|
|
run: echo "message=$(git log --no-merges -1 --oneline)" >> $GITHUB_OUTPUT
|
2021-07-30 12:50:02 -05:00
|
|
|
- name: Take repository
|
|
|
|
id: repo
|
2022-10-21 10:00:46 -05:00
|
|
|
run: echo "message=$GITHUB_REPOSITORY" >> $GITHUB_OUTPUT
|
2021-07-26 04:25:32 -05:00
|
|
|
- name: Bump version
|
2021-07-30 12:50:02 -05:00
|
|
|
if: "!contains(steps.log.outputs.message, 'Bump version') && contains(steps.repo.outputs.message, 'YosysHQ/yosys')"
|
2021-07-26 04:25:32 -05:00
|
|
|
run: |
|
|
|
|
make bumpversion
|
|
|
|
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
|
|
|
git config --local user.name "github-actions[bot]"
|
|
|
|
git add Makefile
|
|
|
|
git commit -m "Bump version"
|
|
|
|
- name: Push changes # push the output folder to your repo
|
2021-07-30 12:50:02 -05:00
|
|
|
if: "!contains(steps.log.outputs.message, 'Bump version') && contains(steps.repo.outputs.message, 'YosysHQ/yosys')"
|
2021-07-26 04:25:32 -05:00
|
|
|
uses: ad-m/github-push-action@master
|
|
|
|
with:
|
|
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|