Skip to content

Commit

Permalink
Support nektos/act for debugging GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Fryguy committed Aug 2, 2022
1 parent 928b8cf commit 2aa1941
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@ jobs:
- '14'
steps:
- uses: actions/checkout@v2
- name: Set up system
run: bin/before_install
- name: Set up Node
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
cache: yarn
cache: ${{ !env.ACT && 'yarn' || '' }}
registry-url: https://npm.manageiq.org/
- name: Prepare tests
run: bin/setup
Expand Down
8 changes: 8 additions & 0 deletions bin/before_install
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash

if [ -n "$ACT" ]; then
# Install yarn
curl -o- -L https://yarnpkg.com/install.sh | bash
echo "$HOME/.yarn/bin" >> $GITHUB_PATH
echo "$HOME/.config/yarn/global/node_modules/.bin" >> $GITHUB_PATH
fi

0 comments on commit 2aa1941

Please sign in to comment.