[arch] fix: not detecting conflicts (regression)

This commit is contained in:
Vinicius Moreira
2022-03-02 15:38:41 -03:00
parent 8c32bfec09
commit 5594a5898a
2 changed files with 5 additions and 3 deletions

View File

@@ -151,7 +151,9 @@ def install_as_process(pkgpaths: Iterable[str], root_password: Optional[str], fi
cmd = ['pacman', '-U'] if file else ['pacman', '-S']
cmd.extend(pkgpaths)
if not simulate:
if simulate:
cmd.append('--confirm')
else:
cmd.append('--noconfirm')
cmd.append('-dd')
@@ -162,7 +164,7 @@ def install_as_process(pkgpaths: Iterable[str], root_password: Optional[str], fi
cmd.append('--asdeps')
return SimpleProcess(cmd=cmd,
root_password=None if simulate else root_password,
root_password=root_password,
cwd=pkgdir,
error_phrases={"error: failed to prepare transaction", 'error: failed to commit transaction', 'error: target not found'},
shell=True)