Skip to content

feat: content-based lockfile detection#6

Merged
split merged 1 commit into
mainfrom
feature/content-based-lockfile-detection
Apr 1, 2026
Merged

feat: content-based lockfile detection#6
split merged 1 commit into
mainfrom
feature/content-based-lockfile-detection

Conversation

@split

@split split commented Apr 1, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add detect method to each lockfile parser (pnpm, npm, yarn, bun) for content-based format detection
  • Change detectLockfile in core to accept lockfile content instead of directory path
  • Refactor FindAffectedOptions to accept pre-parsed LockfileSnapshot and PackageManifest[] instead of raw content and workspace root
  • Move I/O operations (reading lockfiles, loading manifests) to CLI boundary, keeping core functions pure
  • Update tests for content-based detection

Benefits

  1. Core becomes pure — no I/O side effects, fully testable with mock data
  2. More reliable detection — works with any file path, not just conventional filenames
  3. Better separation — CLI handles all I/O, core handles domain logic only

- Add detect method to each lockfile parser (pnpm, npm, yarn, bun)
- Change detectLockfile to accept content instead of directory path
- Refactor FindAffectedOptions to accept pre-parsed snapshots and manifests
- Move I/O to CLI boundary, keeping core functions pure
- Update tests for content-based detection
@split split merged commit 39f8702 into main Apr 1, 2026
3 checks passed
@split split deleted the feature/content-based-lockfile-detection branch April 1, 2026 06:49
@github-actions

github-actions Bot commented Apr 1, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 2.2.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions

github-actions Bot commented Apr 1, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 3.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions

github-actions Bot commented Apr 1, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 2.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions

github-actions Bot commented Apr 1, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 2.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions

github-actions Bot commented Apr 1, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 2.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions

github-actions Bot commented Apr 1, 2026

Copy link
Copy Markdown

🎉 This PR is included in version 2.2.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant