Skip to content

Commit

Permalink
chore: move runner to Node.js 18.x and replace yarn with pnpm
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianroming committed Feb 22, 2024
1 parent b03dbbe commit 9bbb912
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 6 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/build-package.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,25 @@
name: CI Build

on: [push]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Setup pnpm
uses: pnpm/action-setup@v2
with:
version: 8

- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'pnpm'
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies and build 🔧
run: pnpm install && pnpm build
15 changes: 13 additions & 2 deletions .github/workflows/publish-package-to-npm-dry-run.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,29 @@
name: Publish to NPM (dry-run)

on: [push]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Setup pnpm
uses: pnpm/action-setup@v2
with:
version: 8

- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'pnpm'
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies and build 🔧
run: pnpm install && pnpm build

- name: Publish package on NPM 📦
run: npm publish --dry-run
env:
Expand Down
15 changes: 13 additions & 2 deletions .github/workflows/publish-package-to-npm.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,31 @@
name: Publish to NPM

on:
release:
types: [created]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Setup pnpm
uses: pnpm/action-setup@v2
with:
version: 8

- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'pnpm'
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies and build 🔧
run: pnpm install && pnpm build

- name: Publish package on NPM 📦
run: npm publish
env:
Expand Down

0 comments on commit 9bbb912

Please sign in to comment.