[arch-dev-public] [PATCH 4/4] makechrootpkg: Fixed add_to_db option check

Dan McGee dpmcgee at gmail.com
Fri Sep 18 19:17:45 EDT 2009


On Fri, Sep 18, 2009 at 5:03 PM, Eric Bélanger <snowmaniscool at gmail.com> wrote:
> Signed-off-by: Eric Bélanger <snowmaniscool at gmail.com>
> ---
>  makechrootpkg |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/makechrootpkg b/makechrootpkg
> index 177a6fd..7b75da5 100755
> --- a/makechrootpkg
> +++ b/makechrootpkg
> @@ -228,7 +228,7 @@ if mkarchroot -r "/chrootbuild" "$uniondir"; then
>     for pkgfile in "${chrootdir}"/union/pkgdest/*${PKGEXT}; do
>           [ -e "$pkgfile" ] || continue
>          _pkgname=$(basename "$pkgfile")
> -         if [ -n "$add_to_db" ]; then
> +         if [ "$add_to_db" -eq "1" ]; then
If you are using the integer operators, you probably don't want the
quotes around either number.

>             [ -d "${chrootdir}/union/repo" ] || mkdir -p "${chrootdir}/union/repo"
>             pushd "${chrootdir}/union/repo" >/dev/null
>             cp "$pkgfile" .
> --
> 1.6.4.4
>
>


More information about the arch-dev-public mailing list