Documentation
¶
Overview ¶
Package runtimepath resolves exe-relative paths so SpeechKit's portable-mode bundle finds its bundled assets, models, and per-user data dirs without depending on the OS-level installer having registered a fixed location.
Audit 2026-05-24 maintainability sweep.
Index ¶
- func BundleDir() string
- func BundleDirFor(exeDir string) string
- func BundleHelpersDir() string
- func BundleResourcesDir() string
- func ConfigFilePath() string
- func DataDir() string
- func ExecutableDir() string
- func IsPortable() bool
- func IsTranslocated() bool
- func LocalDataDir() string
- func ModelsDir() string
- func SecretsDir() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BundleDir ¶ added in v0.69.13
func BundleDir() string
BundleDir returns the SpeechKit.app directory the running binary lives in, or "" when it runs outside a bundle (a `go build` output, the test binary).
func BundleDirFor ¶ added in v0.69.13
BundleDirFor maps an executable directory of the form …/SpeechKit.app/Contents/MacOS to the …/SpeechKit.app directory.
func BundleHelpersDir ¶ added in v0.69.13
func BundleHelpersDir() string
BundleHelpersDir is Contents/Helpers (whisper-server and later sidecars) or "" outside a bundle.
func BundleResourcesDir ¶ added in v0.69.13
func BundleResourcesDir() string
BundleResourcesDir is Contents/Resources (config.default.toml, models, icons) or "" outside a bundle.
func ConfigFilePath ¶ added in v0.21.1
func ConfigFilePath() string
func DataDir ¶
func DataDir() string
DataDir is the roaming per-user directory for config, feedback and secrets. Portable bundles keep it next to the executable; installed builds use the platform's per-user location (paths_<os>.go).
func ExecutableDir ¶
func ExecutableDir() string
func IsPortable ¶
func IsPortable() bool
IsPortable reports whether the binary runs from a portable bundle: a config or whisper runtime sits next to the executable and nothing marks the location as a managed install (uninstaller, Program Files, a macOS app bundle, a development checkout).
func IsTranslocated ¶ added in v0.69.13
func IsTranslocated() bool
IsTranslocated reports whether Gatekeeper launched the bundle from a read-only App Translocation mount (a quarantined app opened from ~/Downloads). The in-app updater refuses to swap such a bundle.
func LocalDataDir ¶
func LocalDataDir() string
LocalDataDir is the machine-local per-user directory for large, non-roaming data such as downloaded models and runtimes.
func SecretsDir ¶
func SecretsDir() string
Types ¶
This section is empty.