Skip to main content

prettier test for main

None None

Project description

Miscellaneous Code

is_main()

Instead of the not-so-pretty:

if __name__ == "__main__":
    main()

pip install ismain from PyPI:

$pip install ismain

And use is_main() from ismain:

from ismain import is_main

if is_main():
    main()

Project details

None None

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

ismain-0.0.1-py3-none-any.whl (3.7 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page