Re: [PATCH 1/2] apply-live-updates.sh: copy without glob

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 20.10.2011 19:57, Will Woods wrote:
> cp $SRC/* $DEST will skip dotfiles in $SRC.
> ( cd $SRC; cp -a -t $DEST . ) will copy everything.
> ---
>  modules.d/90dmsquash-live/apply-live-updates.sh |    5 +++--
>  1 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/modules.d/90dmsquash-live/apply-live-updates.sh b/modules.d/90dmsquash-live/apply-live-updates.sh
> index dfdb404..8dce5d4 100755
> --- a/modules.d/90dmsquash-live/apply-live-updates.sh
> +++ b/modules.d/90dmsquash-live/apply-live-updates.sh
> @@ -1,7 +1,8 @@
>  #!/bin/sh
>  if [ -b /dev/mapper/live-rw ]; then
> -    if [ "`echo /updates/*`" != "/updates/*" ]; then
> +    if pushd /updates &>/dev/null; then
>          echo "Applying updates to live image..."
> -        /bin/cp -a /updates/* $NEWROOT
> +        /bin/cp -a -t $NEWROOT .
> +        popd &>/dev/null
>      fi
>  fi

pushed, thanks
--
To unsubscribe from this list: send the line "unsubscribe initramfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux