node build #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: node build | |
on: [push, workflow_dispatch] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: show folder content | |
run: ls -l | |
- uses: actions/checkout@v4 | |
name: Git checkout | |
- name: use cache for node packages | |
uses: actions/cache@v4 | |
with: | |
path: nodejs/node_modules | |
key: "our_modules-${{hashFiles('nodejs/package-lock.json')}}" | |
id: cache_modules | |
- name: show folder content | |
run: ls -l | |
- name: pull modules | |
run: | | |
cd nodejs | |
npm install | |
- name: check_cache | |
run: echo "Cache hit ${{toJson(steps.cache_modules.outputs)}}" | |
# contains(steps.cache_modules.outputs.cache-hit, 'true') |