home
/
code
/
covid-19-scrapers.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
acd2abc
)
Update NY URI, location and path
author
Siraaj Khandkar
<siraaj@khandkar.net>
Tue, 17 Mar 2020 20:44:28 +0000
(16:44 -0400)
committer
Siraaj Khandkar
<siraaj@khandkar.net>
Tue, 17 Mar 2020 20:44:28 +0000
(16:44 -0400)
fetch-case-count-usa-ny
patch
|
blob
|
blame
|
history
diff --git
a/fetch-case-count-usa-ny
b/fetch-case-count-usa-ny
index
c50288c
..
808d7be
100755
(executable)
--- a/
fetch-case-count-usa-ny
+++ b/
fetch-case-count-usa-ny
@@
-7,7
+7,9
@@
VALID_LOCATIONS='
Albany
VALID_LOCATIONS='
Albany
+ Allegany
Broome
Broome
+ Clinton
Delaware
Dutchess
Erie
Delaware
Dutchess
Erie
@@
-16,21
+18,26
@@
VALID_LOCATIONS='
Monroe
Montgomery
Nassau
Monroe
Montgomery
Nassau
- New York City
:
+ New York City
New York State (Outside of NYC)
New York State (Outside of NYC)
+ Onondaga
+ Ontario
Orange
Putnam
Orange
Putnam
+ Rensselaer
Rockland
Saratoga
Schenectady
Suffolk
Rockland
Saratoga
Schenectady
Suffolk
+ Sullivan
Tioga
Tompkins
Total Positive Cases (Statewide)
Ulster
Westchester
Tioga
Tompkins
Total Positive Cases (Statewide)
Ulster
Westchester
+ Wyoming
'
'
-DEFAULT_LOCATION='New York City
:
'
+DEFAULT_LOCATION='New York City'
usage() {
printf "Usage: %s [LOCATION]\n" "$0"
usage() {
printf "Usage: %s [LOCATION]\n" "$0"
@@
-47,7
+54,13
@@
case "$1" in
* ) location="$1";;
esac
* ) location="$1";;
esac
-curl 'https://health.ny.gov/diseases/communicable/coronavirus/' \
+# 2020-03-16
+#URI='https://health.ny.gov/diseases/communicable/coronavirus/'
+
+# 2020-03-17
+URI='https://coronavirus.health.ny.gov/county-county-breakdown-positive-cases'
+
+curl "$URI" \
| hxpipe \
| awk -v location="$location" '
BEGIN {
| hxpipe \
| awk -v location="$location" '
BEGIN {
@@
-55,7
+68,10
@@
curl 'https://health.ny.gov/diseases/communicable/coronavirus/' \
#target_path = "/html/body/div/div/div/div/div/div/table/tr/td"
# 2020-03-16 late evening 22:30
#target_path = "/html/body/div/div/div/div/div/div/table/tr/td"
# 2020-03-16 late evening 22:30
- target_path = "/html/body/div/div/div/div/div/div/tr/td"
+ #target_path = "/html/body/div/div/div/div/div/div/tr/td"
+
+ # 2020-03-17 late afternoon 16:35
+ target_path = "/html/body/div/div/main/div/div/div/div/div/div/div/div/table/tbody/tr/td"
}
/^[\(\)]/ {
}
/^[\(\)]/ {
This page took
0.018379 seconds
and
4
git commands to generate.