Skip to content

Chore/yarn3 #1952

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

Merged
merged 17 commits into from
Oct 22, 2021
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
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,7 @@ packages/paste-token-contrast-checker/public
.next
.yarn

packages/**/dist/*

tsconfig.build.tsbuildinfo
**/*.d.ts
10 changes: 0 additions & 10 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,14 +105,4 @@ module.exports = {
// We don't use jasmine and this clashes with danger js
'jest/no-jasmine-globals': 'off',
},
settings: {
'import/resolver': {
[path.join(__dirname, './.eslint/resolver')]: {
someConfig: '',
},
node: {
extensions: ['.js', '.jsx', '.ts', '.tsx', '.d.ts'],
},
},
},
};
15 changes: 8 additions & 7 deletions .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,21 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Newer cache syntax

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

- uses: actions/cache@v2
name: Load Yarn cache
- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn

- name: Install Dependencies
run: yarn install --frozen-lockfile && yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand Down
14 changes: 13 additions & 1 deletion .github/workflows/package-size.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,19 @@ jobs:
with:
node-version: 12.x

- uses: preactjs/compressed-size-action@v2
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
- uses: zahnster/[email protected]
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
build-script: "build:js"
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,21 @@ jobs:
with:
node-version: 12.x

- id: yarn-cache
name: Get Yarn cache path
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- uses: actions/cache@v2
name: Load Yarn cache
- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn

- name: Install Dependencies
run: yarn install --frozen-lockfile && yarn bootstrap
run: yarn install --immutable

- name: Setup CI Git User
run: |
Expand Down
64 changes: 25 additions & 39 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -38,10 +38,7 @@ jobs:

- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile

- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand All @@ -60,15 +57,15 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -84,10 +81,7 @@ jobs:

- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile

- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand All @@ -106,15 +100,15 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -130,10 +124,7 @@ jobs:

- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile

- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand All @@ -152,15 +143,15 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -176,10 +167,7 @@ jobs:

- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile

- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand All @@ -196,14 +184,14 @@ jobs:
uses: actions/setup-node@v2
with:
node-version: 12.x
- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -217,9 +205,7 @@ jobs:
key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile
- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable
- name: Run DangerJS
run: yarn danger ci
env:
Expand Down
13 changes: 5 additions & 8 deletions .github/workflows/vrt_main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -47,10 +47,7 @@ jobs:

- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile && yarn bootstrap

- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand Down
13 changes: 5 additions & 8 deletions .github/workflows/vrt_pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ jobs:
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- name: Load Yarn cache
uses: actions/cache@v2
id: yarn_cache_id
with:
path: ${{ steps.yarn-cache.outputs.dir }}
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
Expand All @@ -44,10 +44,7 @@ jobs:

- name: Install Dependencies
if: steps.yarn_cache_id.outputs.cache-hit != 'true' || steps.node_modules_cache_id.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile && yarn bootstrap

- name: Bootstrap lerna
run: yarn bootstrap
run: yarn install --immutable

- name: Build packages
run: yarn build
Expand Down
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -92,3 +92,12 @@ cypress/screenshots

# Local Netlify folder
.netlify

# Yarn Folders
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/sdks
!.yarn/versions
Loading