Skip to content

Commit

Permalink
Update bump version workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
relliv committed Aug 27, 2024
1 parent 0766aab commit 63eeda2
Showing 1 changed file with 19 additions and 5 deletions.
24 changes: 19 additions & 5 deletions .github/workflows/bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,23 @@ jobs:
git config --global user.name "${{ github.actor }}-ci-automation"
git config --global user.email "${{ env.GITHUB_GIT_EMAIL }}"
- name: Check for changes
run: git diff --quiet || git commit -am "Update dependencies"
- name: Make changes and commit
run: |
DATE=$(date +'%Y-%m-%d')
BRANCH_NAME="bump/deps-${DATE}"
git checkout -b "$BRANCH_NAME"
git add .
git commit -m "Automated update on ${DATE}"
- name: Push changes
if: success()
run: git push origin HEAD
- name: Push changes to a new branch
run: git push origin "$BRANCH_NAME"

- name: Create a Pull Request
uses: peter-evans/create-pull-request@v5
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: '$BRANCH_NAME'
base: dev
title: 'Automated Dependency Update on ${DATE}'
body: 'This pull request has been automatically created by GitHub Actions.'

0 comments on commit 63eeda2

Please sign in to comment.