churn icon indicating copy to clipboard operation
churn copied to clipboard

Allow more flexible ignores (e.g. **/<file> for nested files)

Open mcandre opened this issue 12 years ago • 3 comments

I have several nested directories that I would like to churn all at once. Many of these each contain their own .gitignore, and I would like to configure churn to not only ignore the top level .gitignore, but any .gitignore in the sub directories as well.

Maybe my syntax is wrong?

$ churn -i ".gitignore, **/.gitignore"
...
| haskell/.gitignore        | 3             |
| latex/.gitignore          | 3             |

mcandre avatar Nov 06 '13 23:11 mcandre

makes sense, I will look at improving the matcher or get back to you with better syntax suggestions.

I basically would want to support the same style as gitignore files

danmayer avatar Nov 08 '13 16:11 danmayer

@danmayer Yeah, I love gitignore style!

mcandre avatar Nov 08 '13 22:11 mcandre

Sorry so I basically forgot about this PR because I was looking for a gitingore implementation... Which was harder to come by than I thought... I tried a few approaches and backed out...

Eventually I pushed this

https://github.com/danmayer/churn/commit/a06eaa5695ac18cbdd561d6990c79a677e226e28

which basically allows regex opposed to exact match.

I did see this which would implement a subset of the most important .gitignore rules... For now it seems to complicated

https://gist.github.com/MrJoy/3868993

@mcandre what do you think... would the regex version work well enough? Also, really sorry this fell off my radar.

danmayer avatar Apr 04 '14 02:04 danmayer