Skip to content

Commit

Permalink
Merge pull request #149 from volta-cli/rwjblue/use-checkout-v4
Browse files Browse the repository at this point in the history
Use actions/checkout@v4
  • Loading branch information
rwjblue authored Mar 14, 2024
2 parents 2afcc67 + 57e4af6 commit 839b29c
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 38 deletions.
66 changes: 33 additions & 33 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -1,52 +1,52 @@
name: 'CI'
name: "CI"
on:
pull_request:
push:
branches:
- master
- 'releases/*'
- "releases/*"

defaults:
run:
shell: bash

env:
NODE_OPTIONS: '--unhandled-rejections=strict'
NODE_OPTIONS: "--unhandled-rejections=strict"

concurrency:
group: ci-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
test:
runs-on: '${{ matrix.os }}-latest'
runs-on: "${{ matrix.os }}-latest"

strategy:
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- run: npm ci
- run: npm run lint
- run: npm run build
- run: npm test

test-specific-volta:
runs-on: '${{ matrix.os }}-latest'
runs-on: "${{ matrix.os }}-latest"

strategy:
fail-fast: false
matrix:
volta-version: ['1.0.0', '1.0.8', '1.1.0']
volta-version: ["1.0.0", "1.0.8", "1.1.0"]
os: [ubuntu, macOS, windows]
exclude:
- os: ubuntu
volta-version: '1.0.0'
volta-version: "1.0.0"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action
- run: npm ci
Expand All @@ -64,14 +64,14 @@ jobs:
- run: ./action/tests/check-version.sh 'yarn' '1.19.0'

test-no-options:
runs-on: '${{ matrix.os }}-latest'
runs-on: "${{ matrix.os }}-latest"

strategy:
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action

Expand All @@ -89,18 +89,18 @@ jobs:
- run: ./action/tests/check-version.sh 'yarn' '1.19.1'

test-specified-node-npm-yarn-overrides-pinned-versions:
runs-on: '${{ matrix.os }}-latest'
runs-on: "${{ matrix.os }}-latest"

strategy:
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: 'branch-for-testing-overriding-pinned-projects-in-ci'
ref: "branch-for-testing-overriding-pinned-projects-in-ci"

- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action

Expand All @@ -121,14 +121,14 @@ jobs:
- run: ./action/tests/check-version.sh 'yarn' '1.22.0'

test-specific-volta-node-npm-yarn:
runs-on: '${{ matrix.os }}-latest'
runs-on: "${{ matrix.os }}-latest"

strategy:
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action
- run: npm ci
Expand All @@ -149,15 +149,15 @@ jobs:
- run: ./action/tests/check-version.sh 'yarn' '1.22.0'

test-specified-registry-url:
runs-on: '${{ matrix.os }}-latest'
runs-on: "${{ matrix.os }}-latest"

strategy:
fail-fast: false
matrix:
os: [ubuntu, macOS, windows]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action

Expand All @@ -167,7 +167,7 @@ jobs:
working-directory: ./action
- uses: ./action
with:
registry-url: 'https://some.path.here.com/lol/'
registry-url: "https://some.path.here.com/lol/"

- run: ./action/tests/log-info.sh
- run: ./action/tests/check-version.sh 'volta' 'current'
Expand All @@ -177,10 +177,10 @@ jobs:
- run: ./action/tests/check-registry.sh 'https://some.path.here.com/lol/'

test-specific-variant:
runs-on: 'ubuntu-latest'
runs-on: "ubuntu-latest"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action

Expand All @@ -200,17 +200,17 @@ jobs:
- run: ./action/tests/check-version.sh 'yarn' '1.19.1'

test-js-project-in-subdir-no-options:
runs-on: 'ubuntu-latest'
runs-on: "ubuntu-latest"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action

- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: 'branch-for-testing-overriding-pinned-projects-in-ci'
path: 'js-stuff'
ref: "branch-for-testing-overriding-pinned-projects-in-ci"
path: "js-stuff"

- run: npm ci
working-directory: ./action
Expand All @@ -226,25 +226,25 @@ jobs:
working-directory: ./js-stuff

test-js-project-in-subdir-with-overrides:
runs-on: 'ubuntu-latest'
runs-on: "ubuntu-latest"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
path: action

- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: 'branch-for-testing-overriding-pinned-projects-in-ci'
path: 'js-stuff'
ref: "branch-for-testing-overriding-pinned-projects-in-ci"
path: "js-stuff"

- run: npm ci
working-directory: ./action
- run: npm run build
working-directory: ./action
- uses: ./action
with:
package-json-path: 'js-stuff/package.json'
package-json-path: "js-stuff/package.json"
node-version: 12.14.0
npm-version: 7.5.2
yarn-version: 1.22.0
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Basic (when the project's `package.json` has a `volta` property with `node` and/

```yaml
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: volta-cli/action@v4
- run: npm install
- run: npm test
Expand All @@ -44,7 +44,7 @@ Manually specifying node and/or yarn versions (e.g. to test a project without `v

```yaml
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: volta-cli/action@v4
with:
node-version: 18.x
Expand All @@ -62,7 +62,7 @@ strategy:
node-version: ['^14.10', '16', '18']
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: volta-cli/action@v4
with:
node-version: ${{ matrix.node-version }}
Expand All @@ -79,7 +79,7 @@ strategy:
node-version: ['^8.12', '10', '12']
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: volta-cli/action@v4
with:
node-version: ${{ matrix.node-version }}
Expand All @@ -93,7 +93,7 @@ In some cases, you may know the particular variant of the installer that you wan

```yaml
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: volta-cli/action@v4
with:
variant: 'linux-openssl-rhel'
Expand Down

0 comments on commit 839b29c

Please sign in to comment.