Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace @antfu/ni and remove @manypkg/find-root #1040

Merged
merged 3 commits into from
Aug 28, 2024

Conversation

askoufis
Copy link
Contributor

@askoufis askoufis commented Aug 27, 2024

@antfu/ni is both a CLI and a library, but we don't use the CLI in sku. package-manager-detector (also an antfu package) is basically just the package manager detection/command constructor part of @antfu/ni, which is all we need.

I've also removed @manypkg/find-root, which IMO has a bad API anyway, with just using find-up (an existing sku dep) to find the closest lockfile. This is pretty much the same method @manypkg/find-root and package-manager-detector use internally anyway.

The reason we don't use package-manager-detector to detect the package manager is because it only provides an async function to do so, which we can't use in our packageManager module as it relies on the global scope.

@askoufis askoufis requested a review from a team as a code owner August 27, 2024 07:33
Copy link

changeset-bot bot commented Aug 27, 2024

🦋 Changeset detected

Latest commit: 1098eb8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
sku Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@askoufis askoufis merged commit 7587294 into master Aug 28, 2024
4 checks passed
@askoufis askoufis deleted the replace-ni-manypkg-find-root branch August 28, 2024 00:28
@seek-oss-ci seek-oss-ci mentioned this pull request Aug 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants