Skip to content

Document --sequential flag for pnpm run "/<regex>/" #9578

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

Open
1 task
MattIPv4 opened this issue May 28, 2025 · 3 comments · May be fixed by pnpm/pnpm.io#672
Open
1 task

Document --sequential flag for pnpm run "/<regex>/" #9578

MattIPv4 opened this issue May 28, 2025 · 3 comments · May be fixed by pnpm/pnpm.io#672

Comments

@MattIPv4
Copy link

MattIPv4 commented May 28, 2025

Contribution

Describe the user story

I currently use npm-run-all2 in many of my packages to run all dev: prefixed scripts, for example, in parallel. I also use npm-run-all2 to run all test: prefixed scripts sequentially.

I can use pnpm run "/<regex>/" to replace the dev: prefixed call, running them in parallel, but I cannot replace the test: prefixed call as pnpm run "/<regex>/" does not allow for sequential running.

Describe the solution you'd like

pnpm run already has a --parallel flag for other situations, so I'd love to see the opposite, a --sequential flag added for this situation.

Describe the drawbacks of your solution

I suppose there is a risk that there isn't a particular guaranteed order for this, but I would assume by default it'll just run in whatever order the scripts are in in package.json, only running those matching the regex pattern.

Describe alternatives you've considered

No response

@btea
Copy link
Member

btea commented May 29, 2025

Currently, the --sequential option is supported. The default execution order is based on the script positions matched in the scripts field, from top to bottom.

@MattIPv4
Copy link
Author

Ahah, I should've tried it locally first! Looks like this is just undocumented then?

@btea
Copy link
Member

btea commented May 29, 2025

Ahah, I should've tried it locally first! Looks like this is just undocumented then?

Yeah, I find that a bit weird too, not sure if it was omitted.#5871 (comment)

@MattIPv4 MattIPv4 changed the title Add --sequential flag for pnpm run "/<regex>/" Document --sequential flag for pnpm run "/<regex>/" May 31, 2025
KSXGitHub added a commit to pnpm/pnpm.io that referenced this issue Jun 1, 2025
@KSXGitHub KSXGitHub linked a pull request Jun 1, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants