pub fn query_explicit_packages_sync(mode: InstalledPackagesMode) -> Vec<String>Expand description
What: Query pacman directly for explicitly installed packages with the specified mode.
Inputs:
mode: Filter mode for installed packages.LeafOnly: Usespacman -Qetq(explicitly installed AND not required)AllExplicit: Usespacman -Qeq(all explicitly installed)
Output:
- Returns a sorted vector of package names, or empty vector on error.
Details:
- Queries pacman synchronously without using the cache.
- Used when writing
installed_packages.txtto ensure the file reflects the current mode setting.