From 98cf7ca473a9b064a334a79625241ee0fb00923a Mon Sep 17 00:00:00 2001 From: Michael De Roover Date: Mon, 10 Aug 2020 17:16:11 +0200 Subject: [PATCH 1/2] Re-add removed $1 to $country conversion --- cv | 1 + 1 file changed, 1 insertion(+) diff --git a/cv b/cv index 8ad968b..dcf874e 100755 --- a/cv +++ b/cv @@ -4,6 +4,7 @@ w=11 dfmt="+%Y-%m-%d" data="$HOME/Documents/cv" +country=$1 [ ! -d "$data" ] && ex "mkdir -p $data" [ -z $date ] && date=$(date $dfmt) [ -z $ydate ] && ydate=$(date -d yesterday $dfmt) From 6fbc0f75d263d2cd061d7330e248e5a091374bea Mon Sep 17 00:00:00 2001 From: Michael De Roover Date: Mon, 10 Aug 2020 17:23:02 +0200 Subject: [PATCH 2/2] Remove environment variable support --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 1006949..938f201 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ This application depends on `jq` to parse the JSON output from corona.lmao.ninja You can clone this repository to your computer using `git clone https://git.ghnou.su/ghnou/cv`. Afterwards you can run cv directly from it, without needing to install it. If you would like to install it, you can copy the program to `/usr/local/bin` or `~/.local/bin`. -From the cloned repository you can run the application using `./cv [country]`, e.g. `./cv Belgium`. For worldwide stats you can use `./cv`. If you wouldn't want to type out your country every time, you can pass an environment variable `$country`. So something like `country=Belgium ./cv` would work too. In that case it would be best to load this variable from file (such as `/etc/environment`, `~/.bashrc` or similar). +From the cloned repository you can run the application using `./cv [country]`, e.g. `./cv Belgium`. For worldwide stats you can use `./cv` without arguments. Short country codes are also supported if you don't want to type the country out entirely. As such `./cv be` would work too. #### Data Collection