action.yml aktualisiert
Deployment / lint (push) Successful in 28s
Deployment / test (push) Successful in 59s
Deployment / build (push) Successful in 1m2s
Deployment / deploy (push) Successful in 11s

This commit is contained in:
2023-07-27 19:19:48 +02:00
parent 213f97e472
commit c5fe1e8810
+10 -1
View File
@@ -10,12 +10,18 @@
name: 'Get & Cache Dependencies'
description: 'Get the Dependencies from the cache for a (npm) Node JS Project or initialize the cache for it'
# Inputs can be given with the 'with:' key later when using the custom action
inputs:
caching:
description: 'If the cache should be used or not'
required: false
default: 'true'
outputs:
cache-hit:
description: 'Provides information if the cache was used during the action execution (true) or not (false)'
value: ${{ steps.install.outputs.cache-hit }}
runs:
using: 'composite' # Must be 'composite' for a custom composite action
steps:
@@ -37,6 +43,9 @@ runs:
path: node_modules
key: deps-node-modules-${{ steps.get-cache-hash.outputs.hash }}
- name: Install dependencies
id: install
if: steps.cache.outputs.cache-hit != 'true' || inputs.caching != 'true'
run: npm ci
run: |
npm ci
echo "cache-hit='true'" >> $GITHUB_OUTPUT
shell: bash # compared to workflow ymls... Action ymls require the 'shell' property when a 'run' property was used!