symlink icon indicating copy to clipboard operation
symlink copied to clipboard

Add a "--skip" or "--exclude" option

Open murgatroid99 opened this issue 8 years ago • 3 comments

I would like to use this library, but one of the packages in my packages directory can't be installed locally, which is making the script as a whole fail. It would be great if I could just use something like --skip directory_name to not touch that entire directory.

murgatroid99 avatar Oct 13 '17 00:10 murgatroid99

Hey, yeah, that is a sensible request. It's a bit problematic as there's already an option to pass multiple search directories, and a --skip dir wouldn't necessarily know which of these to filter in without requiring full paths (or you filter all the folders). A global --exclude pathfilter would be acceptable though.

Bit busy myself atm, but will merge a sensible PR with tests :smile: If you separate your folders into ones that work and ones that don't, you'd avoid this problem entirely though.

clux avatar Oct 13 '17 16:10 clux

Well, the search directories are expected to be relative to the current directory. What if the --skip directories were also relative to the current directory? Then there wouldn't be any ambiguity when filtering.

murgatroid99 avatar Oct 13 '17 16:10 murgatroid99

Yeah, you'd have to take out the leading directory part before doing the filtering down inside the handling for each repo dir, which is a bit awkward, but that could also work.

clux avatar Oct 15 '17 19:10 clux