feat(cli): add rooted paths-file scan selection#760
Merged
Conversation
Allow one explicit scan root to consume root-relative path lists so selected-file scans no longer depend on cwd-sensitive positional argument expansion. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Lock in the rooted paths-file contract with validation, cwd-independence, normalization, and warning formatting coverage. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Explain when to use rooted paths-file scans versus multi-input selection so PR-file workflows are documented alongside the existing CLI guidance. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Track rooted paths-file scans and incremental rescans in the beyond-parity improvements index so workflow-level CLI gains have a stable landing zone. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Describe the current paths-file behavior without v1 shorthand so the guide reads as product documentation instead of roadmap language. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Owner
Author
|
Follow-up note on include semantics: This branch now intentionally keeps a sharper split between pattern filtering and explicit path selection.
That differs from the previous Provenant behavior, where bare directory-style |
Separate explicit rooted selection from glob filtering so bare directory-like include values no longer imply recursive subtree scans. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Lock in the narrowed include contract while preserving exact-file and rooted-subtree selection behavior for internal selectors. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Explain that include patterns now require explicit recursive globs while paths-file remains the explicit rooted-selection workflow. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Help ScanCode users adapt path-selection workflows by pointing pattern filtering to --include and exact rooted selection to --paths-file. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
Match slashless include patterns against the basename so literal directory tokens like src stop selecting descendant files implicitly. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai> Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
--paths-file <FILE>for native scans under one explicit root, including stdin support, root-relative normalization, and structured warnings for missing entries--includeso it behaves as an explicit glob/path filter: recursive subtree selection now requires an explicit recursive pattern likesrc/**, while bare directory-like tokens no longer imply descendant selectiondocs/improvements/cli-workflows.mdIssues
Scope and exclusions
--paths-file--paths-file -stdin support--includepattern filtering and rooted path selection--paths-file--paths-filesupport for--from-json--paths-fileentriesIntentional differences from Python
--includeis a glob/path filter, while--paths-fileis the exact rooted-selection workflow.--paths-filecontract is intentionally single-root and root-relative; broader absolute/multi-root support is deferred instead of being partially implemented.Follow-up work
--paths-filesupport until there is evidence that single-root root-relative workflows are insufficient--from-jsonmerge semantics out of this PR because upstream already supports multi-input--from-jsonExpected-output fixture changes