From 075b244be23aa788ae21e8c5d50cb99a1296c37f Mon Sep 17 00:00:00 2001 From: Nagy Gabor Date: Wed, 16 Jul 2008 14:42:25 +0200 Subject: -Sqg and -Qqg With --quiet, "pacman -Sg grp" and "pacman -Qg grp" don't list group names. Note that "pacman -Qgq" and "pacman -Sggq" (without targets) still list group names becuase their output would not be very useful without them. Signed-off-by: Nagy Gabor Signed-off-by: Dan McGee --- src/pacman/query.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/pacman/query.c') diff --git a/src/pacman/query.c b/src/pacman/query.c index 74d3ff21..bd2d8c5d 100644 --- a/src/pacman/query.c +++ b/src/pacman/query.c @@ -235,7 +235,12 @@ static int query_group(alpm_list_t *targets) if(grp) { const alpm_list_t *p, *packages = alpm_grp_get_pkgs(grp); for(p = packages; p; p = alpm_list_next(p)) { - printf("%s %s\n", grpname, alpm_pkg_get_name(alpm_list_getdata(p))); + if(!config->quiet) { + printf("%s %s\n", grpname, + alpm_pkg_get_name(alpm_list_getdata(p))); + } else { + printf("%s\n", alpm_pkg_get_name(alpm_list_getdata(p))); + } } } else { pm_fprintf(stderr, PM_LOG_ERROR, _("group \"%s\" was not found\n"), grpname); -- cgit v1.2.3