1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
|
#!/usr/bin/env python3
#
# This script is only used in development. Package installations will use a
# similar "augur" script automatically created using the entry point feature of
# setuptools.
#
from sys import path, exit
from pathlib import Path
# Try to add our containing package source directory to the Python module
# search path so that we load augur from there instead of any installed
# system-wide.
try:
dev_path = Path(__file__).parent.parent
# Raises an exception if the path doesn't exist.
(dev_path / "augur/__init__.py").resolve()
except:
pass
else:
path.insert(0, str(dev_path))
from augur.__main__ import main
exit( main() )
|