skel-manpage.py 544 B

1234567891011121314151617181920212223
  1. #!/usr/bin/python3
  2. import os
  3. import sys
  4. sys.path.insert(0, os.path.abspath('../'))
  5. import argparse
  6. import qubes.dochelpers
  7. parser = argparse.ArgumentParser(description='prepare new manpage for command')
  8. parser.add_argument('command', metavar='COMMAND',
  9. help='program\'s command name; this should translate to '
  10. 'qubes.tools.<command_name>')
  11. def main():
  12. args = parser.parse_args()
  13. sys.stdout.write(qubes.dochelpers.prepare_manpage(args.command))
  14. if __name__ == '__main__':
  15. main()