Returns the path to `auth.json` inside the opencode data directory.
()
| 44 | static CACHE: Mutex<Option<HashMap<String, CacheEntry>>> = Mutex::new(None); |
| 45 | /// Returns the path to `auth.json` inside the opencode data directory. |
| 46 | fn auth_json_path() -> PathBuf { |
| 47 | let data_dir = dirs::data_dir() |
| 48 | .unwrap_or_else(|| PathBuf::from("~/.local/share")) |
| 49 | .join("opencode"); |
| 50 | data_dir.join("auth.json") |
| 51 | } |
| 52 | |
| 53 | /// Reads `auth.json` and returns only the wellknown entries (url -> WellKnownAuth). |
| 54 | fn read_wellknown_entries() -> HashMap<String, WellKnownAuth> { |
no outgoing calls
no test coverage detected