spotters: most-active-in sort with country/region selector, collection tracking (seen marks, progress, filters), refresh scripts score activity and report new NL entries
Some checks failed
Deploy production / deploy (push) Has been cancelled
Some checks failed
Deploy production / deploy (push) Has been cancelled
This commit is contained in:
@@ -9,7 +9,10 @@
|
||||
# that entered the lists (existing ones are kept, Dex numbers are stable).
|
||||
# 2. bun scripts/wildlife-photos.ts --missing CC-licensed iNaturalist photos for species
|
||||
# without photos (new ones included).
|
||||
# --report-new: stdout is one JSON report {generatedAt, totals, newSpecies[] (with photo)}.
|
||||
# 3. bun scripts/spotters-activity.ts wildlife per-country activity scores (iNaturalist
|
||||
# research-grade observations per country) for the "most active in …" sort.
|
||||
# --report-new: stdout is one JSON report {generatedAt, totals, newSpecies[] (with photo)},
|
||||
# plus `nl` per new species and `newInNl` (see scripts/spotters-report-nl.ts).
|
||||
# Without it, progress only. Progress goes to stderr. DB_URL is read from the running app
|
||||
# container and never printed.
|
||||
set -euo pipefail
|
||||
@@ -26,8 +29,10 @@ if [ "${1:-}" = "--report-new" ]; then
|
||||
report=$(mktemp /tmp/wildlife-report.XXXXXX.json)
|
||||
trap 'rm -f "$report"' EXIT
|
||||
bun scripts/wildlife-import.ts --report-new "$@" >"$report"
|
||||
bun scripts/wildlife-photos.ts --missing --enrich "$report"
|
||||
bun scripts/spotters-activity.ts wildlife >&2
|
||||
bun scripts/wildlife-photos.ts --missing --enrich "$report" | bun scripts/spotters-report-nl.ts wildlife
|
||||
else
|
||||
bun scripts/wildlife-import.ts "$@" >&2
|
||||
bun scripts/wildlife-photos.ts --missing >&2
|
||||
bun scripts/spotters-activity.ts wildlife >&2
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user