Skip to content

Commit 82f152d

Browse files
Migrate to pnpm (#1029)
Co-authored-by: Jordan Pittman <[email protected]>
1 parent a6a29da commit 82f152d

File tree

13 files changed

+5069
-8418
lines changed

13 files changed

+5069
-8418
lines changed

.github/CONTRIBUTING.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ It's never a fun experience to have your pull request declined after investing a
1313
You can build the VSIX package by running these commands in the project root.
1414

1515
```bash
16-
npm install
17-
npx run package --workspace=packages/vscode-tailwindcss
16+
pnpm install
17+
pnpx run package --workspace=packages/vscode-tailwindcss
1818
```

.github/workflows/manual-release.yml

+9-10
Original file line numberDiff line numberDiff line change
@@ -8,26 +8,25 @@ jobs:
88
runs-on: ubuntu-latest
99
steps:
1010
- uses: actions/checkout@v3
11+
- uses: pnpm/action-setup@v3
12+
with:
13+
version: ^9.6.0
1114
- uses: actions/setup-node@v3
1215
with:
1316
node-version: 18
1417
registry-url: 'https://registry.npmjs.org'
15-
- name: Cache node_modules
16-
uses: actions/cache@v3
17-
with:
18-
path: node_modules
19-
key: ${{ runner.os }}-${{ env.NODE_VERSION }}-node_modules-${{ hashFiles('**/package-lock.json') }}
18+
cache: 'pnpm'
2019
- name: Install dependencies
21-
run: npm install
20+
run: pnpm install
2221
- name: Run tests
2322
run: >
2423
cd packages/tailwindcss-language-server &&
25-
npm run build &&
26-
npm run test:prepare &&
27-
npm test
24+
pnpm run build &&
25+
pnpm run test:prepare &&
26+
pnpm test
2827
- name: Publish IntelliSense
2928
env:
3029
VSCODE_TOKEN: ${{ secrets.VSCODE_TOKEN }}
3130
run: >
3231
cd packages/vscode-tailwindcss &&
33-
npm run publish -- -p $VSCODE_TOKEN
32+
pnpm run publish -p $VSCODE_TOKEN

.github/workflows/pre-release.yml

+12-13
Original file line numberDiff line numberDiff line change
@@ -8,23 +8,22 @@ jobs:
88
runs-on: ubuntu-latest
99
steps:
1010
- uses: actions/checkout@v3
11+
- uses: pnpm/action-setup@v3
12+
with:
13+
version: ^9.6.0
1114
- uses: actions/setup-node@v3
1215
with:
1316
node-version: 18
1417
registry-url: 'https://registry.npmjs.org'
15-
- name: Cache node_modules
16-
uses: actions/cache@v3
17-
with:
18-
path: node_modules
19-
key: ${{ runner.os }}-${{ env.NODE_VERSION }}-node_modules-${{ hashFiles('**/package-lock.json') }}
18+
cache: 'pnpm'
2019
- name: Install dependencies
21-
run: npm install
20+
run: pnpm install
2221
- name: Run tests
2322
run: >
2423
cd packages/tailwindcss-language-server &&
25-
npm run build &&
26-
npm run test:prepare &&
27-
npm test
24+
pnpm run build &&
25+
pnpm run test:prepare &&
26+
pnpm test
2827
- name: Bump IntelliSense version
2928
run: >
3029
node .github/workflows/bump-version.mjs &&
@@ -34,19 +33,19 @@ jobs:
3433
VSCODE_TOKEN: ${{ secrets.VSCODE_TOKEN }}
3534
run: >
3635
cd packages/vscode-tailwindcss &&
37-
npm run publish -- --pre-release -p $VSCODE_TOKEN
36+
pnpm run publish --pre-release -p $VSCODE_TOKEN
3837
- name: Build LSP
39-
run: npm run build --workspace=packages/tailwindcss-language-server
38+
run: pnpm run build --workspace=packages/tailwindcss-language-server
4039
- name: Resolve LSP version
4140
run: |
4241
echo "SHA_SHORT=$(git rev-parse --short HEAD)" >> $GITHUB_ENV
4342
- name: 'Version LSP based on commit: 0.0.0-insiders.${{ env.SHA_SHORT }}'
4443
run: >
4544
cd packages/tailwindcss-language-server &&
46-
npm version 0.0.0-insiders.${{ env.SHA_SHORT }} --force --no-git-tag-version
45+
pnpm version 0.0.0-insiders.${{ env.SHA_SHORT }} --force --no-git-tag-version
4746
- name: Publish LSP
4847
run: >
4948
cd packages/tailwindcss-language-server &&
50-
npm publish --tag insiders --access public
49+
pnpm publish --tag insiders --access public
5150
env:
5251
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.vscode/launch.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
"args": ["--extensionDevelopmentPath=${workspaceRoot}/packages/vscode-tailwindcss"],
1111
"stopOnEntry": false,
1212
"sourceMaps": true,
13-
"outFiles": ["${workspaceRoot}/packages/vscode-tailwindcss/dist/**/*.js"]
14-
// "preLaunchTask": "npm: dev"
13+
"outFiles": ["${workspaceRoot}/packages/vscode-tailwindcss/dist/**/*.js"],
14+
"preLaunchTask": "npm: dev"
1515
},
1616
{
1717
"type": "node",

0 commit comments

Comments
 (0)