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

Negation syntax or "include" syntax for new import "ignore" feature #24

Closed
GoogleCodeExporter opened this issue Mar 24, 2015 · 4 comments

Comments

@GoogleCodeExporter
Copy link

This might just be a matter of me having trouble with the appropriate syntax to 
accomplish what I'd like, but ultimately, I'd like to be able to say "ignore 
all files *except* .xyz".

For instance, if I wanted to only import video files or image files from.

The only solution I was able to find about doing this in svn (as you mentioned 
it uses similar syntax) was here: http://www.thoughtspark.org/node/38

The syntax seemed rather clunky. Is there any chance you could perhaps 
implement a "+/-" syntax for inclusion / exclusion of a file mask. The idea 
being someone could type:

-*
+*.xyz

The masks get in sequential order, so first you "exclude" everything and then 
you "include" files ending in ".xyz". This is just an example of a way the 
inclusion/exclusion filter might work (this is how HTTRACK implements file 
masks, but again, it's just one possible way to implement it).

Thanks 

Original issue reported on code.google.com by in...@vittorio.me on 23 Jun 2011 at 2:53

@GoogleCodeExporter
Copy link
Author

The masks get applied* in sequential... 

Original comment by in...@vittorio.me on 23 Jun 2011 at 8:44

@GoogleCodeExporter
Copy link
Author

Agreed. Possibly, this is even more useful for boar than an ignore list. I'd 
expect most users to really just want to store *.jpg or *.raw in a session, and 
ignore all other files. Luckily, this feature is easy to implement now that the 
ignore basics are in place. 

I think the most intuitive way to implement this would be to have an additional 
session property named "include". And if it is set, boar will ignore all other 
types of files. If both "include" and "ignore" is set, then "ignore" will have 
priority. That is, you include "*.jpg" but you ignore "tmp/*", it behaves as 
you would expect. Intuitively it feels like that system would fit most users. 
Any thoughts about this before I implement it?

Original comment by ekb...@gmail.com on 26 Jun 2011 at 2:33

  • Changed state: Accepted
  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

@GoogleCodeExporter
Copy link
Author

Implemented in changeset d32306c81251.

Original comment by ekb...@gmail.com on 27 Jun 2011 at 7:26

  • Changed state: Verified

@GoogleCodeExporter
Copy link
Author

Sounds good to me. And yes, as you do, I expect in most cases people want to 
process only a certain type(s) of files to the exclusion of all else (just 
images, just videos, etc). That said, keeping the ignore parameter for things 
such as tmp files and the like is important as well, so in other words, your 
implementation seems just fine.

Original comment by in...@vittorio.me on 28 Jun 2011 at 2:23

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant