diff --git a/.codeclimate.yml b/.codeclimate.yml new file mode 100644 index 0000000..0f8701f --- /dev/null +++ b/.codeclimate.yml @@ -0,0 +1,16 @@ +--- +engines: + duplication: + enabled: true + config: + languages: + - python + fixme: + enabled: true + radon: + enabled: true +ratings: + paths: + - "**.py" +exclude_paths: + - dist/ \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..ff08d2e --- /dev/null +++ b/Makefile @@ -0,0 +1,12 @@ +init: + pip install --upgrade pip pipenv + pipenv lock + pipenv install --dev +lint: + pipenv run flake8 googledevices + pipenv run pydocstyle googledevices + pipenv run pylint --disable=R0205,R0903,I1101,R0801 googledevices +test: + pipenv run py.test +typing: + pipenv run mypy --ignore-missing-imports googledevices \ No newline at end of file diff --git a/Pipfile b/Pipfile new file mode 100644 index 0000000..03692b0 --- /dev/null +++ b/Pipfile @@ -0,0 +1,17 @@ +[[source]] +url = "https://pypi.python.org/simple" +verify_ssl = true + +[dev-packages] +"flake8" = "*" +mypy = "*" +pydocstyle = "*" +pylint = "*" +pytest-aiohttp = "*" + + +[packages] +aiohttp = "*" +async-timeout = "*" +click = "*" +netifaces = "*" \ No newline at end of file diff --git a/README.md b/README.md index c543054..d0f95b3 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,8 @@ -# googledevices [![Build Status][travis_status]][travis] [![PyPI version][pypi_badge]][pypi] +# googledevices + +[![Build Status][travis_status]][travis] +[![PyPI version][pypi_badge]][pypi] +[![Maintainability][maintainability-badge]][maintainability-url] _API wrapper for Google devices written in Python._ @@ -53,11 +57,29 @@ username@hostname:~$ googledevices scan-network _This is not affiliated, associated, authorized, endorsed by, or in any way officially connected with [Alphabet][alphabet], or any of its subsidiaries or its affiliates. The name "Google" as well as related names, marks, emblems and images are registered trademarks of [Alphabet][alphabet]._ + +## Contributing + +1. [Check for open features/bugs][issues] + or [initiate a discussion on one][issues-new]. +2. [Fork the repository][fork]. +3. Install the dev environment: `make init`. +4. Enter the virtual environment: `pipenv shell` +5. Code your new feature or bug fix. +6. Run `make lint` and make sure the score still is `10.00/10` +7. Submit a [pull request][pull-request]! + [alphabet]: https://abc.xyz/ [eliseomartelli]: https://github.com/eliseomartelli +[fork]: https://github.com/ludeeus/googledevices/fork [GHLocalApi]: https://github.com/rithvikvibhu/GHLocalApi +[issues]: https://github.com/ludeeus/googledevices/issues +[issues-new]: https://github.com/ludeeus/googledevices/issues/new [ludeeus]: https://github.com/ludeeus +[maintainability-badge]: https://api.codeclimate.com/v1/badges/7c88f618d3668ac24a22/maintainability +[maintainability-url]: https://codeclimate.com/github/ludeeus/googledevices/maintainability [travis]: https://travis-ci.com/ludeeus/googledevices [travis_status]: https://travis-ci.com/ludeeus/googledevices.svg?branch=master +[pull-request]: https://github.com/ludeeus/googledevices/compare [pypi]:https://pypi.org/project/googledevices/ [pypi_badge]: https://badge.fury.io/py/googledevices.svg \ No newline at end of file