hercules-ci / gitignore.nix

Nix functions for filtering local git sources
The Unlicense
242 stars 19 forks source link

Add failing test case for directory with ignored contents #56

Closed Minnozz closed 10 months ago

Minnozz commented 2 years ago

In git, the entire directory does not exist. In gitignore.nix, the empty directory does exist.

This illustrates issue #57.

Minnozz commented 2 years ago

I thought this test case would be the best way to illustrate a problem I'm experiencing with gitignore.nix.

Minnozz commented 1 year ago
❯ nix log /nix/store/7hdr9pfq4cg9j6hc4a0k3qfdlhai5wmk-plain.drv
49d48
< test-tree/13-dir-with-ignored-contents

Found a difference between nix-gitignore and native git.
Above diff can be read as a 'fix' to the nix-gitignore output.
< fix by excluding this in nix-gitignore
> fix by including this in nix-gitignore