Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-add __main__.py to enable executing as a module #497

Merged
merged 3 commits into from
Mar 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ All contributions are very welcome! You can contribute in many ways:

* Report bugs on the GitHub `issue tracker`_.

* Submit pull requests on the GitHub `repository`_. Ideally make a pull request to the *develop* branch, as I prefer to keep the master branch the same as the most recent release on PyPI. If you do this, be sure to add yourself to the CONTRIBUTORS.md file too!
* Submit pull requests on the GitHub `repository`_. Ideally make a pull request to the *develop* branch, as I prefer to keep the master branch the same as the most recent release on PyPI. If you do this, be sure to add yourself to the CONTRIBUTORS.rst file too!

.. _python code quality: https://mail.python.org/mailman/listinfo/code-quality
.. _issue tracker: https://github.com/PyCQA/prospector/issues
Expand Down
1 change: 1 addition & 0 deletions CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ Contributors
* Kristian Glass (`@doismellburning <https://github.com/doismellburning>`_)
* Luke Hinds (`@lukehinds <https://github.com/lukehinds>`_)
* Matt Seymour (`@mattseymour <https://github.com/mattseymour>`_)
* Michael Tinsley (`@michaeltinsley <https://github.com/michaeltinsley>`_)
* Phil Frost (`@bitglue <https://github.com/bitglue>`_)
* Phil Jones (`@pgjones <https://github.com/pgjones>`_)
* Pierre Sassoulas (`@Pierre-Sassoulas <https://github.com/Pierre-Sassoulas>`_)
Expand Down
3 changes: 3 additions & 0 deletions docs/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ And you can specify a list of python modules::

See below for :ref:`a complete list of options and flags<full_options>`. You can also run ``prospector --help`` for a full list of options and their effects.

Alternatively, prospector can be executed as a module::

python3 -m prospector <args>

Output Format
'''''''''''''
Expand Down
6 changes: 6 additions & 0 deletions prospector/__main__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import sys

from prospector.run import main

if __name__ == "__main__":
sys.exit(main())