Gentoo Archives: gentoo-commits

From: Zac Medico <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:master commit in: bin/, cnf/
Date: Tue, 31 May 2011 21:49:52
Message-Id: 254e853c8a6aad06d4781b0eb0f5a1d2e1919754.zmedico@gentoo
1 commit: 254e853c8a6aad06d4781b0eb0f5a1d2e1919754
2 Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
3 AuthorDate: Tue May 31 21:48:55 2011 +0000
4 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
5 CommitDate: Tue May 31 21:48:55 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=254e853c
7
8 etc-update: add clear_term config for bug #142508
9
10 ---
11 bin/etc-update | 7 ++++---
12 cnf/etc-update.conf | 3 +++
13 2 files changed, 7 insertions(+), 3 deletions(-)
14
15 diff --git a/bin/etc-update b/bin/etc-update
16 index 2369f04..42518ad 100755
17 --- a/bin/etc-update
18 +++ b/bin/etc-update
19 @@ -149,7 +149,7 @@ sel_file() {
20 elif [ "${DELETE_ALL}" == "yes" ]; then
21 input=0
22 else
23 - clear
24 + [[ $CLEAR_TERM == yes ]] && clear
25 if [[ ${mode} == 0 ]] ; then
26 echo "The following is the list of files which need updating, each
27 configuration file is followed by a list of possible replacement files."
28 @@ -317,7 +317,7 @@ do_cfg() {
29 elif [[ "${DELETE_ALL}" == "yes" ]] && ! user_special "${ofile}"; then
30 my_input=2
31 else
32 - clear
33 + [[ $CLEAR_TERM == yes ]] && clear
34 if [ "${using_editor}" == 0 ]; then
35 (
36 echo "Showing differences between ${ofile} and ${file}"
37 @@ -421,7 +421,7 @@ Please select from the menu above (-1 to exit, losing this merge): "
38 return 255
39 ;;
40 2)
41 - clear
42 + [[ $CLEAR_TERM == yes ]] && clear
43 if [ "${using_editor}" == 0 ]; then
44 (
45 echo "Showing differences between ${ofile} and ${mfile}"
46 @@ -555,6 +555,7 @@ chown ${UID:-0}:${GID:-0} "${TMP}" || die "failed to set ownership on temp dir"
47 #CONFIG_PROTECT_MASK=$(/usr/lib/portage/bin/portageq envvar CONFIG_PROTECT_MASK)
48
49 # load etc-config's configuration
50 +CLEAR_TERM=$(get_config clear_term)
51 EU_AUTOMERGE=$(get_config eu_automerge)
52 rm_opts=$(get_config rm_opts)
53 mv_opts=$(get_config mv_opts)
54
55 diff --git a/cnf/etc-update.conf b/cnf/etc-update.conf
56 index 8157c3d..6f69dee 100644
57 --- a/cnf/etc-update.conf
58 +++ b/cnf/etc-update.conf
59 @@ -5,6 +5,9 @@
60 # note that you need dev-util/dialog installed
61 mode="0"
62
63 +# Whether to clear the term prior to each display
64 +clear_term="yes"
65 +
66 # Whether trivial/comment changes should be automerged
67 eu_automerge="yes"