This repository has been archived by the owner on Feb 6, 2024. It is now read-only.
chore: bump chmod-cli from 1.0.4 to 2.0.1 (#268) #961
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: build | |
on: | |
workflow_dispatch: | |
pull_request: | |
branches: ["*", "!*@latest"] | |
push: | |
branches: ["*@latest", "main"] | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }}-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [windows, ubuntu, macos] | |
steps: | |
- name: Checkout repository | |
uses: actions/[email protected] | |
with: | |
fetch-depth: 0 | |
- name: Cache dependencies | |
id: cache-npm | |
uses: actions/[email protected] | |
with: | |
path: node_modules | |
key: node-${{ runner.os }}-${{ hashFiles('package-lock.json') }} | |
- name: Install dependencies | |
run: npm install | |
- name: Build and test all packages | |
if: github.event_name != 'pull_request' | |
run: | | |
npx nx reset | |
npm run clean -- --scope=@actions-kit/dev | |
npm run build -- --scope=@actions-kit/dev | |
npm run clean -- --ignore=@actions-kit/dev | |
npm run test | |
- name: Build and test changed packages | |
if: github.event_name == 'pull_request' | |
run: | | |
npx nx reset | |
npm run clean -- --scope=@actions-kit/dev "--since=origin/${{ github.base_ref }}" | |
npm run build -- --scope=@actions-kit/dev "--since=origin/${{ github.base_ref }}" | |
npm run clean -- --ignore=@actions-kit/dev "--since=origin/${{ github.base_ref }}" | |
npm test -- "--since=origin/${{ github.base_ref }}" | |
- name: Check diff | |
run: git diff --exit-code HEAD | |
deps-by: | |
needs: build | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
pkg: [cache, dev, envi, exec, log] | |
steps: | |
- name: Init project | |
run: npm init --yes | |
- name: Install package | |
run: npm install 'https://gitpkg.now.sh/${{ github.repository }}/packages/${{ matrix.pkg }}?${{ github.sha }}' | |
- name: Import package | |
run: node -e 'const pkg = require("@actions-kit/${{ matrix.pkg }}");' | |
- name: Import package in TypeScript | |
run: npx --yes ts-node -e 'import * as pkg from "@actions-kit/${{ matrix.pkg }}";' |