flatpak module¶
FlatpakPackage
¶
Detailed information about one installed flatpak package, as a FlatpakPackageInfo.
Commands:
flatpak info <package> 2>/dev/null || true
Returns:
FlatpakPackageInfo | None
Raises:
HostConnectionError
Examples:
Examples can be found in examples/modules/flatpak/flatpak_flatpak_package.py.
FlatpakPackageInfo
¶
Attributes:
| Name | Type | Description |
|---|---|---|
id |
The application's reverse-domain ID (the |
|
ref |
The full install ref (the |
|
version |
The installed version read from the |
FlatpakPackages
¶
The application IDs of the installed flatpak packages.
Commands:
flatpak list --columns=application 2>/dev/null || true
Returns:
list[str]
Raises:
HostConnectionError
Examples:
Examples can be found in examples/modules/flatpak/flatpak_packages.py.
packages
async
¶
packages(
ctx: OpContext,
packages: str
| list[str]
| tuple[str, ...]
| None = None,
remote: str | None = None,
present: bool = True,
**kwargs: Any,
) -> AsyncGenerator[Command]
Install or remove flatpak application packages.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
ctx
|
OpContext
|
Execution context for the operation. |
required |
packages
|
str | list[str] | tuple[str, ...] | None
|
Application IDs to ensure. Prefer tuples when building requests via
|
None
|
remote
|
str | None
|
The remote to install the applications
from (e.g. |
None
|
present
|
bool
|
Whether the applications should be installed. Defaults to True. |
True
|
**kwargs
|
Any
|
Additional keyword arguments. |
{}
|
Yields:
| Name | Type | Description |
|---|---|---|
Command |
AsyncGenerator[Command]
|
Generated flatpak package commands. |
Raises:
HostConnectionError
Examples:
Examples can be found in examples/modules/flatpak/flatpak_packages.py.