Skip to content

Commit

Permalink
Cache npm dependencies in snyk-security workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristianZaccaria committed Nov 6, 2024
1 parent cfaf9b1 commit b5e87ce
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ jobs:
- name: Checkout the repository
uses: actions/checkout@v4
with:
submodules: recursive
token: ${{ secrets.GH_CLI_TOKEN }}
- name: Install Python
uses: actions/setup-python@v5
Expand Down Expand Up @@ -95,8 +94,8 @@ jobs:
- name: Commit and push changes
run: |
git config --global user.email "[email protected]"
git config --global user.name "codeflare-machine-account"
git config --global user.email "${{ vars.CODEFLARE_MACHINE_EMAIL }}"
git config --global user.name "${{ vars.CODEFLARE_MACHINE_NAME }}"
git checkout -b $PR_BRANCH_NAME
git commit -am "Update snyk-security.yaml"
git push --set-upstream origin "$PR_BRANCH_NAME"
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/snyk-security.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,12 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Node.js to cache dependencies
uses: actions/setup-node@v4
with:
submodules: recursive
node-version: 20
cache: 'npm'

- name: Install Snyk CLI
run: npm install -g snyk
Expand Down

0 comments on commit b5e87ce

Please sign in to comment.