VoxCommando Forum

Help and Support (Using VoxCommando) => Other Plugins => Topic started by: PegLegTV on June 24, 2015, 09:52:54 PM

Title: Watcher Plugin, file filter question
Post by: PegLegTV on June 24, 2015, 09:52:54 PM
I'm using 2.148 with the new watcher plugin  :D (thanks again jitterjames)

I'm working on a new group of commands that will move video files and use a script from another program that will rename the video file and then move it to the proper location. with this group of commands I have it watch the final destination folders (Movies, TV Shows) and those folders also have- png, jpg, tbn... added to them as well,

so I'm trying to filter the watcher plugin to only look for video files like- mp4, avi, mkv, iso..... and so on,

I've tried these with no luck  :bonk
Quote
*."avi", "mp4", "iso"   

*.("avi", "mp4", "iso")

*".avi", ".mp4", ".iso"

*(".avi", ".mp4", ".iso")

is there a way to filter for multiple file extensions? or to exclude multiple extensions?
Title: Re: Watcher Plugin, file filter questin
Post by: jitterjames on June 24, 2015, 09:58:14 PM
No it is simply not possible with the .Net FileSystemWatcher.  You would need to set up multiple watchers, or use *.*.

https://msdn.microsoft.com/en-us/library/system.io.filesystemwatcher.filter.aspx
Title: Re: Watcher Plugin, file filter questin
Post by: PegLegTV on June 25, 2015, 02:34:42 AM
Thanks for the fast reply, I was a little busy running around trying to get everything turned off we had a nasty storm roll through and the power was flickering like crazy and we where with out power for about 2 hours,

but it gave me some time to think, I was thinking I would use some regex and a logic block if filtering wasn't possible

then after reading your post and some more thinking your option will be better sense I'm using Media Companion to download artwork and .nfo files when my command is done and that could cause hundreds of images and .nfo's to be downloaded depending on how much I added and that means it would have to check the file extension on every item then tell the command to stop over and over

it will make it a little less user friendly to setup but it will be worth it, I have some more testing to do on my group of commands, but hopefully I can get it uploaded tomorrow

Thanks again for the awesome new watcher plugin  ::bow