[pacman-dev] [PATCH] Make the repo-add quiet flag less quiet

Dan McGee dpmcgee at gmail.com
Fri Dec 12 01:10:29 EST 2008


On Fri, Dec 12, 2008 at 12:02 AM,  <aaronmgriffin at gmail.com> wrote:
> From: Aaron Griffin <aaronmgriffin at gmail.com>
>
> Considering one can easily run:
>   repo-add .... >/dev/null
> to get only warnings and errors, the -q flag is mostly useless.
>
> Make the -q flag silence only level 2 messages
Seems fine to me, if no one else has objections.

>
> Signed-off-by: Aaron Griffin <aaronmgriffin at gmail.com>
> ---
>  scripts/repo-add.sh.in |    5 ++---
>  1 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/scripts/repo-add.sh.in b/scripts/repo-add.sh.in
> index 4f9639c..c89e2a5 100644
> --- a/scripts/repo-add.sh.in
> +++ b/scripts/repo-add.sh.in
> @@ -34,7 +34,6 @@ REPO_DB_FILE=""
>  umask 0022
>
>  msg() {
> -       [ $QUIET -ne 0 ] && return
>        local mesg=$1; shift
>        printf "==> ${mesg}\n" "$@" >&1
>  }
> @@ -68,8 +67,8 @@ repo-remove will update a package database by removing the package name\n\
>  specified on the command line from the given repo database. Multiple\n\
>  packages to remove can be specified on the command line.\n\n")"
>        printf "$(gettext "\
> -The -q/--quiet flag to either program will force silent running except\n\
> -in the case of warnings or errors.\n\n")"
> +Use the -q/--quiet flag to minimize output to basic messages, warnings,\n\
> +and errors\n\n")"
>        echo "$(gettext "Example:  repo-add /path/to/repo.db.tar.gz pacman-3.0.0.pkg.tar.gz")"
>        echo "$(gettext "Example:  repo-remove /path/to/repo.db.tar.gz kernel26")"
>  }
> --
> 1.6.0.5
>
> _______________________________________________
> pacman-dev mailing list
> pacman-dev at archlinux.org
> http://archlinux.org/mailman/listinfo/pacman-dev
>


More information about the pacman-dev mailing list