mirror of
https://gitlab.steamos.cloud/holo/steamos-manager.git
synced 2025-07-12 17:32:21 -04:00
Add format sdcard, update bios/dock, trim devices scripts.
For each of those use the respective polkit-helper script for forward compatibility in case those change.
This commit is contained in:
parent
32963ba2c1
commit
14584d0540
1 changed files with 25 additions and 0 deletions
|
@ -108,6 +108,31 @@ impl SMManager {
|
||||||
value
|
value
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async fn update_bios(&self) -> bool {
|
||||||
|
// Update the bios as needed
|
||||||
|
// Return true if the script was successful (though that might mean no update was needed), false otherwise
|
||||||
|
run_script("update bios", "/usr/bin/steamos-potlkit-helpers/jupiter-biosupdate", &["--auto"]).await
|
||||||
|
}
|
||||||
|
|
||||||
|
async fn update_dock(&self) -> bool {
|
||||||
|
// Update the dock firmware as needed
|
||||||
|
// Retur true if successful, false otherwise
|
||||||
|
run_script("update dock firmware", "/usr/bin/steamos-polkit-helpers/jupiter-dock-updater", &[""]).await
|
||||||
|
}
|
||||||
|
|
||||||
|
async fn trim_devices(&self) -> bool {
|
||||||
|
// Run steamos-trim-devices script
|
||||||
|
// return true on success, false otherwise
|
||||||
|
run_script("trim devices", "/usr/bin/steamos-polkit-helpers/steamos-trim-devices", &[""]).await
|
||||||
|
}
|
||||||
|
|
||||||
|
async fn format_sdcard(&self) -> bool {
|
||||||
|
// Run steamos-format-sdcard script
|
||||||
|
// return true on success, false otherwise
|
||||||
|
run_script("format sdcard", "/usr/bin/steamos-polkit-helpers/steamos-format-sdcard", &[""]).await
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/// A version property.
|
/// A version property.
|
||||||
#[dbus_interface(property)]
|
#[dbus_interface(property)]
|
||||||
async fn version(&self) -> u32 {
|
async fn version(&self) -> u32 {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue