From 01b58191ded6ac40429a114438e7bab706e43275 Mon Sep 17 00:00:00 2001 From: Robert Barron Date: Sat, 7 Dec 2019 17:47:44 -0800 Subject: [PATCH 1/2] Add dependencies to Pip packaging. --- setup.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 8e23233..d24b6a9 100644 --- a/setup.py +++ b/setup.py @@ -19,6 +19,15 @@ with open("README.md", "r") as fh: long_description = fh.read() +DEPENDENCIES = ( + "absl-py", + "urllib3", + "pytype", + "attrs>=19", + "parameterized", + "python-dateutil", +) + setuptools.setup( name="google-deputy-api-python-client", version="0.0.1", @@ -33,5 +42,6 @@ "License :: OSI Approved :: Apache Software License", "Operating System :: OS Independent", ], + install_requires=DEPENDENCIES, python_requires='>=3.6', -) \ No newline at end of file +) From 91d939bab8143fb0a70ca631e7ee38ad347e2999 Mon Sep 17 00:00:00 2001 From: Robert Barron Date: Sun, 8 Dec 2019 16:24:37 -0800 Subject: [PATCH 2/2] Update documentation to reference pip packaging. --- README.md | 6 ++++-- deputy/deputy.py | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 5d15480..2b80a63 100644 --- a/README.md +++ b/README.md @@ -11,9 +11,11 @@ This is not an official, or supported, Google product. # Installation -To install all dependencies: +To install package and dependencies: - pip3 install absl-py urllib3 pytype attrs parameterized python-dateutil +``` + pip3 install google-deputy-api-python-client +``` # Contributing diff --git a/deputy/deputy.py b/deputy/deputy.py index 534c78c..381bab4 100755 --- a/deputy/deputy.py +++ b/deputy/deputy.py @@ -52,7 +52,7 @@ Usage: - import deputy + from deputy import deputy # There are two ways to instantiate the Deputy object. To use the flag values # provided when launching the binary: @@ -75,7 +75,7 @@ provided for the `--current_datetime_override` flag. To find 'employees on shift right now': - import deputy + from deputy import deputy client = deputy.Deputy.from_flags()