-
Notifications
You must be signed in to change notification settings - Fork 122
45 lines (42 loc) Β· 1.36 KB
/
update-dependencies.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Update dependencies
on:
workflow_dispatch:
schedule:
- cron: '0 0 */7 * *'
jobs:
update:
strategy:
matrix:
node-version: [18.x]
name: Update all dependencies
runs-on: ubuntu-latest
if: ${{ github.repository == 'imbhargav5/nextbase-nextjs13-supabase-starter'}}
steps:
- name: 'Check if user has write access'
uses: 'lannonbr/[email protected]'
with:
permission: 'write'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- if: github.event_name == 'pull_request'
name: β¬οΈ Checkout repo
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.ref }}
persist-credentials: false
- if: github.event_name != 'pull_request'
name: β¬οΈ Checkout repo
uses: actions/checkout@v3
with:
persist-credentials: false
- name: π CI Setup
uses: ./.github/actions/ci-setup
- run: yarn npm-check-updates -u # Update dependencies
- run: rm -Rf node_modules yarn.lock
- run: yarn
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GH_TOKEN }}
commit-message: 'build: update dependencies to the latest version'
title: Update dependencies to the latest version