From 6c1d8d28a346e64321b5be966bcb7040cf5984fd Mon Sep 17 00:00:00 2001 From: Pino Toscano Date: Wed, 11 Mar 2015 14:58:14 +0100 Subject: [PATCH] Convert leftover unconditional set -x to DIB_DEBUG_TRACE Commit 36b59c001c1643217449646b371df46d2cb11b91 introduces DIB_DEBUG_TRACE, to be checked in element scripts for enabling tracing. In the aforementioned conversion, few scripts were left with unconditional "set -x" calls: remove them, changing the default value for unset DIB_DEBUG_TRACE from 0 to 1, to retain their older behaviour (as it was done in 36b59c001c1643217449646b371df46d2cb11b91 too). Change-Id: I3d1a9290021bf63de7d4e7752e809852e784ac8b --- elements/centos-minimal/root.d/08-rinse | 3 +-- elements/debian/root.d/08-debootstrap | 3 +-- elements/ubuntu-minimal/root.d/08-debootstrap-ubuntu | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/elements/centos-minimal/root.d/08-rinse b/elements/centos-minimal/root.d/08-rinse index df74e308..5996ff04 100755 --- a/elements/centos-minimal/root.d/08-rinse +++ b/elements/centos-minimal/root.d/08-rinse @@ -15,7 +15,7 @@ # under the License. # -if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then +if [ ${DIB_DEBUG_TRACE:-1} -gt 0 ]; then set -x fi set -eu @@ -32,7 +32,6 @@ RINSE_TARBALL=$DIB_IMAGE_CACHE/rinse-${DISTRO_NAME}-${DIB_RELEASE}-${ARCH}.tar.g DIB_DISTRIBUTION_MIRROR=${DIB_DISTRIBUTION_MIRROR:-http://mirror.centos.org/centos/7/os/x86_64/Packages/} http_proxy=${http_proxy:-} -set -x if [ -n "$DIB_OFFLINE" -o -n "${DIB_CENTOS_USE_RINSE_CACHE:-}" ] && [ -f $RINSE_TARBALL ] ; then echo $RINSE_TARBALL found in cache. Using. sudo tar -C $TARGET_ROOT --numeric-owner -xzf $RINSE_TARBALL diff --git a/elements/debian/root.d/08-debootstrap b/elements/debian/root.d/08-debootstrap index 0d97e2fd..dc128b82 100755 --- a/elements/debian/root.d/08-debootstrap +++ b/elements/debian/root.d/08-debootstrap @@ -15,7 +15,7 @@ # under the License. # -if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then +if [ ${DIB_DEBUG_TRACE:-1} -gt 0 ]; then set -x fi set -eu @@ -37,7 +37,6 @@ fi DIB_DISTRIBUTION_MIRROR=${DIB_DISTRIBUTION_MIRROR:-http://http.debian.net/debian} http_proxy=${http_proxy:-} -set -x if [ -n "$DIB_OFFLINE" -o -n "${DIB_DEBIAN_USE_DEBOOTSTRAP_CACHE:-}" ] && [ -f $DEBOOTSTRAP_TARBALL ] ; then echo $DEBOOTSTRAP_TARBALL found in cache. Using. sudo tar -C $TARGET_ROOT --numeric-owner -xzf $DEBOOTSTRAP_TARBALL diff --git a/elements/ubuntu-minimal/root.d/08-debootstrap-ubuntu b/elements/ubuntu-minimal/root.d/08-debootstrap-ubuntu index 411675ac..cc45971a 100755 --- a/elements/ubuntu-minimal/root.d/08-debootstrap-ubuntu +++ b/elements/ubuntu-minimal/root.d/08-debootstrap-ubuntu @@ -14,7 +14,7 @@ # License for the specific language governing permissions and limitations # under the License. # -if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then +if [ ${DIB_DEBUG_TRACE:-1} -gt 0 ]; then set -x fi set -eu @@ -32,7 +32,6 @@ DEBOOTSTRAP_TARBALL=$DIB_IMAGE_CACHE/debootstrap-${DISTRO_NAME}-${DIB_RELEASE}-$ DIB_DISTRIBUTION_MIRROR=${DIB_DISTRIBUTION_MIRROR:-http://archive.ubuntu.com/ubuntu} http_proxy=${http_proxy:-} -set -x if [ -n "$DIB_OFFLINE" -o -n "${DIB_DEBIAN_USE_DEBOOTSTRAP_CACHE:-}" ] && [ -f $DEBOOTSTRAP_TARBALL ] ; then echo $DEBOOTSTRAP_TARBALL found in cache. Using. sudo tar -C $TARGET_ROOT --numeric-owner -xzf $DEBOOTSTRAP_TARBALL