Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update actions to match module template #154

Draft
wants to merge 10 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Attempt to fix Yarn
  • Loading branch information
Mrtenz committed Dec 16, 2024
commit 57c5897e170a7e9cdde8e7011083cb1d495e49f2
38 changes: 33 additions & 5 deletions .github/workflows/build-lint-test.yml
Original file line number Diff line number Diff line change
@@ -23,8 +23,14 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- name: Install dependencies via Yarn (ignoring engines)
run: yarn --frozen-lockfile --ignore-engines
if: "startsWith(matrix.node-version, '2')"
- name: Install dependencies via Yarn
run: yarn --immutable
run: yarn --frozen-lockfile
if: "!startsWith(matrix.node-version, '2')"


build:
name: Build
@@ -46,8 +52,13 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- name: Install dependencies via Yarn (ignoring engines)
run: yarn --frozen-lockfile --ignore-engines
if: "startsWith(matrix.node-version, '2')"
- name: Install dependencies via Yarn
run: yarn --immutable --immutable-cache
run: yarn --frozen-lockfile
if: "!startsWith(matrix.node-version, '2')"
- run: yarn build
- name: Require clean working directory
shell: bash
@@ -77,8 +88,13 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- name: Install dependencies via Yarn (ignoring engines)
run: yarn --frozen-lockfile --ignore-engines
if: "startsWith(matrix.node-version, '2')"
- name: Install dependencies via Yarn
run: yarn --immutable --immutable-cache
run: yarn --frozen-lockfile
if: "!startsWith(matrix.node-version, '2')"
- run: yarn lint
- name: Validate RC changelog
if: ${{ startsWith(github.head_ref, 'release/') }}
@@ -114,8 +130,13 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- name: Install dependencies via Yarn (ignoring engines)
run: yarn --frozen-lockfile --ignore-engines
if: "startsWith(matrix.node-version, '2')"
- name: Install dependencies via Yarn
run: yarn --immutable --immutable-cache
run: yarn --frozen-lockfile
if: "!startsWith(matrix.node-version, '2')"
- run: yarn test
- name: Require clean working directory
shell: bash
@@ -145,8 +166,15 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
- name: Remove yarn.lock
run: rm yarn.lock
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- name: Install dependencies via Yarn (ignoring engines)
run: yarn --ignore-engines
if: "startsWith(matrix.node-version, '2')"
- name: Install dependencies via Yarn
run: rm yarn.lock && YARN_ENABLE_IMMUTABLE_INSTALLS=false yarn
run: yarn
if: "!startsWith(matrix.node-version, '2')"
- run: yarn test
- name: Restore lockfile
run: git restore yarn.lock
3 changes: 2 additions & 1 deletion .github/workflows/publish-docs.yml
Original file line number Diff line number Diff line change
@@ -33,8 +33,9 @@ jobs:
with:
node-version-file: '.nvmrc'
cache: 'yarn'
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- name: Install dependencies via Yarn
run: yarn --immutable
run: yarn --frozen-lockfile --ignore-engines
- name: Run build script
run: yarn build:docs
- name: Deploy to `${{ inputs.destination_dir }}` directory of `gh-pages` branch
3 changes: 2 additions & 1 deletion .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
@@ -39,7 +39,8 @@ jobs:
./dist
./node_modules/.yarn-state.yml
key: ${{ github.sha }}
- run: yarn --immutable
# TODO: Remove --ignore-engines once devdeps compatible with node v20
- run: yarn --frozen-lockfile --ignore-engines
- run: yarn build

publish-npm-dry-run: