lsd icon indicating copy to clipboard operation
lsd copied to clipboard

Support gitignore

Open theopomies opened this issue 1 year ago • 4 comments

Adds support for filtering out gitignored files

This feature adds a --gitignore CLI flag and a gitignore (optional) boolean key in the config file for filtering out gitignored files.

It makes use of the GitStatus and GitCache structures to provide this feature.

I wrote tests for the Config and Cli flag but couldn't figure out how to write integration tests, I didn't find any tests for the GitStatus or IgnoreGlobs features to take inspiration from.

This partially solves #218 and #342

TODO

  • [x] Use cargo fmt
  • [x] Add necessary tests
  • [x] Update default config/theme in README (if applicable)
  • [x] Update man page at lsd/doc/lsd.md (if applicable)

theopomies avatar Jul 05 '24 08:07 theopomies

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: theopomies Once this PR has been reviewed and has the lgtm label, please assign zwpaper for approval by writing /assign @zwpaper in a comment. For more information see:The Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

muniu-bot[bot] avatar Jul 05 '24 08:07 muniu-bot[bot]

@zwpaper bumping this PR as a user who's interested in this functionality. Any blockers merging this?

rkoten avatar Apr 01 '25 14:04 rkoten

Any updates?

josselinonduty avatar Jun 07 '25 15:06 josselinonduty

@josselinonduty, I just merged it so it remains up to date, but still awaiting review from @zwpaper

theopomies avatar Aug 27 '25 17:08 theopomies