summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Ulrich Niedermann <hun@n-dimensional.de>2011-02-10 16:42:38 +0100
committerJesse Keating <jkeating@redhat.com>2011-02-09 20:36:46 -0700
commit682b73e3feb68802a9f887e2c6dac7edbb9482f7 (patch)
tree51f5ef45c430860bc88132b12e1eac247ec08991
parent6faf450a35601ceb8bafeb9e4f2fdd1a7c0304f9 (diff)
downloadfedora-packager-682b73e3feb68802a9f887e2c6dac7edbb9482f7.zip
fedora-packager-682b73e3feb68802a9f887e2c6dac7edbb9482f7.tar.gz
fedora-packager-682b73e3feb68802a9f887e2c6dac7edbb9482f7.tar.xz
Move actual man page generation call
Move actual man page generation call from Makefile.am to the src/fedpkg_man_page.py __main__ section.
-rw-r--r--Makefile.am2
-rw-r--r--src/fedpkg_man_page.py5
2 files changed, 6 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 0d79b06..fc2dcbf 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -84,7 +84,7 @@ CLEANFILES += fedpkg.1
man1_MANS = fedpkg.1
fedpkg.1: fedpkg
tmpfile="fedpkg.1.$$$$"; \
- if env PYTHONPATH=$(srcdir)/src python -c 'import fedpkg; fedpkg.parse_cmdline(True)' > "$$tmpfile"; then \
+ if $(PYTHON) $(srcdir)/src/fedpkg_man_page.py > "$$tmpfile"; then \
mv -f "$$tmpfile" "$@"; \
else \
rm -f "$$tmpfile"; \
diff --git a/src/fedpkg_man_page.py b/src/fedpkg_man_page.py
index 117ad62..36cd6a4 100644
--- a/src/fedpkg_man_page.py
+++ b/src/fedpkg_man_page.py
@@ -144,3 +144,8 @@ def generate(parser, subparsers):
mf.write(h)
man_file.write(man_footer)
+
+
+if __name__ == '__main__':
+ import fedpkg
+ fedpkg.parse_cmdline(generate_manpage = True)