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

feat(pnpm) - migrate from YarnV1 to PNPM #5254

Draft
wants to merge 157 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
157 commits
Select commit Hold shift + click to select a range
9e1dac4
big commit pnpm
Oct 12, 2023
03d2f1a
syn with master
Oct 12, 2023
de2c965
add warn pnpm
Oct 12, 2023
160eaf7
fix
Oct 12, 2023
5654709
fix: build icons
jmfrancois Oct 12, 2023
3bd4e96
chore: remove enzyme and fix some lint
jmfrancois Oct 12, 2023
c72ba53
fix: prettier
jmfrancois Oct 12, 2023
9528a05
chore: lint forms
jmfrancois Oct 12, 2023
d104543
chore: CI on pnpm
jmfrancois Oct 12, 2023
2b87eee
chore: CI use pnpm everywhere
jmfrancois Oct 12, 2023
d4250ea
chore: remove cache-loader deprecated webpack plugin
jmfrancois Oct 12, 2023
930d566
npmrc + remove @talend/scripts-config-babel
Oct 12, 2023
32e236c
chore: add typescript config devDep for VSCode
jmfrancois Oct 12, 2023
7ed6a6a
Merge branch 'smouillour/fix/TDOPS-5327-pnpm' of github.com:Talend/ui…
jmfrancois Oct 12, 2023
fd29e1c
revert
Oct 12, 2023
c1b527b
add "@talend/scripts-config-typescript": "^11.1.0" in package having …
Oct 12, 2023
3313a64
add @talend/scripts-config-babel in each package with babel file
Oct 12, 2023
19c72e7
fix import testing-library
Oct 12, 2023
bb9e680
a11n add compiler option with type jest
Oct 12, 2023
e5d894a
add compiler option in http to add type jest
Oct 12, 2023
092b39d
fix package util adding type lodash
Oct 12, 2023
8cf2480
try to fix issue with jsfc (missing babel-loader)
Oct 12, 2023
fd58ec4
revert change made on jsfc
Oct 12, 2023
6749610
remove babel-loader to config-react-webpack and add it (+add webapp) …
Oct 12, 2023
7459b77
Merge 67496107ffbb4cabcc41b97ac4e16ee7968c12e9 into cd04f75e88298e9b8…
smouillour Oct 12, 2023
527af9c
chore: pnpm-deduplicate
github-actions[bot] Oct 12, 2023
9001885
remove yarn in tool-versions
Oct 12, 2023
4e7be57
change way to call webpack in build-lib-umd
Oct 12, 2023
8b6656e
try something to inprove findPackagesFromScopeFolder for PNPM
Oct 12, 2023
c2acf07
DRAFT PNPM 2(#4932)
smouillour Oct 13, 2023
9bc0d00
fix lockfile
Oct 13, 2023
f305cfb
More fixes (#4934)
smouillour Oct 17, 2023
813cdca
DRAFT PNPM 5 (more fixes) (#4938)
smouillour Oct 19, 2023
89ed2f3
Merge 813cdcacde6cbf5907dbab2275cf31436f0121e1 into 6efd54301e87eff51…
smouillour Oct 19, 2023
46de8a2
chore: pnpm-deduplicate
github-actions[bot] Oct 19, 2023
1c97306
Merge with master and manage conflict
Oct 19, 2023
27f728b
fixes after merge
Oct 19, 2023
fc54ed1
Sync with master
Oct 23, 2023
385f14d
update pnpm lock
Oct 23, 2023
74eae57
Merge 385f14dabe1b3b9f2fbc6b05e81747ee2516c33f into 35263dfcb1c1b3028…
smouillour Oct 23, 2023
2e97a30
chore: pnpm-deduplicate
github-actions[bot] Oct 23, 2023
1906997
fix prettier
Oct 23, 2023
14add4a
add missing deps in scripts-config-storybook-lib
Oct 23, 2023
8c6fd49
Sync with master
Oct 23, 2023
4b5cbb3
fix tests impacted by fix with prettier
Oct 23, 2023
65d448a
add eslint to module-to-cdn
Oct 23, 2023
07a20eb
fix(TDOPS-5502): PNPM - Prepare scripts-config-babel and packages dep…
Oct 23, 2023
93c3b79
add missing one + add babel.config.js in npmignore files
Oct 23, 2023
a11b253
fix missing changes
Oct 23, 2023
be1e8a6
Merge a11b2534df44de9ff14cdc23484bbad7bd846c67 into 96d688489246d683e…
smouillour Oct 23, 2023
652ec0d
chore: yarn-deduplicate
github-actions[bot] Oct 23, 2023
c39e54b
add changeset and revert useless changes in npmignore
Oct 23, 2023
75ca249
Merge branch 'master' into smouillour/fix/TDOPS-5502
smouillour Oct 23, 2023
123c4b8
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5502
Oct 24, 2023
0ca28ed
fix: remove dep between eslint config and script utils
jmfrancois Oct 24, 2023
0fc2b84
chore: remove babel config form module-to-cdn as it is not used
jmfrancois Oct 24, 2023
eff5912
chore: kill the breaking change
jmfrancois Oct 24, 2023
1b7d997
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5502
Oct 24, 2023
d4d0183
sync with smouillour/fix/TDOPS-5502
Oct 24, 2023
1cb523b
sync with Master
Oct 25, 2023
6829525
Merge 1cb523b6e221c6a5556e56755a186e1e1de40c50 into 3f9c8a7bbddfafc93…
smouillour Oct 25, 2023
ae730ff
chore: pnpm-deduplicate
github-actions[bot] Oct 25, 2023
c32eceb
remove tsconfig.build to remind why i added them + fix scripts-utils …
Oct 25, 2023
aaf287b
Merge c32eceb11e1abb9a77b0179afc2df699dc37115e into 3f9c8a7bbddfafc93…
smouillour Oct 25, 2023
f710b4d
chore: pnpm-deduplicate
github-actions[bot] Oct 25, 2023
c09eb2e
remove babelrc in scripts-utils
Oct 25, 2023
551ddd2
fix issues
Oct 26, 2023
460b50d
some fix
Oct 27, 2023
a2f8c0c
fix storybook
Oct 27, 2023
6ff881d
Add pnpm setup
Oct 28, 2023
99364a8
fix pnpm store
Oct 28, 2023
8f95e3a
try another fix with pnpm setup
Oct 28, 2023
08c00d2
one more try to fix pnpm setup
Oct 28, 2023
984a37e
one more try
Oct 28, 2023
8ec1f82
try to fix pnpm global bin dir
Nov 6, 2023
7b6e15d
go back to pnpm/action-setup
Nov 6, 2023
a8d1072
fix
Nov 6, 2023
e9bfb11
fix missing deps
Nov 6, 2023
9f83275
add missing deps
Nov 6, 2023
3b7b45d
fix for playground
Nov 6, 2023
400f5d9
fix playground deps
Nov 6, 2023
3c91352
Merge with Master
Nov 6, 2023
851c6f4
fix talend versions
Nov 6, 2023
80fd394
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5327-…
Nov 6, 2023
935404b
npmrc: add cypress in public-hoist-pattern
Nov 7, 2023
ec6a726
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5327-…
Nov 7, 2023
77bc7e4
fix tests in dynamic-cdn-webpack-plugin
Nov 7, 2023
1a21d99
add condition to manage issue using pnpm/action-setup
Nov 7, 2023
30bdeb9
fix edge case due to pnpm/action-setup
Nov 7, 2023
abdedd3
fix eslint in multiple packages
Nov 8, 2023
5eeb0ee
fix forms test
Nov 9, 2023
1aac508
Merge 5eeb0eeb2b74226244d2e5797b0474b284c12243 into a0fdcfa961aa137be…
smouillour Nov 9, 2023
15dccc4
chore: pnpm-deduplicate
github-actions[bot] Nov 9, 2023
07038c3
upgrade version of pnpm needed
Nov 9, 2023
3ad6e1d
fix scripts-core usage as devDep instead of dep
Nov 9, 2023
8d5d34c
revert one change in dynamic-cdn-webpack-plugin (find)
Nov 9, 2023
f250513
fix lint
Nov 9, 2023
6a06216
fix usage of loader 'source-map-loader' in scripts-config-react-webpack
Nov 10, 2023
8a97f20
Merge with Master
Nov 10, 2023
f47cd02
Fix version after merge with master
Nov 10, 2023
15bbb2c
fix lock file
Nov 10, 2023
40d3567
Merge with Master
Nov 10, 2023
6886e12
Merge 40d35678b526965cd65d8fc918b9bc2dbd52070d into e82cc7f30406efff3…
smouillour Nov 10, 2023
1e859e9
chore: pnpm-deduplicate
github-actions[bot] Nov 10, 2023
2547a2f
Sync with master managing conflict
Nov 13, 2023
fbea33c
remove changeset not needed
Nov 13, 2023
2335784
revert remove of .babelrc.json to keep compatibility
Nov 13, 2023
6d52560
undo changes made in this file
Nov 13, 2023
3d72111
Fix detected issue with yarn
Nov 13, 2023
ff7bc49
Fix after review in another PR
Nov 14, 2023
872d4bc
Sync with Master
Nov 14, 2023
163f9ba
update pnpm-lock
Nov 14, 2023
060ec78
revert change
Nov 14, 2023
672ae7d
fix playground
Nov 14, 2023
ce17d45
fix
Nov 14, 2023
6863eed
fix scripts-config-react-webpack for playground basename
Nov 15, 2023
30c0009
fix
Nov 15, 2023
d011e33
Sync with master
Nov 15, 2023
aebb874
fix
Nov 16, 2023
8f3c55d
Sync with master
Nov 16, 2023
26f7304
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5327-…
Nov 16, 2023
70dba13
fix cypress
Nov 17, 2023
3a4e2f1
fix cypress
Nov 17, 2023
58469a7
fix for test cypress
Nov 17, 2023
25596bf
move lint merge-report to scripts-core
Nov 20, 2023
c5531b3
fix gha dependencies + more
Nov 23, 2023
e14ea2a
Merge with master
Nov 23, 2023
1cb1632
Merge e14ea2af2d27c3c85594286d7f1a0f1dc498c492 into 5455b651717d5d1b5…
smouillour Nov 23, 2023
80c23e2
chore: pnpm-deduplicate
github-actions[bot] Nov 23, 2023
7e8cf5d
fix
Nov 23, 2023
4719211
fix
Nov 24, 2023
b7ccea6
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5327-…
Nov 24, 2023
2ec1cc3
merge with master
Nov 24, 2023
e41a9cf
revert some changes
Nov 27, 2023
1cea9f7
Merge e41a9cf4e2dba790745ddbba218d57b3eccedae3 into faa8bb3f8c2706807…
smouillour Nov 27, 2023
341e158
chore: pnpm-deduplicate
github-actions[bot] Nov 27, 2023
71d3ede
fix lint
Nov 27, 2023
e1ecf22
fix
Nov 27, 2023
172252a
sync with master
Nov 27, 2023
a724744
sync with master
Nov 28, 2023
c7fe896
Merge a724744e1ed4e713de1ccceb09694382a503d409 into b5fc2c3bb53d5006c…
smouillour Nov 28, 2023
f03f18d
chore: pnpm-deduplicate
github-actions[bot] Nov 28, 2023
397a559
update pnpm version
Dec 1, 2023
c8407b1
sync with master
Dec 1, 2023
4785a34
upgrade deps
Dec 1, 2023
7359601
Merge 4785a346f0dbe30271b78ff663d9d0dd71e638bd into 92ff355c7bcb7ffd4…
smouillour Dec 1, 2023
85169dc
chore: pnpm-deduplicate
github-actions[bot] Dec 1, 2023
7834cc6
Merge remote-tracking branch 'origin' into smouillour/fix/TDOPS-5327-…
Dec 4, 2023
e62267d
Merge 7834cc60903188c17ef865958477482e7abf5f89 into 38dad22dc6467891b…
smouillour Dec 4, 2023
135b47a
chore: pnpm-deduplicate
github-actions[bot] Dec 4, 2023
be8de20
sync with master
smouillour Apr 3, 2024
d821af8
Merge be8de205585ddaeb6250b6a8256fc2598f58f59d into e12b3cd3d1a5e9806…
smouillour Apr 3, 2024
be131a7
chore: pnpm-deduplicate
github-actions[bot] Apr 3, 2024
b4b9378
fix bug
smouillour Apr 3, 2024
9c7cdbe
Merge b4b937823411de0b519e6d6ff65942bebb64aa4a into e12b3cd3d1a5e9806…
smouillour Apr 3, 2024
d0fd9d1
chore: pnpm-deduplicate
github-actions[bot] Apr 3, 2024
a33a4cc
upgrade pnpm version in .tool-versions
smouillour Apr 4, 2024
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
32 changes: 22 additions & 10 deletions .github/actions/setup-node/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,31 @@ runs:
registry-url: 'https://registry.npmjs.org/'
scope: '@talend'

- name: Install yarn
shell: bash
run: npm i -g yarn
# - name: Install PNPM
# shell: bash
# run: npm install -g [email protected]

# - name: Setup PNPM
# shell: bash
# run: |
# mkdir ~/.local/share/pnpm
# pnpm config set global-bin-dir ~/.local/share/pnpm

- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 8
run_install: false

- name: Get yarn cache directory path
id: yarn-cache-dir-path
- name: Get pnpm cache directory path
id: pnpm-cache-dir-path
shell: bash
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
run: echo "dir=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 #v3.3.2
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
id: pnpm-cache # use this to check for `cache-hit` (`steps.pnpm-cache.outputs.cache-hit != 'true'`)
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
path: ${{ steps.pnpm-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-yarn-
${{ runner.os }}-pnpm-
13 changes: 13 additions & 0 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# How to run github action locally

Use the cli ACT: https://github.com/nektos/act

# How to run PR-TEST

```bash
act pull_request -j build -W .github/workflows/pr-test.yml
```

```bash
act --container-architecture linux/amd64 pull_request -j build -W .github/workflows/pr-test.yml
```
4 changes: 2 additions & 2 deletions .github/workflows/changeset.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@ jobs:
uses: ./.github/actions/setup-node

- name: Install Dependencies
run: yarn --frozen-lockfile
run: pnpm --frozen-lockfile

- name: Create Release Pull Request or Publish to npm
id: changesets
uses: changesets/action@aba318e9165b45b7948c60273e0b72fce0a64eb9 #v1.4.7
with:
# This expects you to have a script called release which does a build for your packages and calls changeset publish
publish: yarn release
publish: pnpm run release
commit: "chore: prepare release"
title: "chore: prepare release"
env:
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ jobs:

- name: Upgrade dependencies
run: |
yarn --frozen-lockfile --ignore-scripts
yarn talend-upgrade-deps --ignore-scripts
yarn talend-upgrade-deps --scope=@talend --latest --ignore-scripts
yarn talend-upgrade-deps --latest --dry > dependencies-latest.txt
pnpm --frozen-lockfile --ignore-scripts
pnpm talend-upgrade-deps --ignore-scripts
pnpm talend-upgrade-deps --scope=@talend --latest --ignore-scripts
pnpm talend-upgrade-deps --latest --dry > dependencies-latest.txt
Comment on lines +30 to +32
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
pnpm talend-upgrade-deps --ignore-scripts
pnpm talend-upgrade-deps --scope=@talend --latest --ignore-scripts
pnpm talend-upgrade-deps --latest --dry > dependencies-latest.txt
npx talend-upgrade-deps --ignore-scripts
npx talend-upgrade-deps --scope=@talend --latest --ignore-scripts
npx talend-upgrade-deps --latest --dry > dependencies-latest.txt

git add dependencies-latest.txt

- name: Create Pull Request
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/design-system-component-testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,23 +30,23 @@ jobs:
- uses: actions/cache@13aacd865c20de90d75de3b17ebe84f7a17d57d2 #v4.0.0
with:
path: ~/.cache/Cypress
key: my-cache-${{ runner.os }}-${{ hashFiles('yarn.lock') }}
key: my-cache-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}

- name: Install dependencies
run: |
yarn --frozen-lock --ignore-scripts
yarn cypress install
yarn workspace @talend/assets-api run build:lib
yarn workspace @talend/utils run build:lib
yarn workspace @talend/icons run build:lib
yarn workspace @talend/design-tokens run build:lib
pnpm install --frozen-lockfile --ignore-scripts
pnpm cypress install
pnpm --filter @talend/assets-api run build:lib
pnpm --filter @talend/utils run build:lib
pnpm --filter @talend/icons run build:lib
pnpm --filter @talend/design-tokens run build:lib

- name: Cypress Component Testing
uses: cypress-io/github-action@1b70233146622b69e789ccdd4f9452adc638d25a #v6.6.1
with:
install: false
browser: ${{ matrix.browser }}
command: yarn workspace @talend/design-system run test:cy
command: pnpm --filter @talend/design-system run test:cy

- name: Cypress screenshots upload
uses: actions/upload-artifact@694cdabd8bdb0f10b2cea11669e1bf5453eed0a6 #v4.2.0
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/pr-demo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,26 +41,26 @@ jobs:
- name: Install
run: |
node --version
yarn install --frozen-lockfile
pnpm install --frozen-lockfile

- name: Run test:demo
run: |
node --version
yarn test:demo
pnpm run test:demo

- name: Before surge
run: |
node --version
yarn global add surge
echo "$(yarn global bin)" >> $GITHUB_PATH
pnpm add -g surge
# echo "$(yarn global bin)" >> $GITHUB_PATH
node --version
./.github/workflows/before-surge.sh
env:
STORYBOOK_FIGMA_ACCESS_TOKEN: ${{ secrets.STORYBOOK_FIGMA_ACCESS_TOKEN }}

- name: deploy if master
if: github.ref == 'refs/heads/master'
run: surge --project .static --domain "talend.surge.sh"
run: npx surge --project .static --domain "talend.surge.sh"
env:
SURGE_LOGIN: ${{ secrets.SURGE_LOGIN }}
SURGE_TOKEN: ${{ secrets.SURGE_TOKEN }}
Expand All @@ -77,7 +77,7 @@ jobs:
- name: deploy if PR
if: github.ref != 'refs/heads/master'
run: |
surge --project .static --domain "${{ github.event.number }}.talend.surge.sh"
npx surge --project .static --domain "${{ github.event.number }}.talend.surge.sh"
env:
SURGE_LOGIN: ${{ secrets.SURGE_LOGIN }}
SURGE_TOKEN: ${{ secrets.SURGE_TOKEN }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pr-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ jobs:
uses: ./.github/actions/setup-node

- name: Install
run: yarn install --frozen-lockfile --ignore-scripts
run: pnpm install --frozen-lockfile --ignore-scripts

- name: eslint + stylelint
continue-on-error: true
id: eslint
run: yarn lint
run: pnpm lint

- name: Merge lint
run: yarn lint-merge-report master ${GITHUB_HEAD_REF}
run: pnpm lint-merge-report master ${GITHUB_HEAD_REF}

- name: Annotate Code Linting Results
uses: ataylorme/eslint-annotate-action@5f4dc2e3af8d3c21b727edb597e5503510b1dc9c #v2.2.0
Expand Down
13 changes: 6 additions & 7 deletions .github/workflows/pr-playground.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,10 @@ jobs:
- name: Install and build playground
id: build
run: |
yarn install --frozen-lockfile
yarn global add surge
echo "$(yarn global bin)" >> $GITHUB_PATH
yarn pre-release
yarn workspace @talend/ui-playground run test:demo:umd
pnpm install --frozen-lockfile
pnpm add -g surge
pnpm pre-release
pnpm --filter @talend/ui-playground run test:demo:umd

- name: deploy if master
if: github.ref == 'refs/heads/master'
Expand All @@ -46,7 +45,7 @@ jobs:
mkdir .static
mkdir .static/playground
cp -R packages/playground/dist/* .static/playground
surge --project .static --domain "talend-playground.surge.sh"
npx surge --project .static --domain "talend-playground.surge.sh"
env:
SURGE_LOGIN: ${{ secrets.SURGE_LOGIN }}
SURGE_TOKEN: ${{ secrets.SURGE_TOKEN }}
Expand All @@ -58,7 +57,7 @@ jobs:
mkdir .static
mkdir .static/playground
cp -R packages/playground/dist/* .static/playground
surge --project .static --domain "${{ github.event.number }}.talend-playground.surge.sh"
npx surge --project .static --domain "${{ github.event.number }}.talend-playground.surge.sh"
env:
SURGE_LOGIN: ${{ secrets.SURGE_LOGIN }}
SURGE_TOKEN: ${{ secrets.SURGE_TOKEN }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pr-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ jobs:
uses: ./.github/actions/setup-node

- name: Install
run: yarn install --frozen-lockfile
run: pnpm install --frozen-lockfile

- name: Test
run: yarn test --coverage --coverageReporters json-summary
run: pnpm run test --coverage --coverageReporters json-summary

- name: Jest Coverage Comment
uses: MishaKav/jest-coverage-comment@c2d5cfd6c32e8799c6deb0fd76a8e2d9ad8b35c2 #1.0.25
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/tests-cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ jobs:

- name: Install and tests
run: |
yarn --frozen-lockfile --ignore-scripts
yarn test:cron
pnpm --frozen-lockfile --ignore-scripts
pnpm test:cron

- name: Create Issue on Failed workflow
if: ${{ failure() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/visual-testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
uses: ./.github/actions/setup-node

- name: Install dependencies
run: yarn --frozen-lock
run: pnpm install --frozen-lockfile

- name: Publish PR to DS Chromatic
if: github.ref != 'refs/heads/master'
Expand Down
13 changes: 6 additions & 7 deletions .github/workflows/yarn-deduplicate.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: yarn-deduplicate
name: pnpm-deduplicate

on:
pull_request:
paths:
- "yarn.lock"
- "pnpm-lock.yaml"

# This allows a subsequently queued workflow run to interrupt previous runs
concurrency:
Expand Down Expand Up @@ -31,17 +31,16 @@ jobs:
- name: Use Node.js
uses: ./.github/actions/setup-node

- name: yarn-deduplicate
- name: pnpm-deduplicate
id: deduplicate
run: |
yarn
yarn yarn-deduplicate
echo "::set-output name=diff::$(git status --short yarn.lock)"
pnpm dedupe --ignore-scripts
echo "::set-output name=diff::$(git status --short pnpm-lock.yaml)"

- name: Commit dedupe
if: steps.deduplicate.outputs.diff
uses: actions-js/push@156f2b10c3aa000c44dbe75ea7018f32ae999772 #1.4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
message: "chore: yarn-deduplicate"
message: "chore: pnpm-deduplicate"
branch: ${{ github.head_ref }}
56 changes: 56 additions & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
prefer-workspace-packages=true

#https://pnpm.io/blog/2020/10/17/node-modules-configuration-options-with-pnpm#plugnplay-the-strictest-configuration
hoist=false

#########################################
# WARNGING Add public-hoist-pattern ONLY if you don't have other solution
#########################################
# ES LINT
public-hoist-pattern[]=eslint-config-airbnb-base
public-hoist-pattern[]=eslint-plugin-angular
public-hoist-pattern[]=eslint-plugin-cypress
public-hoist-pattern[]=eslint-plugin-import
public-hoist-pattern[]=eslint-plugin-jest-dom
public-hoist-pattern[]=eslint-plugin-jsx-a11y
public-hoist-pattern[]=eslint-plugin-mdx
public-hoist-pattern[]=eslint-plugin-prettier
public-hoist-pattern[]=eslint-plugin-react
public-hoist-pattern[]=eslint-plugin-react-hooks
public-hoist-pattern[]=eslint-plugin-storybook
public-hoist-pattern[]=eslint-plugin-testing-library

# STYLE LINT
public-hoist-pattern[]=postcss-scss
public-hoist-pattern[]=stylelint-config-sass-guidelines

# CYPRESS
public-hoist-pattern[]=cypress

# JEST
public-hoist-pattern[]=jest-environment-jsdom
public-hoist-pattern[]=jest-environment-jsdom-global
public-hoist-pattern[]=jest-serializer-html

# I18N
public-hoist-pattern[]=i18next
public-hoist-pattern[]=react-i18next
public-hoist-pattern[]=i18next-http-backend

# STORYBOOK
public-hoist-pattern[]=@storybook*
public-hoist-pattern[]=msw-storybook-addon

# OTHERS
public-hoist-pattern[]=autoprefixer
public-hoist-pattern[]=lodash
public-hoist-pattern[]=reakit
public-hoist-pattern[]=react-dom
public-hoist-pattern[]=redux*
public-hoist-pattern[]=*types*

# WEBPACK (initially needed to be able to start the playground)
public-hoist-pattern[]=webpack-dev-server



2 changes: 2 additions & 0 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
nodejs 20.9.0
# asdf plugin-add pnpm
pnpm 8.15.5
2 changes: 1 addition & 1 deletion fork/react-bootstrap/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"scripts": {
"build:dev": "talend-scripts build --umd --dev",
"build:prod": "talend-scripts build --umd --prod",
"pre-release": "yarn build:dev && yarn build:prod",
"pre-release": "pnpm build:dev && pnpm build:prod",
"build:lib": "talend-scripts build",
"lint": "talend-scripts lint",
"test": "talend-scripts test",
Expand Down
Loading
Loading