-
-
Notifications
You must be signed in to change notification settings - Fork 983
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
feat: have if-present apply to recursive runs #2520
Conversation
9252df1
to
8424541
Compare
await execa('pnpm', [ | ||
'install', | ||
'-r', | ||
'--registry', | ||
REGISTRY, | ||
'--store-dir', | ||
path.resolve(DEFAULT_OPTS.storeDir), | ||
]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is not needed
await run.handler({ | ||
...DEFAULT_OPTS, | ||
...await readProjects(process.cwd(), [{ namePattern: '*' }]), | ||
dir: process.cwd(), | ||
ifPresent: true, | ||
recursive: true, | ||
workspaceDir: process.cwd(), | ||
}, ['this-command-does-not-exist']) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You could probably run this in the previous test case as well. That way, one case will test both scenarios.
@@ -217,6 +227,15 @@ test('`pnpm recursive run` fails when run with a filter that includes all packag | |||
version: '1.0.0', | |||
}, | |||
]) | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can add here a comment
t.comment('recursive run does not fail when if-present is true')
5600e21
to
90eb1dc
Compare
Thanks. There are also some linting errors. Run And add some changesets. Run |
🚢 4.14.2 |
I think these changes are correct.
I'm not sure whether the IF_PRESENT related functions /
const
s / help text should move along with the typing.