Coder Social home page Coder Social logo

argparse output suxx about suxx HOT 2 OPEN

techtonik avatar techtonik commented on June 3, 2024
argparse output suxx

from suxx.

Comments (2)

techtonik avatar techtonik commented on June 3, 2024

--help output also suxx:

> py -2 -m wheel -h
usage: __main__.py [-h]
                   {keygen,sign,unsign,verify,unpack,install,install-scripts,convert,version,help}
                   ...

positional arguments:
  {keygen,sign,unsign,verify,unpack,install,install-scripts,convert,version,help}
                        commands
    keygen              Generate signing key
    sign                Sign wheel
    unsign              Remove RECORD.jws from a wheel by truncating the zip
                        file. RECORD.jws must be at the end of the archive.
                        The zip file must be an ordinary archive, with the
                        compressed files and the directory in the same order,
                        and without any non-zip content after the truncation
                        point.
    verify              Verify a wheel. The signature will be verified for
                        internal consistency ONLY and printed. Wheel's own
                        unpack/install commands verify the manifest against
                        the signature and file contents.
    unpack              Unpack wheel
    install             Install wheels
    install-scripts     Install console_scripts
    convert             Convert egg or wininst to wheel
    version             Print version and exit
    help                Show this help

optional arguments:
  -h, --help            show this help message and exit

I don't get why people want to name commands as positional arguments and options as optional arguments. I mean if you want to name commands to be something else, you should have the freedom, but by default the names should be sane.

from suxx.

techtonik avatar techtonik commented on June 3, 2024

The proper way to fix this is to export argparse state in nested data structure and format it.

from suxx.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.