A command line tool to fetch worldwide data about COVID-19.

栏目: IT技术 · 发布时间: 4年前

内容简介:Track the Coronavirus disease (COVID-19) in the command line.
A command line tool to fetch worldwide data about COVID-19.

A command line tool to fetch worldwide data about COVID-19.

Stay Home, Stay Safe.

coronapy-cli

Track the Coronavirus disease (COVID-19) in the command line.

  • :rocket: Get worldwide Coronavirus disease (COVID-19) reporting
  • Active daily reporting of your country's COVID-19 statistics
  • Data: Country, Cases, Deaths, Recovered, Active, Critical
  • Soon : Get Mroccan States data for Coronavirus disease reports

coronapy-cli

Install

pip install coronapy-cli

A command line tool to fetch worldwide data about COVID-19.

Project Structure

├───.github
├───coronapy
│    ├───lib
│    │   ├───__init.py__
│    │   ├───color.py
│    │   ├───get_countries.py
│    │   ├───get_country.py
│    │   └───get_world_wide.py
│    ├───__init__.py
│    └───cli.py
├───.gitignore
├───LICENSE.txt
├───Pipfile
├───Pipfile.lock
├───READMR.md
├───setup.cfg
└───setup.py

Development

Setup

  1. Clone the repo and cd into it.

  2. Set up a Python 3 virtual environment using pipenv :

    pipenv --three         # create Python 3 virtual environment
    pipenv install --dev   # install all dependencies
    pipenv shell           # activate virtual environment shell
  3. The script can be run from the root directory of the project:

    python3 -m coronapy.cli --help

Usage

Worldwide Information

# Display data for all total cases, recovery, and deaths.
coronapy all

# Display a chart of Total Cases, Total Deaths and Recovered Cases.
coronapy all --chart

# Alias: Display  a char.
coronapy all -c

A command line tool to fetch worldwide data about COVID-19.

All Countries

# Display data for all countries.
coronapy countries

# Sort data by type, the default type is 'cases'.
coronapy countries --sort cases

# Alias: Sort data by type.
corcoronapyona countries -s recovered

A command line tool to fetch worldwide data about COVID-19.

Single Country

# Display data for given country.
coronapy country <country_name>

# Display a chart of Total Cases, Total Deaths and Recovered Cases for given country i.e. China.
coronapy country China --chart

# Alias: Display  a char.
coronapy country China -c

# Display a histogram shows cases or deaths data in last 20 day for given country i.e. USA.
coronapy country usa --hist

# You can set what kind of data (cases or deaths), the default is 'cases'.
coronapy country usa --hist --type cases
coronapy country usa --hist --type deaths

# Alias: Histogram & data type.
coronapy country usa -h -t cases

A command line tool to fetch worldwide data about COVID-19.

Sort Data

# All sorting parameters.
coronapy countries -s country
coronapy countries -s cases
coronapy countries -s todayCases
coronapy countries -s deaths
coronapy countries -s todayDeaths
coronapy countries -s recovered
coronapy countries -s active
coronapy countries -s critical

A command line tool to fetch worldwide data about COVID-19.

CLI Help

# Display the help data.
coronapy --help

To Do

  • Add Screenshots.
  • Catch and handle exceptions.
  • Add Mroccan States data for Coronavirus disease reports.
  • Add US States data for Coronavirus disease reports.
  • Testing code.
  • Make --help command better.
  • More Code Refactor!
  • More... (have suggestions? let me know!)

Issues

If you're facing a problem in using coronapy-cli please let me know by creating an issue in this github repository. I'm happy to help you! Don't forget to provide some screenshot or error logs of it!

Contributing

Contributions are welcome, create a pull request to this repo and I will review your code.

Contributors list

A command line tool to fetch worldwide data about COVID-19. Mouad Boulahdoud A command line tool to fetch worldwide data about COVID-19. Misha Lisovyi A command line tool to fetch worldwide data about COVID-19. aymaneMx

Authors

  • MouadBH

License

This project is licensed under the MIT License - see the LICENSE.txt file for details

Sponsor

This project sponsored by tea .


以上所述就是小编给大家介绍的《A command line tool to fetch worldwide data about COVID-19.》,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对 码农网 的支持!

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

算法霸权

算法霸权

[美] 凯西·奥尼尔 / 马青玲 / 中信出版集团 / 2018-9-1 / 69.00元

数据科学家凯西•奥尼尔认为,我们应该警惕不断渗透和深入我们生活的数学模型——它们的存在,很有可能威胁到我们的社会结构。 我们生活在一个依赖“算法”的时代,它对我们生活的影响越来越大,我们去哪里上学,我是不是应该贷款买车,我们应该花多少钱来买健康保险,这些都不是由人来决定的,而是由大数据模型来决定的。从理论上来说,这一模型应该让社会更加公平,每一个人的衡量标准都是一样的,偏见是不存在的。 ......一起来看看 《算法霸权》 这本书的介绍吧!

CSS 压缩/解压工具
CSS 压缩/解压工具

在线压缩/解压 CSS 代码

JSON 在线解析
JSON 在线解析

在线 JSON 格式化工具

XML 在线格式化
XML 在线格式化

在线 XML 格式化压缩工具