Skip to content

Commit

Permalink
ci: fix checkout issue
Browse files Browse the repository at this point in the history
  • Loading branch information
danielmhair committed Dec 18, 2024
1 parent ebcd2b4 commit b8508c6
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 15 deletions.
21 changes: 9 additions & 12 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,6 @@ concurrency:
cancel-in-progress: false

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout 🛎️
uses: actions/checkout@v4

- name: Setup Node.js ⚙️ - Cache dependencies ⚡ - Install dependencies 🔧
uses: ./.github/workflows/setup-node

# To do this in another repo, run `ng add angular-cli-ghpages
# Then add this under angular.json > projects > <project> > architect object
# "deploy": {
Expand All @@ -35,10 +25,17 @@ jobs:
# }
# },
# Then add this
publish_deploy:

build:
runs-on: ubuntu-latest
needs: build

steps:
- name: Checkout 🛎️
uses: actions/checkout@v4

- name: Setup Node.js ⚙️ - Cache dependencies ⚡ - Install dependencies 🔧
uses: ./.github/workflows/setup-node

- name: Prepare Git
run: |
git config user.name "Panda Bytes"
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/setup-node/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,20 @@ description: "Setup Node.js ⚙️ - Cache dependencies ⚡ - Install dependenci
runs:
using: "composite"
steps:

- name: Setup Node.js ⚙️
uses: actions/setup-node@v4
with:
node-version: 20
cache-dependency-path: package-lock.json,app/package-lock.json,packages/package-lock.json

- name: Cache dependencies ⚡
id: cache_dependencies
uses: actions/cache@v3
with:
path: node_modules
key: node-modules-${{ hashFiles('package-lock.json') }}
key: node-modules-${{ hashFiles('package-lock.json') }}-${{ hashFiles('app/package-lock.json') }}-${{ hashFiles('packages/package-lock.json') }}

- name: Install dependencies 🔧
shell: bash
if: steps.cache_dependencies.outputs.cache-hit != 'true'
run: npm ci
run: npm ci

0 comments on commit b8508c6

Please sign in to comment.