Skip to content

Commit

Permalink
chore(ci): use pnpm instead of yarn
Browse files Browse the repository at this point in the history
  • Loading branch information
vscav committed May 23, 2023
1 parent 8b07023 commit 4bebab2
Show file tree
Hide file tree
Showing 6 changed files with 67 additions and 52 deletions.
18 changes: 12 additions & 6 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
branches:
- master
tags:
- '*'
- "*"
pull_request:

jobs:
Expand All @@ -19,9 +19,15 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Volta
uses: volta-cli/action@v4
- name: Install Dependencies
run: yarn install --frozen-lockfile
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 16.x
- name: Install pnpm
uses: NullVoxPopuli/action-setup-pnpm@v1
with:
pnpm-version: 8.5.1
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Run Lint
run: yarn lint
run: pnpm lint
26 changes: 16 additions & 10 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,33 @@ name: Release
on:
push:
tags:
- 'v*'
- "v*"

jobs:
release:
name: release
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- name: Checkout
uses: actions/checkout@v3
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 16
registry-url: 'https://registry.npmjs.org'

- run: yarn install
- run: yarn build

registry-url: "https://registry.npmjs.org"
- name: Install pnpm
uses: NullVoxPopuli/action-setup-pnpm@v1
with:
pnpm-version: 8.5.1
- name: Install dependencies
run: pnpm install
- name: Build addon
run: pnpm build
- name: auto-dist-tag
run: npx auto-dist-tag@1 --write

- run: npm publish
- name: Publish
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
working-directory: ember-phone-input
65 changes: 39 additions & 26 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
branches:
- master
tags:
- '*'
- "*"
pull_request:

jobs:
Expand All @@ -20,14 +20,18 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Volta
uses: volta-cli/action@v4
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 16
- name: Install Dependencies
run: yarn install --frozen-lockfile
node-version: 16.x
- name: Install pnpm
uses: NullVoxPopuli/action-setup-pnpm@v1
with:
pnpm-version: 8.5.1
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Test
run: yarn test:ember
run: pnpm test:ember
working-directory: test-app

try-scenarios:
Expand All @@ -43,28 +47,32 @@ jobs:
ember-try-scenario:
- ember-lts-3.28
- ember-lts-4.4
- 'ember-release'
- 'ember-beta'
- 'ember-canary'
- 'embroider-safe'
- 'embroider-optimized'
- 'ember-classic'
- "ember-release"
- "ember-beta"
- "ember-canary"
- "embroider-safe"
- "embroider-optimized"
- "ember-classic"

steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Volta
uses: volta-cli/action@v4
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 16.x
- name: Install pnpm
uses: NullVoxPopuli/action-setup-pnpm@v1
with:
node-version: 16
- name: Install Dependencies
run: yarn install --frozen-lockfile
pnpm-version: 8.5.1
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Test
run: yarn ember try:one ${{ matrix.ember-try-scenario }} --skip-cleanup
run: pnpm ember try:one ${{ matrix.ember-try-scenario }} --skip-cleanup
working-directory: test-app

floating-dependencies:
name: Floating Dependencies
name: Floating dependencies
runs-on: ubuntu-latest
timeout-minutes: 10

Expand All @@ -73,12 +81,17 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Volta
uses: volta-cli/action@v4
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 16.x
- name: Install pnpm
uses: NullVoxPopuli/action-setup-pnpm@v1
with:
node-version: 16
- name: Install Dependencies
run: yarn install --no-lockfile
pnpm-version: 8.5.1
no-lockfile: true
- name: Install dependencies
run: pnpm install --no-lockfile
- name: Test
run: yarn test:ember
run: pnpm test:ember
working-directory: test-app
3 changes: 0 additions & 3 deletions ember-phone-input/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,5 @@
".": "./dist/index.js",
"./*": "./dist/*.js",
"./addon-main.js": "./addon-main.cjs"
},
"volta": {
"extends": "../package.json"
}
}
4 changes: 0 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@
"engines": {
"node": "16.* || >= 18"
},
"volta": {
"node": "18.16.0",
"yarn": "1.22.19"
},
"publishConfig": {
"registry": "https://registry.npmjs.org"
},
Expand Down
3 changes: 0 additions & 3 deletions test-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,5 @@
},
"dependencies": {
"ember-phone-input": "*"
},
"volta": {
"extends": "../package.json"
}
}

0 comments on commit 4bebab2

Please sign in to comment.