https://github.com/genzrizzcode/wca.js
A Command Line Tool for the World Cube Association
https://github.com/genzrizzcode/wca.js
Last synced: 4 days ago
JSON representation
A Command Line Tool for the World Cube Association
- Host: GitHub
- URL: https://github.com/genzrizzcode/wca.js
- Owner: genZrizzCode
- License: mit
- Created: 2026-05-26T03:52:44.000Z (9 days ago)
- Default Branch: main
- Last Pushed: 2026-05-26T04:33:27.000Z (9 days ago)
- Last Synced: 2026-05-26T06:25:41.377Z (9 days ago)
- Language: JavaScript
- Size: 263 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# wcasearch.js
## Install (global)
```bash
npm install -g wcasearch.js
```
## Install (dev)
```bash
npm i
npm link
```
## Usage
```bash
wca help
wca nearby
wca nearby --place "Los Angeles, CA" --radius-km 80
wca nearby --place "Los Angeles, CA" --radius-km 80 --from 2026-06-01 --to 2026-12-31
wca nearby --place "US"
wca nearby --place "Europe"
wca nearby --place "Beijing" --radius-km 1000 --limit 200 --max-pages 50
wca nearby --place "Beijing" --radius-km 1000 --limit 200 --max-pages 50 --all-at-once
wca nearby --place "Beijing" --radius-km 1000 --limit 200 --live 60
wca nearby --place "Beijing" --radius-km 1000 --limit 200 --live
wca nearby --place "Beijing" --radius-km 1000 --limit 200 --live 60 --debug
wca nearby --place "Beijing" --radius-km 1000 --limit 200 --live 60 --debug ./my-run.log
wca live --place "Beijing" --radius-km 1000 --minutes 60
```
Example of a log: [example.log](./example.log)
Notes:
- For city/county lookups, this uses Open-Meteo geocoding first, then falls back to Nominatim.
- If Nominatim blocks requests, set `WCAJS_USER_AGENT` to a real UA string with contact info.
- For large queries (`--limit >= 200` or `--max-pages >= 50`), it prints `Press ⌃C to exit.` and streams results line-by-line.
- `--live` polls for new matching competitions and always prints `Press ⌃C to exit.` at the bottom of each poll cycle.
- `--live` with no duration runs indefinitely only if the CLI can enable OS sleep inhibition (macOS: `caffeinate`, Linux: `systemd-inhibit`, Windows: PowerShell). If not available, it prints instructions and exits.
- `--debug` writes a debug log. In live mode it updates continuously; otherwise it writes the log when the command finishes.