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

Use pnpm package manager #424

Merged
merged 1 commit into from
Feb 11, 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
75 changes: 27 additions & 48 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,33 +7,28 @@ on:
- 'v*'
pull_request: {}

env:
PNPM_VERSION: 5.18.1

jobs:
lint:
name: Linting
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12.x

- name: get yarn cache dir
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v1
- uses: pnpm/action-setup@v2.0.1
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-lint-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
version: ${{ env.PNPM_VERSION }}

- name: install dependencies
run: yarn install
- uses: actions/setup-node@v1
with:
node-version: 12.x
cache: pnpm

- name: lint
run: yarn lint
- run: pnpm install
- run: pnpm lint

test:
name: Node Tests
Expand All @@ -46,26 +41,18 @@ jobs:

steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: get yarn cache dir
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v1
- uses: pnpm/action-setup@v2.0.1
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-test-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
version: ${{ env.PNPM_VERSION }}

- name: install dependencies
run: yarn install
- uses: actions/setup-node@v1
with:
node-version: 12.x
cache: pnpm

- name: node tests
run: yarn test --coverage
- run: pnpm install
- run: pnpm test -- --coverage

ember-try-scenarios:
name: Ember Tests
Expand All @@ -74,23 +61,15 @@ jobs:

steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 12.x

- name: get yarn cache dir
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v1
- uses: pnpm/action-setup@v2.0.1
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-ember-try-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
version: ${{ env.PNPM_VERSION }}

- name: install dependencies
run: yarn install
- uses: actions/setup-node@v1
with:
node-version: 12.x
cache: pnpm

- name: test
run: yarn ember try:each
- run: pnpm install
- run: node_modules/.bin/ember try:each
10 changes: 9 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,25 @@ on:
tags:
- '*'

env:
PNPM_VERSION: 5.18.1

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

steps:
- uses: actions/checkout@v1

- uses: pnpm/action-setup@v2.0.1
with:
version: ${{ env.PNPM_VERSION }}

- uses: actions/setup-node@v1
with:
node-version: 12.x
registry-url: 'https://registry.npmjs.org'
cache: pnpm

- run: npm publish
env:
Expand Down
1 change: 1 addition & 0 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@
.travis.yml
bower.json
ember-cli-build.js
pnpm-lock.yaml
testem.js
2 changes: 1 addition & 1 deletion config/ember-try.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
module.exports = {
command: 'yarn run ember test',
useVersionCompatibility: true,
useYarn: true,
usePnpm: true,
scenarios: [{
name: 'ember-release',
allowedToFail: true,
Expand Down
Loading