lingo.dev icon indicating copy to clipboard operation
lingo.dev copied to clipboard

feat(cli): add filters to show files command(#1312)

Open Pruthvi-Parmar opened this issue 2 months ago • 1 comments

Problem

Fixes #1312

The show files command lists all bucket paths but cannot be filtered. Passing --bucket or other filter options results in "unknown option" errors, making it difficult to inspect specific subsets of files in large repositories.

Solution

Added three filter options to the show files command, mirroring the run command:

  • --bucket <bucket> - Filter by bucket type (repeatable)
  • --target-locale <code> - Filter by target locale (repeatable)
  • --file <substr> - Filter by file path pattern (repeatable)

Testing

  • All filters work independently
  • All filters work in combination
  • Repeatable pattern works correctly
  • No linter errors
  • Backward compatible

Examples

# Single filters
show files --bucket json -y
show files --target-locale es -y
show files --file messages -y

# Combined filters
show files --bucket mdx --target-locale fr --file readme -y

Implementation

Follows the same pattern as the run command in packages/cli/src/cli/cmd/run/plan.ts

Pruthvi-Parmar avatar Oct 29 '25 19:10 Pruthvi-Parmar

correct file filter matching logic

Pruthvi-Parmar avatar Nov 14 '25 06:11 Pruthvi-Parmar

Hey @Pruthvi-Parmar! Just checking in - are you still working on this PR? We noticed there are some comments that may need addressing. If you need more time, no problem! Just let us know. If we don't hear back within a week, we'll close this to keep the repo tidy, but you can always reopen when ready.

github-actions[bot] avatar Dec 15 '25 00:12 github-actions[bot]

Actively working on it.. want anyone from the team to review last changes made inorder to address comments by copilot

Pruthvi-Parmar avatar Dec 16 '25 18:12 Pruthvi-Parmar