https://github.com/nandoabreu/simple-ping
Python ping package published in PyPi
https://github.com/nandoabreu/simple-ping
ping pypi pypi-package pypi-source python python-console python-package python-ping
Last synced: 2 months ago
JSON representation
Python ping package published in PyPi
- Host: GitHub
- URL: https://github.com/nandoabreu/simple-ping
- Owner: nandoabreu
- License: mit
- Created: 2020-08-10T15:27:56.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2020-08-10T22:05:10.000Z (over 5 years ago)
- Last Synced: 2026-01-14T11:37:54.874Z (2 months ago)
- Topics: ping, pypi, pypi-package, pypi-source, python, python-console, python-package, python-ping
- Language: Python
- Homepage: https://pypi.org/project/simple-ping/
- Size: 15.6 KB
- Stars: 0
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# simple-ping
Simple Python ping package published in [PyPi](https://pypi.org/project/simple-ping/).
## README Map
- To pip install, run: ` pip install simple-ping `
- To run locally, go to [Run from command line](#run-from-command-line).
- To use the main class, skip to [The main class](#the-main-class).
- Instructions on advanced/technical documentation, go to [Documentation](#documentation).
## Run from command line
From the project's root directory, please run the following command and follow instructions:
$ python -m ping
## The main class
With the python console and the [Ping class](ping/__init__.py), we can get things running:
$ python
>>> from ping import Ping
>>> ping = Ping('localhost')
>>> print(f'Ping avg return: {ping.avg} ms')
>>> print(f'Ping errors return: {ping.returncode} {ping.stderr}')
## Documentation
Please try from python console:
$ python
>>> import ping
>>> help(ping)
Or try from command line:
$ python -c "import ping; print(ping.__doc__)"
All documentation can be found in [docs](docs).