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

bug: subdirectories in .gitignore are not handled consistently #1360

Open
sellmerfud opened this issue Jan 29, 2025 · 0 comments
Open

bug: subdirectories in .gitignore are not handled consistently #1360

sellmerfud opened this issue Jan 29, 2025 · 0 comments
Labels
errors Something isn't working

Comments

@sellmerfud
Copy link

Mac OS 15.2
eza version: v0.20.18 [+git] (installed with homebrew)
terminal: iterm2 3.5.11


I created a test with the following directory structure:

> tree -aL2 .
.
├── .git
    <contents snipped>
├── .gitignore
├── bar
│   └── file.txt
├── baz
│   └── file.txt
├── foo
│   └── file.txt
└── test.txt

Contents of .gitignore

bar/
test.txt

Files and directories that are in the .gitignore file are correctly ignored when not explicit on the command line.

> eza -1 --git-ignore .
baz
foo

Files in .gitignore are correctly listed if explicitly specified on command line.

> eza -1 --git-ignore test.txt
test.txt

Directories in .gitignore file are not displayed if explicitly specified on the command line.

> eza -1 --git-ignore bar
<no ouput>

If the -T option is added then the directory is included but the contents of the directory are omitted.

> eza -1T --git-ignore foo bar
bar
foo
└── file.txt
@sellmerfud sellmerfud added the errors Something isn't working label Jan 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
errors Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant