(interactive)
Update APT's package index

    NOTE: this function updates APT only. On dnf/yum, there is no need to run
    an update manually. The tool (dnf/yum) updates the package index
    automatically when an install/upgrade command is called.
Update APT's package index
Update APT s package index
def _update_pkg_repo(interactive):
    """Update APT's package index

    NOTE: this function updates APT only. On dnf/yum, there is no need to run
    an update manually. The tool (dnf/yum) updates the package index
    automatically when an install/upgrade command is called.

    """

    if (not which("apt")):
        return

    cmd = ["apt", "update"]
    if (not interactive):
        cmd.append("-y")

    runner.run(cmd, root=True)
def _update_pkg_repo ( interactive ) : if ( not which ( "apt" ) ) : return cmd = [ "apt" , "update" ] if ( not interactive ) : cmd . append ( "-y" ) runner . run ( cmd , root = True )