Skip to content

Commit b8ede3b

Browse files
Xavier MedranoXavier Medrano
Xavier Medrano
authored and
Xavier Medrano
committed
change action to open pr and test on push
1 parent d60c9f9 commit b8ede3b

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

.github/workflows/main.yml

+11-2
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ name: Check for dependency upgrades
33
on:
44
schedule:
55
- cron: '30 5 * * 0'
6+
push:
7+
branches:
8+
- auto/dependency-update
69

710
jobs:
811
upgrade-dependencies:
@@ -24,11 +27,17 @@ jobs:
2427
nodeenv -p && \
2528
npm install -g npm-check-updates && \
2629
find ./docker -name package.json -exec ncu --packageFile {} -u \;
27-
- name: Push to main branch
30+
- name: Push to designated branch
2831
run: |
2932
git config --global user.name "xmedr"
3033
git config --global user.email "[email protected]"
34+
git checkout auto/dependency-update
3135
3236
git add .
3337
git commit -m "Update pypi and node dependencies"
34-
git push origin ${{ github.ref_name }}
38+
git push origin auto/dependency-update
39+
- name: Create pull request
40+
run: |
41+
gh pr create -B main -H auto/dependency-update --title 'Update cookiecutter dependencies' --body 'Created by Github action. Review changes to the cookiecutters' dependencies and merge if stable.'
42+
env:
43+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)