Skip to content
This repository was archived by the owner on Apr 2, 2026. It is now read-only.

Commit 434bf1e

Browse files
greynewellclaude
andcommitted
docs: add local testing instructions for NPM distribution
Add a detailed guide to CLAUDE.md on how to build, pack, and test the NPM package locally without requiring a full release. Co-Authored-By: Grey Newell <greyshipscode@gmail.com> Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 6d4c5ae commit 434bf1e

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

CLAUDE.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,35 @@ When creating a GitHub issue, always include `@claude` at the end of the body so
3030
- Lint: `go vet ./...`
3131
- No test suite yet — at minimum verify `go build ./...` passes before committing
3232

33+
### Testing NPM Distribution Locally
34+
35+
To test the one-command installation flow without releasing:
36+
37+
1. **Build the latest binary** into the `npm` directory:
38+
```bash
39+
mkdir -p npm/bin && go build -o npm/bin/uncompact .
40+
```
41+
42+
2. **Package and install locally**:
43+
```bash
44+
npm pack
45+
# Replace 0.0.0 with the version in package.json if different
46+
npm install -g ./uncompact-0.0.0.tgz --foreground-scripts
47+
```
48+
*Note: `--foreground-scripts` is required to see the output of the post-install hook.*
49+
50+
3. **Verify installation**:
51+
```bash
52+
uncompact verify-install
53+
uncompact status
54+
```
55+
56+
4. **Total Cleanup** (to reset your environment):
57+
```bash
58+
uncompact uninstall --total
59+
npm uninstall -g uncompact
60+
```
61+
3362
## Commits
3463

3564
Always include both co-authors in every commit message:

0 commit comments

Comments
 (0)