aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorArthur Zamarin <arthurzam@gentoo.org>2022-11-16 14:35:05 +0200
committerArthur Zamarin <arthurzam@gentoo.org>2022-11-16 20:08:28 +0200
commit27dd5ec2b8ca977e0b9711eca0d6cba543743a4e (patch)
treec35b3f648ca6cdb1473f02a5b837a654e81b1f7f /src
parentcommit: mention `-e` as nice option (diff)
downloadpkgdev-27dd5ec2b8ca977e0b9711eca0d6cba543743a4e.tar.gz
pkgdev-27dd5ec2b8ca977e0b9711eca0d6cba543743a4e.tar.bz2
pkgdev-27dd5ec2b8ca977e0b9711eca0d6cba543743a4e.zip
build backend: use custom wrapper around flit
For pkgcore we need to run multiple preparations of generating files before creating sdist or wheel. Flit is a very simple and nice build backend, much more than setuptools. Also migrate to use snakeoil.dist sphinx extension for generating man and html, to remove various logic from `doc/conf.py`. Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
Diffstat (limited to 'src')
-rwxr-xr-xsrc/pkgdev/scripts/__init__.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/pkgdev/scripts/__init__.py b/src/pkgdev/scripts/__init__.py
index 2f92c43..164a7f8 100755
--- a/src/pkgdev/scripts/__init__.py
+++ b/src/pkgdev/scripts/__init__.py
@@ -38,9 +38,13 @@ def run(script_name):
sys.exit(tool())
-if __name__ == '__main__':
+def main():
# We're in a git repo or tarball so add the src dir to the system path.
# Note that this assumes a certain module layout.
src_dir = os.path.realpath(__file__).rsplit(os.path.sep, 3)[0]
sys.path.insert(0, src_dir)
- run(os.path.basename(__file__))
+ run(os.path.basename(sys.argv[0]))
+
+
+if __name__ == '__main__':
+ main()