From owner-svn-src-user@FreeBSD.ORG Tue Dec 29 21:41:55 2009 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B68E81065694; Tue, 29 Dec 2009 21:41:55 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 891BC8FC12; Tue, 29 Dec 2009 21:41:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id nBTLftBa037044; Tue, 29 Dec 2009 21:41:55 GMT (envelope-from dougb@svn.freebsd.org) Received: (from dougb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id nBTLftu3037042; Tue, 29 Dec 2009 21:41:55 GMT (envelope-from dougb@svn.freebsd.org) Message-Id: <200912292141.nBTLftu3037042@svn.freebsd.org> From: Doug Barton Date: Tue, 29 Dec 2009 21:41:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r201221 - user/dougb/portmaster X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Dec 2009 21:41:55 -0000 Author: dougb Date: Tue Dec 29 21:41:55 2009 New Revision: 201221 URL: http://svn.freebsd.org/changeset/base/201221 Log: For the printing of status information to the terminal title bar: 1. Collect the information in update_port(). This is both simpler and more thorough. 2. Make the counts global so that per parent port they will count all of the dependencies all the way down the tree. Modified: user/dougb/portmaster/portmaster Modified: user/dougb/portmaster/portmaster ============================================================================== --- user/dougb/portmaster/portmaster Tue Dec 29 21:41:51 2009 (r201220) +++ user/dougb/portmaster/portmaster Tue Dec 29 21:41:55 2009 (r201221) @@ -208,6 +208,8 @@ safe_exit () { # Save state for the parent process to read back in echo "CUR_DEPS='$CUR_DEPS'" >> $IPC_SAVE + echo "num_of_deps='$num_of_deps'" >> $IPC_SAVE + echo "dep_of_deps='$dep_of_deps'" >> $IPC_SAVE if [ -z "$CONFIG_ONLY" ]; then echo "DISPLAY_LIST='$DISPLAY_LIST'" >> $IPC_SAVE echo "INSTALLED_LIST='$INSTALLED_LIST'" >> $IPC_SAVE @@ -1093,8 +1095,6 @@ check_for_updates () { # No need for check_exclude here because it is already # run in the places that call check_for_updates(). check_interactive $iport $port_ver || return 0 - [ -n "$CONFIG_ONLY" ] && num_of_deps=$(( $num_of_deps + 1 )) - dep_of_deps=$(( $dep_of_deps + 1 )) update_port $iport $port_ver || return 1 return 0 } @@ -1655,6 +1655,10 @@ term_printf () { update_port () { local update_to +#[ -n "$CONFIG_ONLY" ] && { echo '' ; echo "Debug> num_deps $num_of_deps"; } + [ -n "$CONFIG_ONLY" ] && num_of_deps=$(( $num_of_deps + 1 )) + dep_of_deps=$(( $dep_of_deps + 1 )) + [ -n "$2" ] && update_to=" to $2" echo "===>>> Launching child to update ${1#$pd/}${update_to}" @@ -1847,9 +1851,6 @@ dependency_check () { check_for_updates $iport $origin || fail 'Update failed' else check_interactive $origin || continue - [ -n "$CONFIG_ONLY" ] && - num_of_deps=$(( $num_of_deps + 1 )) - dep_of_deps=$(( $dep_of_deps + 1 )) update_port $origin fi done