From 63d8341e60c7c864e05ffab1fa03cd8fd26bc9cb Mon Sep 17 00:00:00 2001 From: Rok Roskar <rokroskar@gmail.com> Date: Wed, 8 Apr 2020 17:23:46 +0200 Subject: [PATCH] chore: rename dashboard to utils --- Dockerfile | 2 +- notebooks/Dashboard.ipynb | 4 ++-- .../examples/covidtracking-jhu-diff.ipynb | 2 +- notebooks/examples/italy-covid-19.ipynb | 4 ++-- notebooks/examples/spain-covid-19.ipynb | 0 notebooks/openzh-covid-19-dashboard.ipynb | 2 +- notebooks/process/standardize_datasets.ipynb | 4 ++-- notebooks/process/wikidata-pop-data.ipynb | 2 +- runs/Dashboard.run.ipynb | 2 +- runs/italy-covid-19.ipynb | 4 ++-- runs/openzh-covid-19-dashboard.run.ipynb | 2 +- runs/wikidata-pop-data.run.ipynb | 2 +- .../covid_19_dashboard/tests/__init__.py | 1 - .../.editorconfig | 0 .../.gitignore | 0 .../.travis.yml | 0 .../CONTRIBUTING.rst | 20 +++++++++---------- .../HISTORY.rst | 0 .../LICENSE | 0 .../MANIFEST.in | 0 .../Makefile | 8 ++++---- .../README.rst | 8 ++++---- .../covid_19_utils}/__init__.py | 2 +- .../covid_19_utils}/converters/__init__.py | 0 .../converters/covidtracking.py | 0 .../covid_19_utils}/converters/italy.py | 0 .../covid_19_utils}/converters/jhu.py | 0 .../covid_19_utils}/converters/spain.py | 0 .../covid_19_utils}/converters/switzerland.py | 0 .../covid_19_utils}/helper.py | 3 +-- .../covid_19_utils}/italy_utils.py | 0 .../covid_19_utils}/plotting.py | 0 .../docs/Makefile | 2 +- .../docs/conf.py | 18 ++++++++--------- .../docs/contributing.rst | 0 .../docs/history.rst | 0 .../docs/index.rst | 0 .../docs/installation.rst | 10 +++++----- .../docs/make.bat | 2 +- .../docs/readme.rst | 0 .../docs/usage.rst | 2 +- .../requirements_dev.txt | 0 .../setup.cfg | 2 +- .../setup.py | 8 ++++---- src/covid-19/covid_19_utils/tests/__init__.py | 1 + .../tests/test_covid_19_dashboard.py | 8 ++++---- .../tox.ini | 2 +- 47 files changed, 63 insertions(+), 64 deletions(-) create mode 100644 notebooks/examples/spain-covid-19.ipynb delete mode 100644 src/covid-19/covid_19_dashboard/tests/__init__.py rename src/covid-19/{covid_19_dashboard => covid_19_utils}/.editorconfig (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/.gitignore (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/.travis.yml (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/CONTRIBUTING.rst (85%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/HISTORY.rst (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/LICENSE (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/MANIFEST.in (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/Makefile (92%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/README.rst (73%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/__init__.py (78%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/converters/__init__.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/converters/covidtracking.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/converters/italy.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/converters/jhu.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/converters/spain.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/converters/switzerland.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/helper.py (99%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/italy_utils.py (100%) rename src/covid-19/{covid_19_dashboard/covid_19_dashboard => covid_19_utils/covid_19_utils}/plotting.py (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/Makefile (94%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/conf.py (92%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/contributing.rst (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/history.rst (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/index.rst (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/installation.rst (74%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/make.bat (95%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/readme.rst (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/docs/usage.rst (67%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/requirements_dev.txt (100%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/setup.cfg (87%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/setup.py (85%) create mode 100644 src/covid-19/covid_19_utils/tests/__init__.py rename src/covid-19/{covid_19_dashboard => covid_19_utils}/tests/test_covid_19_dashboard.py (55%) rename src/covid-19/{covid_19_dashboard => covid_19_utils}/tox.ini (85%) diff --git a/Dockerfile b/Dockerfile index 1985ae929..03ca99346 100644 --- a/Dockerfile +++ b/Dockerfile @@ -33,4 +33,4 @@ RUN conda env update -q -f /tmp/environment.yml && \ COPY --chown=rstudio:rstudio src /code/src RUN ln -s /code/src -RUN pip install -e src/covid-19/covid_19_dashboard \ No newline at end of file +RUN pip install -e src/covid-19/covid_19_utils \ No newline at end of file diff --git a/notebooks/Dashboard.ipynb b/notebooks/Dashboard.ipynb index 3e9b7221b..335af9a34 100644 --- a/notebooks/Dashboard.ipynb +++ b/notebooks/Dashboard.ipynb @@ -21,7 +21,7 @@ "import pandas as pd\n", "\n", "from IPython.display import display, HTML, Markdown\n", - "from covid_19_dashboard import helper" + "from covid_19_utils import helper" ] }, { @@ -48,7 +48,7 @@ "outputs": [], "source": [ "# Read in and transform the case data\n", - "from covid_19_dashboard.converters import CaseConverter\n", + "from covid_19_utils.converters import CaseConverter\n", "converter = CaseConverter('../data/atlas')\n", "jhu_df = converter.read_convert(ts_folder)\n", "\n", diff --git a/notebooks/examples/covidtracking-jhu-diff.ipynb b/notebooks/examples/covidtracking-jhu-diff.ipynb index 56733b24f..fc6d00851 100644 --- a/notebooks/examples/covidtracking-jhu-diff.ipynb +++ b/notebooks/examples/covidtracking-jhu-diff.ipynb @@ -1469,7 +1469,7 @@ "from holoviews import opts\n", "from IPython.display import display, HTML, Markdown\n", "\n", - "import covid_19_dashboard as helper\n", + "import covid_19_utils as helper\n", "\n", "hv.extension('bokeh')" ] diff --git a/notebooks/examples/italy-covid-19.ipynb b/notebooks/examples/italy-covid-19.ipynb index 03cbf73d4..c400607e0 100644 --- a/notebooks/examples/italy-covid-19.ipynb +++ b/notebooks/examples/italy-covid-19.ipynb @@ -30,8 +30,8 @@ "\n", "from IPython.display import display, HTML\n", "\n", - "from covid_19_dashboard import helper, plotting\n", - "from covid_19_dashboard.italy_utils import get_region_populations, prepare_dataframe" + "from covid_19_utils import helper, plotting\n", + "from covid_19_utils.italy_utils import get_region_populations, prepare_dataframe" ] }, { diff --git a/notebooks/examples/spain-covid-19.ipynb b/notebooks/examples/spain-covid-19.ipynb new file mode 100644 index 000000000..e69de29bb diff --git a/notebooks/openzh-covid-19-dashboard.ipynb b/notebooks/openzh-covid-19-dashboard.ipynb index 51f0bdb8e..d7475d7ee 100644 --- a/notebooks/openzh-covid-19-dashboard.ipynb +++ b/notebooks/openzh-covid-19-dashboard.ipynb @@ -88,7 +88,7 @@ "outputs": [], "source": [ "# read in population data\n", - "from covid_19_dashboard import helper, plotting\n", + "from covid_19_utils import helper, plotting\n", "\n", "population = {key[3:]: value for (key,value) in helper.get_region_populations('CHE').items()}\n", "\n", diff --git a/notebooks/process/standardize_datasets.ipynb b/notebooks/process/standardize_datasets.ipynb index 64ab3ba8e..d1bca3597 100644 --- a/notebooks/process/standardize_datasets.ipynb +++ b/notebooks/process/standardize_datasets.ipynb @@ -32,8 +32,8 @@ "import altair as alt\n", "import pandas as pd\n", "\n", - "from covid_19_dashboard import helper, plotting\n", - "from covid_19_dashboard.converters import CaseConverter" + "from covid_19_utils import helper, plotting\n", + "from covid_19_utils.converters import CaseConverter" ] }, { diff --git a/notebooks/process/wikidata-pop-data.ipynb b/notebooks/process/wikidata-pop-data.ipynb index e19ba2701..0d582022d 100644 --- a/notebooks/process/wikidata-pop-data.ipynb +++ b/notebooks/process/wikidata-pop-data.ipynb @@ -16,7 +16,7 @@ "import os\n", "import pandas as pd\n", "\n", - "from covid_19_dashboard import helper" + "from covid_19_utils import helper" ] }, { diff --git a/runs/Dashboard.run.ipynb b/runs/Dashboard.run.ipynb index c587a409b..54cdb4ac9 100644 --- a/runs/Dashboard.run.ipynb +++ b/runs/Dashboard.run.ipynb @@ -22,7 +22,7 @@ "import numpy as np\n", "import os\n", "from IPython.display import display, HTML, Markdown\n", - "import covid_19_dashboard as helper" + "import covid_19_utils as helper" ] }, { diff --git a/runs/italy-covid-19.ipynb b/runs/italy-covid-19.ipynb index 246feeaf1..979520fb0 100644 --- a/runs/italy-covid-19.ipynb +++ b/runs/italy-covid-19.ipynb @@ -59,8 +59,8 @@ "\n", "from IPython.display import display, HTML\n", "\n", - "from covid_19_dashboard import helper, plotting\n", - "from covid_19_dashboard.italy_utils import get_region_populations, prepare_dataframe" + "from covid_19_utils import helper, plotting\n", + "from covid_19_utils.italy_utils import get_region_populations, prepare_dataframe" ] }, { diff --git a/runs/openzh-covid-19-dashboard.run.ipynb b/runs/openzh-covid-19-dashboard.run.ipynb index b799708c1..bf1235a32 100644 --- a/runs/openzh-covid-19-dashboard.run.ipynb +++ b/runs/openzh-covid-19-dashboard.run.ipynb @@ -191,7 +191,7 @@ "outputs": [], "source": [ "# read in population data\n", - "from covid_19_dashboard import helper, plotting\n", + "from covid_19_utils import helper, plotting\n", "\n", "population = {key[3:]: value for (key,value) in helper.get_region_populations('CHE').items()}\n", "\n", diff --git a/runs/wikidata-pop-data.run.ipynb b/runs/wikidata-pop-data.run.ipynb index f7bbb999a..129244c2d 100644 --- a/runs/wikidata-pop-data.run.ipynb +++ b/runs/wikidata-pop-data.run.ipynb @@ -34,7 +34,7 @@ "import os\n", "import pandas as pd\n", "\n", - "from covid_19_dashboard import helper" + "from covid_19_utils import helper" ] }, { diff --git a/src/covid-19/covid_19_dashboard/tests/__init__.py b/src/covid-19/covid_19_dashboard/tests/__init__.py deleted file mode 100644 index 710f25a5e..000000000 --- a/src/covid-19/covid_19_dashboard/tests/__init__.py +++ /dev/null @@ -1 +0,0 @@ -"""Unit test package for covid_19_dashboard.""" diff --git a/src/covid-19/covid_19_dashboard/.editorconfig b/src/covid-19/covid_19_utils/.editorconfig similarity index 100% rename from src/covid-19/covid_19_dashboard/.editorconfig rename to src/covid-19/covid_19_utils/.editorconfig diff --git a/src/covid-19/covid_19_dashboard/.gitignore b/src/covid-19/covid_19_utils/.gitignore similarity index 100% rename from src/covid-19/covid_19_dashboard/.gitignore rename to src/covid-19/covid_19_utils/.gitignore diff --git a/src/covid-19/covid_19_dashboard/.travis.yml b/src/covid-19/covid_19_utils/.travis.yml similarity index 100% rename from src/covid-19/covid_19_dashboard/.travis.yml rename to src/covid-19/covid_19_utils/.travis.yml diff --git a/src/covid-19/covid_19_dashboard/CONTRIBUTING.rst b/src/covid-19/covid_19_utils/CONTRIBUTING.rst similarity index 85% rename from src/covid-19/covid_19_dashboard/CONTRIBUTING.rst rename to src/covid-19/covid_19_utils/CONTRIBUTING.rst index d6e62ccca..6014b4421 100644 --- a/src/covid-19/covid_19_dashboard/CONTRIBUTING.rst +++ b/src/covid-19/covid_19_utils/CONTRIBUTING.rst @@ -15,7 +15,7 @@ Types of Contributions Report Bugs ~~~~~~~~~~~ -Report bugs at https://github.com/ciyer/covid_19_dashboard/issues. +Report bugs at https://github.com/ciyer/covid_19_utils/issues. If you are reporting a bug, please include: @@ -45,7 +45,7 @@ articles, and such. Submit Feedback ~~~~~~~~~~~~~~~ -The best way to send feedback is to file an issue at https://github.com/ciyer/covid_19_dashboard/issues. +The best way to send feedback is to file an issue at https://github.com/ciyer/covid_19_utils/issues. If you are proposing a feature: @@ -57,17 +57,17 @@ If you are proposing a feature: Get Started! ------------ -Ready to contribute? Here's how to set up `covid_19_dashboard` for local development. +Ready to contribute? Here's how to set up `covid_19_utils` for local development. -1. Fork the `covid_19_dashboard` repo on GitHub. +1. Fork the `covid_19_utils` repo on GitHub. 2. Clone your fork locally:: - $ git clone git@github.com:your_name_here/covid_19_dashboard.git + $ git clone git@github.com:your_name_here/covid_19_utils.git 3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development:: - $ mkvirtualenv covid_19_dashboard - $ cd covid_19_dashboard/ + $ mkvirtualenv covid_19_utils + $ cd covid_19_utils/ $ python setup.py develop 4. Create a branch for local development:: @@ -79,7 +79,7 @@ Ready to contribute? Here's how to set up `covid_19_dashboard` for local develop 5. When you're done making changes, check that your changes pass flake8 and the tests, including testing other Python versions with tox:: - $ flake8 covid_19_dashboard tests + $ flake8 covid_19_utils tests $ python setup.py test or pytest $ tox @@ -103,7 +103,7 @@ Before you submit a pull request, check that it meets these guidelines: your new functionality into a function with a docstring, and add the feature to the list in README.rst. 3. The pull request should work for Python 3.5, 3.6, 3.7 and 3.8, and for PyPy. Check - https://travis-ci.com/ciyer/covid_19_dashboard/pull_requests + https://travis-ci.com/ciyer/covid_19_utils/pull_requests and make sure that the tests pass for all supported Python versions. Tips @@ -112,7 +112,7 @@ Tips To run a subset of tests:: - $ python -m unittest tests.test_covid_19_dashboard + $ python -m unittest tests.test_covid_19_utils Deploying --------- diff --git a/src/covid-19/covid_19_dashboard/HISTORY.rst b/src/covid-19/covid_19_utils/HISTORY.rst similarity index 100% rename from src/covid-19/covid_19_dashboard/HISTORY.rst rename to src/covid-19/covid_19_utils/HISTORY.rst diff --git a/src/covid-19/covid_19_dashboard/LICENSE b/src/covid-19/covid_19_utils/LICENSE similarity index 100% rename from src/covid-19/covid_19_dashboard/LICENSE rename to src/covid-19/covid_19_utils/LICENSE diff --git a/src/covid-19/covid_19_dashboard/MANIFEST.in b/src/covid-19/covid_19_utils/MANIFEST.in similarity index 100% rename from src/covid-19/covid_19_dashboard/MANIFEST.in rename to src/covid-19/covid_19_utils/MANIFEST.in diff --git a/src/covid-19/covid_19_dashboard/Makefile b/src/covid-19/covid_19_utils/Makefile similarity index 92% rename from src/covid-19/covid_19_dashboard/Makefile rename to src/covid-19/covid_19_utils/Makefile index 924161a62..0c40f844a 100644 --- a/src/covid-19/covid_19_dashboard/Makefile +++ b/src/covid-19/covid_19_utils/Makefile @@ -48,7 +48,7 @@ clean-test: ## remove test and coverage artifacts rm -fr .pytest_cache lint: ## check style with flake8 - flake8 covid_19_dashboard tests + flake8 covid_19_utils tests test: ## run tests quickly with the default Python python setup.py test @@ -57,15 +57,15 @@ test-all: ## run tests on every Python version with tox tox coverage: ## check code coverage quickly with the default Python - coverage run --source covid_19_dashboard setup.py test + coverage run --source covid_19_utils setup.py test coverage report -m coverage html $(BROWSER) htmlcov/index.html docs: ## generate Sphinx HTML documentation, including API docs - rm -f docs/covid_19_dashboard.rst + rm -f docs/covid_19_utils.rst rm -f docs/modules.rst - sphinx-apidoc -o docs/ covid_19_dashboard + sphinx-apidoc -o docs/ covid_19_utils $(MAKE) -C docs clean $(MAKE) -C docs html $(BROWSER) docs/_build/html/index.html diff --git a/src/covid-19/covid_19_dashboard/README.rst b/src/covid-19/covid_19_utils/README.rst similarity index 73% rename from src/covid-19/covid_19_dashboard/README.rst rename to src/covid-19/covid_19_utils/README.rst index c3bb6b169..c2a88a0f1 100644 --- a/src/covid-19/covid_19_dashboard/README.rst +++ b/src/covid-19/covid_19_utils/README.rst @@ -3,11 +3,11 @@ COVID-19 Dashboard ================== -.. image:: https://img.shields.io/pypi/v/covid_19_dashboard.svg - :target: https://pypi.python.org/pypi/covid_19_dashboard +.. image:: https://img.shields.io/pypi/v/covid_19_utils.svg + :target: https://pypi.python.org/pypi/covid_19_utils -.. image:: https://img.shields.io/travis/ciyer/covid_19_dashboard.svg - :target: https://travis-ci.com/ciyer/covid_19_dashboard +.. image:: https://img.shields.io/travis/ciyer/covid_19_utils.svg + :target: https://travis-ci.com/ciyer/covid_19_utils .. image:: https://readthedocs.org/projects/covid-19-dashboard/badge/?version=latest :target: https://covid-19-dashboard.readthedocs.io/en/latest/?badge=latest diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/__init__.py b/src/covid-19/covid_19_utils/covid_19_utils/__init__.py similarity index 78% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/__init__.py rename to src/covid-19/covid_19_utils/covid_19_utils/__init__.py index 5a69e41df..8c5400c2a 100644 --- a/src/covid-19/covid_19_dashboard/covid_19_dashboard/__init__.py +++ b/src/covid-19/covid_19_utils/covid_19_utils/__init__.py @@ -1,4 +1,4 @@ -"""Top-level package for COVID-19 Dashboard.""" +"""Utilities for processing COVID-19 data.""" __author__ = """Chandrasekhar Ramakrishnan""" __email__ = "cramakri@ethz.ch" diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/__init__.py b/src/covid-19/covid_19_utils/covid_19_utils/converters/__init__.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/__init__.py rename to src/covid-19/covid_19_utils/covid_19_utils/converters/__init__.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/covidtracking.py b/src/covid-19/covid_19_utils/covid_19_utils/converters/covidtracking.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/covidtracking.py rename to src/covid-19/covid_19_utils/covid_19_utils/converters/covidtracking.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/italy.py b/src/covid-19/covid_19_utils/covid_19_utils/converters/italy.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/italy.py rename to src/covid-19/covid_19_utils/covid_19_utils/converters/italy.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/jhu.py b/src/covid-19/covid_19_utils/covid_19_utils/converters/jhu.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/jhu.py rename to src/covid-19/covid_19_utils/covid_19_utils/converters/jhu.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/spain.py b/src/covid-19/covid_19_utils/covid_19_utils/converters/spain.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/spain.py rename to src/covid-19/covid_19_utils/covid_19_utils/converters/spain.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/switzerland.py b/src/covid-19/covid_19_utils/covid_19_utils/converters/switzerland.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/converters/switzerland.py rename to src/covid-19/covid_19_utils/covid_19_utils/converters/switzerland.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/helper.py b/src/covid-19/covid_19_utils/covid_19_utils/helper.py similarity index 99% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/helper.py rename to src/covid-19/covid_19_utils/covid_19_utils/helper.py index cda51b983..194e0e7b1 100644 --- a/src/covid-19/covid_19_dashboard/covid_19_dashboard/helper.py +++ b/src/covid-19/covid_19_utils/covid_19_utils/helper.py @@ -1,5 +1,4 @@ -"""Main module. -Helper functions for the dashboard""" +"""Helper functions for the dashboard""" import altair as alt from vega_datasets import data diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/italy_utils.py b/src/covid-19/covid_19_utils/covid_19_utils/italy_utils.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/italy_utils.py rename to src/covid-19/covid_19_utils/covid_19_utils/italy_utils.py diff --git a/src/covid-19/covid_19_dashboard/covid_19_dashboard/plotting.py b/src/covid-19/covid_19_utils/covid_19_utils/plotting.py similarity index 100% rename from src/covid-19/covid_19_dashboard/covid_19_dashboard/plotting.py rename to src/covid-19/covid_19_utils/covid_19_utils/plotting.py diff --git a/src/covid-19/covid_19_dashboard/docs/Makefile b/src/covid-19/covid_19_utils/docs/Makefile similarity index 94% rename from src/covid-19/covid_19_dashboard/docs/Makefile rename to src/covid-19/covid_19_utils/docs/Makefile index ba46b860b..b374269c9 100644 --- a/src/covid-19/covid_19_dashboard/docs/Makefile +++ b/src/covid-19/covid_19_utils/docs/Makefile @@ -4,7 +4,7 @@ # You can set these variables from the command line. SPHINXOPTS = SPHINXBUILD = python -msphinx -SPHINXPROJ = covid_19_dashboard +SPHINXPROJ = covid_19_utils SOURCEDIR = . BUILDDIR = _build diff --git a/src/covid-19/covid_19_dashboard/docs/conf.py b/src/covid-19/covid_19_utils/docs/conf.py similarity index 92% rename from src/covid-19/covid_19_dashboard/docs/conf.py rename to src/covid-19/covid_19_utils/docs/conf.py index c51f68fbf..39fe36323 100755 --- a/src/covid-19/covid_19_dashboard/docs/conf.py +++ b/src/covid-19/covid_19_utils/docs/conf.py @@ -1,6 +1,6 @@ #!/usr/bin/env python # -# covid_19_dashboard documentation build configuration file, created by +# covid_19_utils documentation build configuration file, created by # sphinx-quickstart on Fri Jun 9 13:47:02 2017. # # This file is execfile()d with the current directory set to its @@ -21,7 +21,7 @@ import os import sys sys.path.insert(0, os.path.abspath('..')) -import covid_19_dashboard +import covid_19_utils # -- General configuration --------------------------------------------- @@ -55,9 +55,9 @@ author = "Chandrasekhar Ramakrishnan" # the built documents. # # The short X.Y version. -version = covid_19_dashboard.__version__ +version = covid_19_utils.__version__ # The full version, including alpha/beta/rc tags. -release = covid_19_dashboard.__version__ +release = covid_19_utils.__version__ # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. @@ -100,7 +100,7 @@ html_static_path = ['_static'] # -- Options for HTMLHelp output --------------------------------------- # Output file base name for HTML help builder. -htmlhelp_basename = 'covid_19_dashboarddoc' +htmlhelp_basename = 'covid_19_utilsdoc' # -- Options for LaTeX output ------------------------------------------ @@ -127,7 +127,7 @@ latex_elements = { # (source start file, target name, title, author, documentclass # [howto, manual, or own class]). latex_documents = [ - (master_doc, 'covid_19_dashboard.tex', + (master_doc, 'covid_19_utils.tex', 'COVID-19 Dashboard Documentation', 'Chandrasekhar Ramakrishnan', 'manual'), ] @@ -138,7 +138,7 @@ latex_documents = [ # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). man_pages = [ - (master_doc, 'covid_19_dashboard', + (master_doc, 'covid_19_utils', 'COVID-19 Dashboard Documentation', [author], 1) ] @@ -150,10 +150,10 @@ man_pages = [ # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ - (master_doc, 'covid_19_dashboard', + (master_doc, 'covid_19_utils', 'COVID-19 Dashboard Documentation', author, - 'covid_19_dashboard', + 'covid_19_utils', 'One line description of project.', 'Miscellaneous'), ] diff --git a/src/covid-19/covid_19_dashboard/docs/contributing.rst b/src/covid-19/covid_19_utils/docs/contributing.rst similarity index 100% rename from src/covid-19/covid_19_dashboard/docs/contributing.rst rename to src/covid-19/covid_19_utils/docs/contributing.rst diff --git a/src/covid-19/covid_19_dashboard/docs/history.rst b/src/covid-19/covid_19_utils/docs/history.rst similarity index 100% rename from src/covid-19/covid_19_dashboard/docs/history.rst rename to src/covid-19/covid_19_utils/docs/history.rst diff --git a/src/covid-19/covid_19_dashboard/docs/index.rst b/src/covid-19/covid_19_utils/docs/index.rst similarity index 100% rename from src/covid-19/covid_19_dashboard/docs/index.rst rename to src/covid-19/covid_19_utils/docs/index.rst diff --git a/src/covid-19/covid_19_dashboard/docs/installation.rst b/src/covid-19/covid_19_utils/docs/installation.rst similarity index 74% rename from src/covid-19/covid_19_dashboard/docs/installation.rst rename to src/covid-19/covid_19_utils/docs/installation.rst index 4378653fe..d0bdd199b 100644 --- a/src/covid-19/covid_19_dashboard/docs/installation.rst +++ b/src/covid-19/covid_19_utils/docs/installation.rst @@ -12,7 +12,7 @@ To install COVID-19 Dashboard, run this command in your terminal: .. code-block:: console - $ pip install covid_19_dashboard + $ pip install covid_19_utils This is the preferred method to install COVID-19 Dashboard, as it will always install the most recent stable release. @@ -32,13 +32,13 @@ You can either clone the public repository: .. code-block:: console - $ git clone git://github.com/ciyer/covid_19_dashboard + $ git clone git://github.com/ciyer/covid_19_utils Or download the `tarball`_: .. code-block:: console - $ curl -OJL https://github.com/ciyer/covid_19_dashboard/tarball/master + $ curl -OJL https://github.com/ciyer/covid_19_utils/tarball/master Once you have a copy of the source, you can install it with: @@ -47,5 +47,5 @@ Once you have a copy of the source, you can install it with: $ python setup.py install -.. _Github repo: https://github.com/ciyer/covid_19_dashboard -.. _tarball: https://github.com/ciyer/covid_19_dashboard/tarball/master +.. _Github repo: https://github.com/ciyer/covid_19_utils +.. _tarball: https://github.com/ciyer/covid_19_utils/tarball/master diff --git a/src/covid-19/covid_19_dashboard/docs/make.bat b/src/covid-19/covid_19_utils/docs/make.bat similarity index 95% rename from src/covid-19/covid_19_dashboard/docs/make.bat rename to src/covid-19/covid_19_utils/docs/make.bat index c18343e90..724d38d65 100644 --- a/src/covid-19/covid_19_dashboard/docs/make.bat +++ b/src/covid-19/covid_19_utils/docs/make.bat @@ -9,7 +9,7 @@ if "%SPHINXBUILD%" == "" ( ) set SOURCEDIR=. set BUILDDIR=_build -set SPHINXPROJ=covid_19_dashboard +set SPHINXPROJ=covid_19_utils if "%1" == "" goto help diff --git a/src/covid-19/covid_19_dashboard/docs/readme.rst b/src/covid-19/covid_19_utils/docs/readme.rst similarity index 100% rename from src/covid-19/covid_19_dashboard/docs/readme.rst rename to src/covid-19/covid_19_utils/docs/readme.rst diff --git a/src/covid-19/covid_19_dashboard/docs/usage.rst b/src/covid-19/covid_19_utils/docs/usage.rst similarity index 67% rename from src/covid-19/covid_19_dashboard/docs/usage.rst rename to src/covid-19/covid_19_utils/docs/usage.rst index e459b07b7..27752ebee 100644 --- a/src/covid-19/covid_19_dashboard/docs/usage.rst +++ b/src/covid-19/covid_19_utils/docs/usage.rst @@ -4,4 +4,4 @@ Usage To use COVID-19 Dashboard in a project:: - import covid_19_dashboard + import covid_19_utils diff --git a/src/covid-19/covid_19_dashboard/requirements_dev.txt b/src/covid-19/covid_19_utils/requirements_dev.txt similarity index 100% rename from src/covid-19/covid_19_dashboard/requirements_dev.txt rename to src/covid-19/covid_19_utils/requirements_dev.txt diff --git a/src/covid-19/covid_19_dashboard/setup.cfg b/src/covid-19/covid_19_utils/setup.cfg similarity index 87% rename from src/covid-19/covid_19_dashboard/setup.cfg rename to src/covid-19/covid_19_utils/setup.cfg index 33a68f1a9..0ecf1c76c 100644 --- a/src/covid-19/covid_19_dashboard/setup.cfg +++ b/src/covid-19/covid_19_utils/setup.cfg @@ -7,7 +7,7 @@ tag = True search = version='{current_version}' replace = version='{new_version}' -[bumpversion:file:covid_19_dashboard/__init__.py] +[bumpversion:file:covid_19_utils/__init__.py] search = __version__ = '{current_version}' replace = __version__ = '{new_version}' diff --git a/src/covid-19/covid_19_dashboard/setup.py b/src/covid-19/covid_19_utils/setup.py similarity index 85% rename from src/covid-19/covid_19_dashboard/setup.py rename to src/covid-19/covid_19_utils/setup.py index d045ce8e9..2fe22eec2 100644 --- a/src/covid-19/covid_19_dashboard/setup.py +++ b/src/covid-19/covid_19_utils/setup.py @@ -36,13 +36,13 @@ setup( license="Apache Software License 2.0", long_description=readme + '\n\n' + history, include_package_data=True, - keywords='covid_19_dashboard', - name='covid_19_dashboard', - packages=find_packages(include=['covid_19_dashboard', 'covid_19_dashboard.*']), + keywords='covid_19_utils', + name='covid_19_utils', + packages=find_packages(include=['covid_19_utils', 'covid_19_utils.*']), setup_requires=setup_requirements, test_suite='tests', tests_require=test_requirements, - url='https://github.com/ciyer/covid_19_dashboard', + url='https://github.com/ciyer/covid_19_utils', version='0.1.0', zip_safe=False, ) diff --git a/src/covid-19/covid_19_utils/tests/__init__.py b/src/covid-19/covid_19_utils/tests/__init__.py new file mode 100644 index 000000000..13c18f5f6 --- /dev/null +++ b/src/covid-19/covid_19_utils/tests/__init__.py @@ -0,0 +1 @@ +"""Unit test package for covid_19_utils.""" diff --git a/src/covid-19/covid_19_dashboard/tests/test_covid_19_dashboard.py b/src/covid-19/covid_19_utils/tests/test_covid_19_dashboard.py similarity index 55% rename from src/covid-19/covid_19_dashboard/tests/test_covid_19_dashboard.py rename to src/covid-19/covid_19_utils/tests/test_covid_19_dashboard.py index 2bb0a85f8..17a7acf76 100644 --- a/src/covid-19/covid_19_dashboard/tests/test_covid_19_dashboard.py +++ b/src/covid-19/covid_19_utils/tests/test_covid_19_dashboard.py @@ -1,15 +1,15 @@ #!/usr/bin/env python -"""Tests for `covid_19_dashboard` package.""" +"""Tests for `covid_19_utils` package.""" import unittest -from covid_19_dashboard import covid_19_dashboard +from covid_19_utils import covid_19_utils -class TestCovid_19_dashboard(unittest.TestCase): - """Tests for `covid_19_dashboard` package.""" +class Testcovid_19_utils(unittest.TestCase): + """Tests for `covid_19_utils` package.""" def setUp(self): """Set up test fixtures, if any.""" diff --git a/src/covid-19/covid_19_dashboard/tox.ini b/src/covid-19/covid_19_utils/tox.ini similarity index 85% rename from src/covid-19/covid_19_dashboard/tox.ini rename to src/covid-19/covid_19_utils/tox.ini index 0a00bcd95..269fa95f0 100644 --- a/src/covid-19/covid_19_dashboard/tox.ini +++ b/src/covid-19/covid_19_utils/tox.ini @@ -11,7 +11,7 @@ python = [testenv:flake8] basepython = python deps = flake8 -commands = flake8 covid_19_dashboard tests +commands = flake8 covid_19_utils tests [testenv] setenv = -- GitLab