aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2009-04-28 11:34:56 +0000
committerUlrich Müller <ulm@gentoo.org>2009-04-28 11:34:56 +0000
commit1f38f95bcdad4f210136b160364598f883dfdc6f (patch)
tree5c097ffd96726e0de5dc437d301e40a3757b3f53
parentAdd news-tng module. (diff)
downloadeselect-1f38f95bcdad4f210136b160364598f883dfdc6f.tar.gz
eselect-1f38f95bcdad4f210136b160364598f883dfdc6f.tar.bz2
eselect-1f38f95bcdad4f210136b160364598f883dfdc6f.zip
Highlight selected target in mailer module, bug 220473.
svn path=/trunk/; revision=516
-rw-r--r--ChangeLog3
-rw-r--r--NEWS1
-rw-r--r--modules/mailer.eselect19
3 files changed, 14 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index 3557c1a..e4d930e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2009-04-28 Ulrich Mueller <ulm@gentoo.org>
+ * modules/mailer.eselect (do_list): Highlight selected target,
+ patch by Karl Hakimian <t4y68ds02@sneakemail.com> in 220473.
+
* configure.ac: Fix test for greadlink.
* configure.ac: Add --with-pm option for configuring the preferred
diff --git a/NEWS b/NEWS
index 38bb0c5..7c6ab1c 100644
--- a/NEWS
+++ b/NEWS
@@ -6,6 +6,7 @@ trunk:
- Fixed bug #155814: Clear aliases and shell functions.
- Fixed bug #156866: Handle missing scripts in rc module.
- Fixed bug #180966: Make rc module work with OpenRC.
+ - Fixed bug #220473: Highlight selected target in mailer module.
- Various improvements in opengl module.
New features:
diff --git a/modules/mailer.eselect b/modules/mailer.eselect
index 91ebcc6..d460a45 100644
--- a/modules/mailer.eselect
+++ b/modules/mailer.eselect
@@ -1,4 +1,4 @@
-# Copyright 1999-2005 Gentoo Foundation
+# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
@@ -83,14 +83,15 @@ do_list() {
for (( i = 0 ; i < ${#targets[@]} ; i = i + 1 )) ; do
# any more elegant way to do this?
local profile
- profile="$(canonicalise ${ROOT}/etc/mail/mailer.conf )"
- [[ ${targets[${i}]} == ${profile%.mailer} ]] && \
- targets[${i}]="${targets[${i}]} $(highlight '*' )"
- done
- write_numbered_list "${targets[@]}"
- else
- write_kv_list_entry "(none found)" ""
- fi
+ profile=$(basename \
+ "$(canonicalise "${ROOT}/etc/mail/mailer.conf")")
+ [[ ${targets[i]} = ${profile%.mailer} ]] \
+ && targets[i]="${targets[i]} $(highlight '*')"
+ done
+ write_numbered_list "${targets[@]}"
+ else
+ write_kv_list_entry "(none found)" ""
+ fi
}
### set action ###