Commit 2b15bcdf authored by nimrod's avatar nimrod
Browse files

Documentation.

Document the current state of the development. Remove proselint
pre-commit hook as it complains on the usage info and I can't ignore
specific lines and the README is the only file that I want proselint to
lint so out it goes. Add a better description for dry-run (now that I
decided what I meant by it).
parent 43704a6a
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -18,13 +18,6 @@ repos:
    hooks:
      - id: yamllint

  - repo: https://github.com/amperser/proselint/
    rev: 0.11.2
    hooks:
      - id: proselint
        types: [plain-text]
        exclude: LICENSE

  - repo: https://github.com/ambv/black
    rev: 21.6b0
    hooks:
+34 −0
Original line number Diff line number Diff line
@@ -5,6 +5,40 @@ My Nagios plugin wrapper
    :target: https://git.shore.co.il/shore/mnpw/-/commits/master
    :alt: pipeline status

*This software is in early development and is not intended for use yet.*

The goal of this project is running Nagios plugins without a monitoring system.
It is intended for my personal use as the warning and critical alerts go to `my
notification mechanism <https://git.shore.co.il/nimrod/nextcloud-notifier>`_.
There is a small-ish binary that is created in the CI pipeline that doesn't have
any external dependencies (like the Python VM or any 3rd party Python packages).
The binary is avaiable at
https://git.shore.co.il/shore/mnpw/-/jobs/artifacts/master/raw/dist/mnpw?job=build-executable
and should work all Linux distro with glibc 2.17 or newer.

Usage
-----

.. code:: shell

   usage: mnpw [-h] [-v] [-V] [-d] [-t TIMEOUT]
               command [arguments [arguments ...]]

    My Nagios plugin wrapper.

    positional arguments:
      command               Plugin command
      arguments             Command arguments

    optional arguments:
      -h, --help            show this help message and exit
      -v, --verbose         Verbose output
      -V, --version         show program's version number and exit
      -d, --dry-run         Dry-run, don't notify
      -t TIMEOUT, --timeout TIMEOUT
                            Command timeout (in seconds), defaults to
                            10

License
-------

+3 −1
Original line number Diff line number Diff line
@@ -26,7 +26,9 @@ def main():
        action="version",
        version=f"mnpw version {__version__}",
    )
    parser.add_argument("-d", "--dry-run", help="Dry-run", action="store_true")
    parser.add_argument(
        "-d", "--dry-run", help="Dry-run, don't notify", action="store_true"
    )
    parser.add_argument(
        "-t",
        "--timeout",