From e3175a117cab82103cc3c47bc51547ac80e8cdfb Mon Sep 17 00:00:00 2001 From: sigma67 Date: Fri, 15 May 2020 20:51:11 +0200 Subject: [PATCH] Add dev dependencies and CONTRIBUTING.rst (#3) --- CONTRIBUTING.rst | 33 +++++++++++++++++++++++++++++++++ setup.py | 9 +++++++++ 2 files changed, 42 insertions(+) create mode 100644 CONTRIBUTING.rst diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst new file mode 100644 index 0000000..255ab1c --- /dev/null +++ b/CONTRIBUTING.rst @@ -0,0 +1,33 @@ +Contributing to ytmusicapi +########################## + +Issues +------- +Please make sure to include sufficient details for reproducing your issue. +This includes the version of the library used as well as detailed instructions for reproduction. +If needed, please include the YouTube Music API response as well by debugging the API (responses +may differ based on the user account, so this helps with reproducing new issues). + + +Pull requests +-------------- +Please open an issue before submitting, unless it's just a typo or some other small error. + +Before making changes to the code, install the development requirements using + +.. code-block:: + + pip install -e .[dev] + +Before committing, run style and linter checks using + +.. code-block:: + + pre-commit run + + +Code structure +--------------- +The folder `ytmusicapi` contains the main library which is distributed to the users. +Each main library function in `ytmusic.py` is covered by a test in the `tests` folder. +If you want to contribute a new function, please create a corresponding unittest. \ No newline at end of file diff --git a/setup.py b/setup.py index 3db94b9..c685859 100644 --- a/setup.py +++ b/setup.py @@ -23,6 +23,15 @@ setup(name='ytmusicapi', install_requires=[ 'requests >= 2.22' ], + extras_require={ + 'dev': [ + 'pre-commit', + 'flake8', + 'yapf', + 'coverage', + 'coverage-badge' + ] + }, python_requires=">=3.5", include_package_data=True, zip_safe=False