fc8ab5b216
With sys.path the package depends on the fact that the mangle.pyw launcher is exactly one directory under the package. __file__ on the other hand, is relative to the package, so it does not matter where the mangle.pyw file is or whether it even exists at all, thus making the package self-contained. This is useful when putting the package in site-packages and the launcher into $PATH. |
||
---|---|---|
mangle | ||
ref | ||
.gitignore | ||
LICENSE | ||
mangle.pyw | ||
nodist | ||
README | ||
setup.py |