pacman: don't run hooks when using --dbonly
--dbonly is meant to only touch the database and not the actual system. However hooks still run which can leave files in place or run commands you may not want. The hooks being run also means `fakeroot pacman -S --dbpath test/ foo --dbonly` fails because alpm tries to chroot for hooks which requires real root. Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
be76f8bf06
commit
165e492485
1 changed files with 1 additions and 0 deletions
|
@ -634,6 +634,7 @@ static int parsearg_trans(int opt)
|
|||
case OP_DBONLY:
|
||||
config->flags |= ALPM_TRANS_FLAG_DBONLY;
|
||||
config->flags |= ALPM_TRANS_FLAG_NOSCRIPTLET;
|
||||
config->flags |= ALPM_TRANS_FLAG_NOHOOKS;
|
||||
break;
|
||||
case OP_NOPROGRESSBAR:
|
||||
config->noprogressbar = 1;
|
||||
|
|
Loading…
Add table
Reference in a new issue