taunus-core
The basics every program uses. taunus_core::…
settings
~/.config/taunus/settings.json: one JSON object shared by the shell, Settings and the services. Unknown keys are
kept.
use taunus_core::settings::Settings;
let s = Settings::load();
s.bool("developer"); // also int(), str(), get() (serde_json::Value)
s.text_scale(); // typed getters: animations(), aod(), app_lock(), hud_seconds(), …
Settings::save([("my-key".into(), serde_json::json!(true))])?; // merges and writes atomically
//2bi: settings are typed and namespaced per program (org.taunus.Hello/…), changes are broadcast to every
program, and a program can only write its own keys.
paths
config_dir(), data_dir(), cache_dir(), pictures_dir(), runtime_dir(), control_socket(),
write_atomic(path, data, mode), only_instance(name). See App lifecycle.
lifecycle
restoring(), on_terminate(f), save_state/load_state, block_terminate(), exit(). See
App lifecycle.
form
form_factor() -> FormFactor (Tab | Tv): TAUNUS_FORM_FACTOR, then the Developer override, then the device
profile.
apps
The installed apps, from .desktop files.
for app in taunus_core::apps::all() {
println!("{} {}", app.name, app.id);
}
app.launch(&[])?; // starts it, returns the pid
App::is_taunus() tells Taunus apps from other Linux apps (other apps show on the home screen only when chosen in
Settings › Developer › Launcher apps).
//2bi: a Taunus app is recognised by its manifest, not by its taunus- name.
control
taunus_core::control::send("settings wifi") sends a command to the shell. See The shell.
attest
Proof that the person at the device knows the passcode. See The shell › Passcode proof.
hw
Small hardware helpers: Backlight (get/set 0–1), volume_get/volume_set (PipeWire), speaker_mute_toggle,
physical_keyboard_present, remote_or_keyboard_present, pids_of(name), run/spawn.
DEBUG_BUILD
true in debug images (feature debug-build). Release and debug differ only at build time.