This is an automated email from the ASF dual-hosted git repository.

gnutt pushed a commit to branch pr589
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit bb3ddab4130f53ba3e294d863bb11dff3b526c78
Author: Xiang Xiao <[email protected]>
AuthorDate: Thu Mar 19 13:43:30 2020 +0800

    tools/refresh.sh: Invoke make with V=1 if receiving -d option
    
    Signed-off-by: Xiang Xiao <[email protected]>
    Change-Id: I8fda13c3faa955a771efd6841e0da09f8e4d8303
---
 tools/refresh.sh | 29 ++++++++++++++++++++++-------
 1 file changed, 22 insertions(+), 7 deletions(-)

diff --git a/tools/refresh.sh b/tools/refresh.sh
index 3765316..14a9a6e 100755
--- a/tools/refresh.sh
+++ b/tools/refresh.sh
@@ -38,6 +38,7 @@ USAGE="USAGE: $0 [options] <board>:<config>"
 ADVICE="Try '$0 --help' for more information"
 
 unset CONFIGS
+debug=n
 defaults=n
 prompt=y
 nocopy=n
@@ -45,6 +46,7 @@ nocopy=n
 while [ ! -z "$1" ]; do
   case $1 in
   --debug )
+    debug=y
     set -x
     ;;
   --silent )
@@ -233,23 +235,36 @@ for CONFIG in ${CONFIGS}; do
     # Then run oldconfig or oldefconfig
 
     if [ "X${defaults}" == "Xy" ]; then
-      make olddefconfig
+      if [ "X${debug}" = "Xy" ]; then
+        make olddefconfig V=1
+      else
+        make olddefconfig 1>/dev/null 2>&1
+      fi
     else
-      make oldconfig
+      if [ "X${debug}" = "Xy" ]; then
+        make oldconfig V=1
+      else
+        make oldconfig
+      fi
     fi
   fi
 
   # Run savedefconfig to create the new defconfig file
 
-  make savedefconfig
-
-  # Show differences
-
-  $CMPCONFIG $DEFCONFIG defconfig
+  if [ "X${debug}" = "Xy" ]; then
+    make savedefconfig V=1
+  else
+    make savedefconfig 1>/dev/null 2>&1
+  fi
 
   # Save the refreshed configuration
 
   if [ "X${prompt}" == "Xy" ]; then
+
+    # Show differences
+
+    $CMPCONFIG $DEFCONFIG defconfig
+
     read -p "Save the new configuration (y/n)?" -n 1 -r
     echo
     if [[ $REPLY =~ ^[Yy]$ ]]

Reply via email to