system¶
System utilities.
- deltona.system.CHROME_DEFAULT_CONFIG_PATH¶
Default Chrome config path.
- deltona.system.CHROME_DEFAULT_LOCAL_STATE_PATH¶
Default Chrome local state path.
- deltona.system.IS_LINUX¶
If the system is Linux.
- exception deltona.system.MultipleKeySlots(dev: str)¶
Bases:
ExceptionRaised when a LUKS device has more than one keyslot.
- deltona.system.find_bluetooth_device_info_by_name(name: str) tuple[str, dict[str, Any]]¶
Get Bluetooth device information from D-Bus (bluez) by name.
Note that not all devices present a name.
-
deltona.system.get_kwriteconfig_commands(file: StrPath =
PosixPath('/home/docs/.config/kdeglobals')) Iterator[str]¶ Generate
kwriteconfig6commands from a KDE configuration file.
-
deltona.system.inhibit_notifications(name: str =
'deltona.system', reason: str ='No reason specified.') bool¶ Disable notifications.
This function is meant to be called from a separate thread from the working task thread during initialisation.
- deltona.system.kill_wine() None¶
Kill all running Wine processes including wineserver and Wine-wrapped executables.
-
deltona.system.pan_connect(device_mac: str, hci: str =
'hci0') None¶ Connect to a Bluetooth PAN (Personal Area Network) device.
-
deltona.system.pan_disconnect(device_mac: str, hci: str =
'hci0') None¶ Disconnect from a Bluetooth PAN (Personal Area Network) device.
- deltona.system.patch_macos_bundle_info_plist(bundle: str | PathLike[str], **data: Any) None¶
Patch a macOS application bundle’s
Info.plistwith additional data.
-
deltona.system.reset_tpm_enrollment(uuid: str, *, dry_run: bool =
True) None¶ Reset TPM2 enrolment for a LUKS-encrypted device.
-
deltona.system.slug_rename(path: str | PathLike[str], *, no_lower: bool =
False) str | PathLike[str]¶ Perform a slug rename on a file or directory.
- deltona.system.uninhibit_notifications() None¶
Enable notifications.
This function is meant to be called from a separate thread from the working task thread during clean-up.
This function is not required to be called if the application will exit as the state will be restored on clean-up of the D-Bus connection.
- Raises:¶
ConnectionError – If D-Bus connection is not available (which can be caused by not having pydbus installed).
-
deltona.system.wait_for_disc(drive_path: Annotated[str | PathLike[str], 'must_exist'] =
'dev/sr0', *, sleep_time: float =1.0) bool¶ Wait for a disc to be ready in a drive.
For Linux only.