You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add YAML config file support via koanf (#40)
* feat: add YAML config file support via koanf
Add ~/.config/hypeman/cli.yaml support so the CLI can read base_url and
api_key from a config file instead of requiring environment variables.
Config precedence: CLI flags > env vars > config file.
This pairs with the server-side config migration in kernel/hypeman to
enable a zero-config local experience after running install.sh.
* fix: unify credential resolution across all commands
- Add resolveBaseURL() and resolveAPIKey() helpers to config.go
- Update exec, cp, and push commands to use shared helpers
- All commands now consistently use: flag > env > config file
- WebSocket commands no longer bypass cli.yaml configuration
* fix: unify auth precedence in SDK and WebSocket paths
Update getDefaultRequestOptions to use resolveBaseURL() and
resolveAPIKey() so SDK calls and WebSocket calls share the same
HYPEMAN_BEARER_TOKEN > HYPEMAN_API_KEY > config file precedence.
* fix: give HYPEMAN_API_KEY precedence over HYPEMAN_BEARER_TOKEN
HYPEMAN_API_KEY is the documented primary env var. HYPEMAN_BEARER_TOKEN
is a legacy fallback and should not override it.
* chore: remove internal process comment from cmdutil.go
* refactor: use koanf env provider for HYPEMAN_ env vars
Load HYPEMAN_BASE_URL and HYPEMAN_API_KEY via koanf's env provider
in loadCLIConfig() instead of manual os.Getenv checks. This gives
consistent precedence (env > config file) in one place.
HYPEMAN_BEARER_TOKEN remains as a legacy fallback checked separately.
* refactor: remove legacy HYPEMAN_BEARER_TOKEN support
0 commit comments