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

chore(internal, ci): switch to setup-node #640

Merged
merged 5 commits into from
Oct 5, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
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
17 changes: 7 additions & 10 deletions .github/actions/pnpm/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,12 @@ description: Setup node and install dependencies using pnpm
runs:
using: "composite"
steps:
- uses: volta-cli/action@v4
- name: Cache pnpm modules
uses: actions/cache@v3
with:
path: ~/.pnpm-store
key: ${{ runner.os }}-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-
- uses: pnpm/action-setup@v2.2.2
with:
version: 7.11.0
run_install: true
version: 7
- uses: actions/setup-node@v3
with:
cache: 'pnpm'
- name: 'Install dependencies'
shell: 'bash'
run: pnpm install
13 changes: 8 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: volta-cli/action@v4
- uses: ./.github/actions/pnpm
- uses: wagoid/commitlint-github-action@v4.1.9
with:
configFile: 'commitlint.config.cjs'
Expand Down Expand Up @@ -166,7 +166,6 @@ jobs:
- uses: actions/checkout@v3
with:
persist-credentials: false
- uses: volta-cli/action@v4
- uses: ./.github/actions/pnpm
- uses: ./.github/actions/download-built-package
- name: Release
Expand All @@ -186,10 +185,14 @@ jobs:
- uses: actions/checkout@v3
with:
persist-credentials: false
- uses: volta-cli/action@v4
- uses: ./.github/actions/pnpm
- uses: ./.github/actions/download-built-package


- name: measure asset sizes
run: node ./build/estimate-bytes/index.js
- name: comment on PR
uses: marocchino/sticky-pull-request-comment@v2
with:
path: ./build/estimate-bytes/comment.txt



2 changes: 1 addition & 1 deletion build/estimate-bytes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { globby } from 'globby';
import esbuild from 'esbuild';
import { dir as tmpDir } from 'tmp-promise';
import { gzip } from 'gzip-cli';
import filesize from 'filesize';
import { filesize } from 'filesize';

const __dirname = path.dirname(fileURLToPath(import.meta.url));
const root = path.join(__dirname, '../..');
Expand Down