Skip to content
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

feat: option to ignore directories with CACHEDIR.TAG #948

Open
SIGSTACKFAULT opened this issue Apr 24, 2024 · 1 comment · May be fixed by #949
Open

feat: option to ignore directories with CACHEDIR.TAG #948

SIGSTACKFAULT opened this issue Apr 24, 2024 · 1 comment · May be fixed by #949

Comments

@SIGSTACKFAULT
Copy link

SIGSTACKFAULT commented Apr 24, 2024

Problem

I like using eza --tree, but I'm extremely mildly inconvenienced by things like cargo target directories:

tether@Gasoline-Veins ~/D/testasdf> eza --tree
.
├── Cargo.lock
├── Cargo.toml
├── shell.nix
├── src
│  └── main.rs
└── target
   ├── CACHEDIR.TAG
   └── debug
      ├── build
      │  ├── httparse-84bd2fb1031ca66f
      │  │  ├── invoked.timestamp
      │  │  ├── out
      │  │  ├── output
      │  │  ├── root-output
      │  │  └── stderr
      │  ├── httparse-99a751e119a4cca3
      │  │  ├── build-script-build
      │  │  ├── build_script_build-99a751e119a4cca3
      │  │  └── build_script_build-99a751e119a4cca3.d
[624 remaining lines clipped]

I already use --git-ignore in my alias, but sometimes there isn't a .gitignore file. So i would like a way to ignore directories which contain CACHEDIR.TAG.

Solution

add an argument, perhaps named --cachedir-ignore, which causes eza to ignore directories which meet the Cache Directory Tagging Specification. I'll poke around in eza today and might do it.

Stretch Goal

add an argument, or extend --ignore-glob to support hiding directories which contain a specific file (e.g., a tool which doesn't add CACHEDIR.TAG, but has some other uniquely-named file in it's cache directory)

@SIGSTACKFAULT
Copy link
Author

too WIP for a WIP pr: https://github.com/SIGSTACKFAULT/eza/tree/cachedir-ignore

@SIGSTACKFAULT SIGSTACKFAULT linked a pull request Apr 24, 2024 that will close this issue
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant