mirror of
https://github.com/0xrsydn/idx-cli.git
synced 2026-08-07 01:33:52 +00:00
No description
- Rust 92.9%
- Shell 6.7%
- Nix 0.4%
Add MsnProvider implementing MarketDataProvider trait with quote, fundamentals, and history support. Includes provider-aware config (file/env/CLI), cache namespace isolation per provider, symbol ID mapping via embedded TSV, OHLCV resampling, and comprehensive unit + integration tests with MSN fixture data. Key changes: - MsnProvider with quote, key-ratios, and chart endpoints - ProviderKind enum (yahoo/msn) with config hierarchy support - Provider-namespaced cache buckets to prevent cross-provider poisoning - Provider-aware MockProvider loading correct fixtures per provider - Integration tests for config round-trip and cache isolation Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .github/workflows | ||
| src | ||
| tests | ||
| .envrc | ||
| .gitignore | ||
| .pre-commit-config.yaml | ||
| AGENTS.md | ||
| Cargo.lock | ||
| Cargo.toml | ||
| CLAUDE.md | ||
| flake.lock | ||
| flake.nix | ||
| LICENSE | ||
| README.md | ||
| TODO.md | ||
idx-cli
CLI tool for Indonesian stock market (IDX) analysis, built in Rust for humans and AI agents.
Installation
cargo install idx-cli
nix run github:0xrsydn/idx-cli
Quick start
idx stocks quote BBCA
idx stocks quote BBCA,BBRI,BMRI
idx -o json stocks quote BBCA
idx stocks history BBCA --period 3mo
idx config init
idx cache info
idx --offline stocks quote BBCA
Features
- Provider abstraction (swap data sources behind one interface)
- Local file cache with TTL
- Offline mode with stale-cache fallback
- Human table output and machine-friendly JSON output
Configuration
Config file location:
~/.config/idx/config.toml
You can configure using:
- Config file (
idx config init,idx config set) - Environment variables
- CLI flags
Precedence order:
- CLI flags
- Environment variables
- Config file
- Built-in defaults
Agent-friendly usage
- Use
idx --helpand subcommand help for discoverability - Use
-o json/--output jsonfor structured output - See
skills/for agent workflows and task recipes
Development
nix develop
cargo test
Prek hooks are configured for quality gates:
- pre-commit:
cargo fmt --check+cargo clippy -- -D warnings - pre-push:
cargo test
License
MIT