PROD-1033: expand .npmignore to match .gitignore hygiene#175
Merged
Conversation
The published @agility/cli package was shipping non-runtime files (.github/, .claude/, .vscode/, tsconfig*.json, changelog.md, structure.txt, eslint/jest/prettier configs) because .npmignore only excluded three paths and takes precedence over .gitignore. Expand .npmignore to exclude all non-runtime files. Verified with `npm pack --dry-run`: the tarball now ships only dist/, README.md, license.txt, and package.json. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
jules-exel
approved these changes
Jul 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The published
@agility/clinpm package was shipping a lot of non-runtime files. Because.npmignoretakes precedence over.gitignorewhen present, the previous thin.npmignore(which only excluded/src/,/.agility-files/,/agility-files/) meant files excluded from git still made it into the tarball.Before this change,
npm pack --dry-runincluded:.github/,.claude/,.vscode/,.prettierrc,.prettierignore,eslint.config.js,jest.config.js,tsconfig.json,tsconfig.test.json,changelog.md, andstructure.txt.This PR expands
.npmignoreto cover all non-runtime files (dev configs, env files, test artifacts/config, TypeScript/build config, lint/format config, CI/repo tooling, and OS/editor junk), organized to mirror.gitignorehygiene.Verification
npm pack --dry-run(after a cleannpm run build) now ships only:dist/(compiled output +.d.tstype definitions — whatmain/binpoint at)README.mdlicense.txtpackage.jsonAcceptance criteria
.npmignorecovers all non-runtime filesnpm pack --dry-runoutput reviewed — only runtime files shipTicket: https://agilitycms.atlassian.net/browse/PROD-1033
🤖 Generated with Claude Code