skel-manpage.py 523 B

1234567891011121314151617181920
  1. #!/usr/bin/python3
  2. import os
  3. import sys
  4. sys.path.insert(0, os.path.abspath('../'))
  5. import argparse
  6. import qubesadmin.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. 'qubesadmin.tools.<command_name>')
  11. def main():
  12. args = parser.parse_args()
  13. sys.stdout.write(qubesadmin.dochelpers.prepare_manpage(args.command))
  14. if __name__ == '__main__':
  15. main()