node_modules: commit updates #489
Workflow file for this run
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: Setup Homebrew | |
on: | |
pull_request: | |
paths: | |
- "**setup-homebrew**" | |
- "package.json" | |
- "package-lock.json" | |
- "node_modules/**" | |
jobs: | |
setup: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- os: macos-latest | |
key: macos | |
- os: ubuntu-20.04 | |
key: ubuntu-20 | |
- os: ubuntu-22.04 | |
key: ubuntu-22 | |
- os: ubuntu-22.04 | |
key: docker-root | |
container: | |
image: ghcr.io/homebrew/ubuntu22.04:master | |
options: --user=root | |
- os: ubuntu-22.04 | |
key: docker-linuxbrew | |
container: | |
image: ghcr.io/homebrew/ubuntu22.04:master | |
options: --user=linuxbrew | |
runs-on: ${{ matrix.os }} | |
container: ${{ matrix.container }} | |
steps: | |
- name: Checkout | |
run: | | |
if [ "$RUNNER_OS" = "Linux" ] | |
then | |
# Allow writing under linuxbrew user | |
orig_uid="$(stat --printf='%u' "$GITHUB_WORKSPACE")" | |
sudo chown -R "$(whoami)" "$GITHUB_WORKSPACE" "$HOME" | |
fi | |
git config --global --add safe.directory "$GITHUB_WORKSPACE" | |
git init | |
git remote add origin "$GITHUB_SERVER_URL/$GITHUB_REPOSITORY" | |
git fetch --no-tags --depth=1 origin "$GITHUB_SHA" | |
git checkout --force "$GITHUB_SHA" | |
if [ "$RUNNER_OS" = "Linux" ] | |
then | |
# Reset ownership so we test if the equivalent in setup-homebrew works. | |
sudo chown -R "$orig_uid" "$GITHUB_WORKSPACE" "$HOME" | |
fi | |
- name: Check syntax | |
run: bash -n setup-homebrew/*.sh | |
- name: Set up Homebrew | |
id: set-up-homebrew | |
uses: ./setup-homebrew/ | |
- name: Cache Homebrew Bundler RubyGems | |
id: cache | |
uses: actions/cache@v4 | |
with: | |
path: ${{ steps.set-up-homebrew.outputs.gems-path }} | |
key: ${{ matrix.key }}-rubygems-${{ steps.set-up-homebrew.outputs.gems-hash }} | |
restore-keys: ${{ matrix.key }}-rubygems- | |
- name: Install Homebrew Bundler RubyGems | |
if: steps.cache.outputs.cache-hit != 'true' | |
run: brew install-bundler-gems | |
- run: brew test-bot --only-cleanup-before | |
- run: brew test-bot --only-setup | |
- run: brew info hello | |
- run: brew install shellcheck | |
- run: shellcheck ./setup-homebrew/*.sh |