Allow an affected target to run only on directly modified projects without walking the dependency graph #22566
meDavidNS
started this conversation in
Feature Requests
Replies: 1 comment 1 reply
-
For lint in particular, it's generally not the slowest part of the pipeline so it's less important. If the lint tasks do not have any inputs which start with If we were to add something we would need to design it out further. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Description
I would like to execute a target on all directly affected projects in the nx workspace. My usecase is specifically for linting, but could be usefull for formatting or docs generation as well.
Motivation
For linting I would like to run the target only on directly affected projects, unlike unit tests or e2e tests, reducing the amount of time required to run
nx affected -t lint
. For linting it doesn't make sense to walk the dependency trying to executing the same target on other projects that depend on the directly modified project.Suggested Implementation
For the
nx affected
command implement a --direct or --depth option.Please let me know if you would welcome a PR.
Beta Was this translation helpful? Give feedback.
All reactions