Launchpad bug-1179630 Autodetect path search order
Cleaned up code; updated docs.
More style cleanup; added docstrings
Fixed contributors list; saner plugin dir checking.
Pulled from saikobee's branch.
Automatic detection of search path order. Patch by saikobee.