Skip to main content

build_force_sync_update_command

Function build_force_sync_update_command 

Source
pub fn build_force_sync_update_command(
    helper: Option<AurHelper>,
    noconfirm: bool,
) -> CommandSpec
Expand description

What: Build a full-system update command that force-refreshes sync databases.

Inputs:

  • helper: When Some, use the AUR helper; when None, plain pacman.
  • noconfirm: Pass --noconfirm for non-interactive updates.

Output:

  • CommandSpec like pacman -Syyu --noconfirm.

Details:

  • -Syyu re-downloads all sync databases even when they appear up to date; use after mirror changes (mirrors Pacsea’s force-sync update option).
  • Same privilege rules as build_update_command.

§Example

use arch_toolkit::install::build_force_sync_update_command;

let spec = build_force_sync_update_command(None, true);
assert_eq!(spec.to_shell_string(), "pacman -Syyu --noconfirm");