I've finally managed to get FinderJob working the way I've been trying. (It needs more testing before I send a patch, and I'll wait for you to finish with the last one first anyway.)
It accepts both files and directories as arguments. Unless told not to, it tries to skip getting a listing if no other information is required, so it can be used for simple non-recursive operations, too. The top-level argument is now passed to the derived as well; "find dir" will print dir/ dir/file1 dir/file2 like regular find does. Type information is retrieved for this, too. TreatFileJob is now derived from FinderJob. "rm -f file" now works as expected (before it would try to rmdir even if it was a file.) rm/rmdir and rm -r are now a single class. (FinderJob_cmd doesn't do anything; you can probably remove it.) "find file" and "du file" work. chmod for text arguments and chmod -R should be trivial now. Side-effect: find dir1/dir2 will also get a listing for dir1/, for obvious reasons (need the type of dir2, and need to make sure it really exists.) I might be able to help the case of "dir/dir2/" (where we know it's a directory due to the trailing slash, and only need to make sure it exists-- CDing into it is sufficient) within GetFileInfo; probably not worth it. Currently, "find ../" (etc) doesn't work. Working on it. rm and chmod no longer work with urls. I'll try to add URL support to FinderJob. -- Glenn Maynard
