Skip to content

Commit 24827b2

Browse files
kmelveclaude
andcommitted
chore: migrate from npm to pnpm
- Update CI and release workflows to use pnpm - Add packageManager field to package.json - Replace package-lock.json with pnpm-lock.yaml - Update CLAUDE.md and CONTRIBUTING.md to reference pnpm commands - Remove @sanity-labs/ prefix from package name reference Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 4cd0d1f commit 24827b2

File tree

7 files changed

+2357
-3791
lines changed

7 files changed

+2357
-3791
lines changed

.github/workflows/ci.yml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,24 +16,27 @@ jobs:
1616
runs-on: ubuntu-latest
1717
strategy:
1818
matrix:
19-
node: ['20', '22']
19+
node: ['22', '24']
2020
steps:
2121
- uses: actions/checkout@v4
2222

23+
- name: Setup pnpm
24+
uses: pnpm/action-setup@v4
25+
2326
- name: Setup Node.js
2427
uses: actions/setup-node@v4
2528
with:
2629
node-version: ${{ matrix.node }}
27-
cache: 'npm'
30+
cache: 'pnpm'
2831

2932
- name: Install dependencies
30-
run: npm ci
33+
run: pnpm install --frozen-lockfile
3134

3235
- name: Type check
33-
run: npm run typecheck
36+
run: pnpm typecheck
3437

3538
- name: Build
36-
run: npm run build
39+
run: pnpm build
3740

3841
- name: Test
39-
run: npm run test:run
42+
run: pnpm test:run

.github/workflows/release.yml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,31 @@ jobs:
2222
with:
2323
fetch-depth: 0
2424

25+
- name: Setup pnpm
26+
uses: pnpm/action-setup@v4
27+
2528
- name: Setup Node.js
2629
uses: actions/setup-node@v4
2730
with:
2831
node-version: '22'
29-
cache: 'npm'
32+
cache: 'pnpm'
3033
registry-url: 'https://registry.npmjs.org'
3134

3235
- name: Install dependencies
33-
run: npm ci
36+
run: pnpm install --frozen-lockfile
3437

3538
- name: Build
36-
run: npm run build
39+
run: pnpm build
3740

3841
- name: Test
39-
run: npm run test:run
42+
run: pnpm test:run
4043

4144
- name: Create Release Pull Request or Publish
4245
id: changesets
4346
uses: changesets/action@v1
4447
with:
45-
publish: npx changeset publish
46-
version: npx changeset version
48+
publish: pnpm release
49+
version: pnpm changeset version
4750
title: 'chore: version packages'
4851
commit: 'chore: version packages'
4952
env:

CLAUDE.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
44

55
## Project Overview
66

7-
**boxfix** (`@sanity-labs/boxfix`) is a CLI tool and library that fixes misaligned ASCII diagram borders in markdown files. LLMs often generate diagrams where content lines are shorter than boundary lines - this tool detects and pads those lines to proper width.
7+
**boxfix** is a CLI tool and library that fixes misaligned ASCII diagram borders in markdown files. LLMs often generate diagrams where content lines are shorter than boundary lines - this tool detects and pads those lines to proper width.
88

99
## Workflow
1010

@@ -27,14 +27,14 @@ See [CONTRIBUTING.md](./CONTRIBUTING.md) for detailed guidelines.
2727

2828
```bash
2929
# Build (uses tsup)
30-
npm run build
30+
pnpm build
3131

3232
# Run tests
33-
npm test # Watch mode
34-
npm run test:run # Single run
33+
pnpm test # Watch mode
34+
pnpm test:run # Single run
3535

3636
# Type checking
37-
npm run typecheck
37+
pnpm typecheck
3838

3939
# CLI usage (after build)
4040
./dist/cli.js input.md # Output to stdout

CONTRIBUTING.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,17 @@ Thank you for your interest in contributing to boxfix! This document provides gu
1919

2020
2. Install dependencies:
2121
```bash
22-
npm install
22+
pnpm install
2323
```
2424

2525
3. Build the project:
2626
```bash
27-
npm run build
27+
pnpm build
2828
```
2929

3030
4. Run tests to verify setup:
3131
```bash
32-
npm run test:run
32+
ppnpm test:run
3333
```
3434

3535
## Development Workflow
@@ -52,9 +52,9 @@ The `main` branch is protected with the following rules:
5252
```
5353

5454
2. Make your changes, ensuring:
55-
- Tests pass: `npm run test:run`
56-
- Types check: `npm run typecheck`
57-
- Build succeeds: `npm run build`
55+
- Tests pass: `ppnpm test:run`
56+
- Types check: `pnpm typecheck`
57+
- Build succeeds: `pnpm build`
5858

5959
3. Commit using [conventional commits](#commit-conventions)
6060

@@ -117,8 +117,8 @@ examples/ # Before/after diagram examples
117117
### Running Tests
118118

119119
```bash
120-
npm test # Watch mode
121-
npm run test:run # Single run (CI)
120+
pnpm test # Watch mode
121+
ppnpm test:run # Single run (CI)
122122
```
123123

124124
### Writing Tests
@@ -183,7 +183,7 @@ Releases are managed through [Changesets](https://github.com/changesets/changese
183183

184184
1. Create a changeset when making user-facing changes:
185185
```bash
186-
npm run changeset
186+
pnpm changeset
187187
```
188188

189189
2. Follow the prompts to describe your changes

0 commit comments

Comments
 (0)