Perforce scripts to fill in features lacking from client or command line.
Go to file
Brian 97da25ce38 Threaded console, threaded cleanup. Yes!
Made the threaded console to batch messages and so I could manually
flush or clear them.  At some point I would consider a safety maximum
buffer size that triggers it to auto flush. This worked out really well,
though I have to see why in some cases lines appear to double up still,
could be something with the process not completing when I expect it to.

This is possible a naive thread implementation, since it pushes a
directory for every thread which seems too drastic. I'd like to see how
much better it works without all the context switches.  It's also a
matter of figuring out how much to handle yourself before letting
another thread join in.  Right now the threads don't branch out too much
since I think they basically do a breadth-first search, though I have to
double check on that.

Still to come, trying to safely work with fstat across multiple
directories. It's fast, but on the console the script would appear to
stall as it parses everything, so I'd still want to break it down
somewhat so you can see the script making visible progress.  I would
also prefer this because then console messages wouldn't be so short and
blocky.

Improvements to come!
2014-05-08 22:55:12 -06:00
README.md Update README.md 2014-05-08 19:25:48 -06:00
p4RemoveUnversioned.py Threaded console, threaded cleanup. Yes! 2014-05-08 22:55:12 -06:00

README.md

p4RemoveUnversioned

Removes unversioned files from perforce repository. Script is in beta, though it works. It will be undergoing changes to add thread support to see how much we can speed up searching; depends a lot on your storage device. I will then also try seeing if I can reduce the calls to fstat a bit, it will be a bit more complicated.

This script does parse .p4ignore ignore files, compiles the fields as regex, and scans every directory and file against the local and parent .p4ignore files. This is my first time doing something like this, and I just realized this isn't actually correct; I need to update how things are ignored to follow the spec, since it's not straight up regex.

Files are currently permanently deleted, so use this at your own risk.