diff options
author | Ian Stakenvicius <axs@gentoo.org> | 2012-06-22 19:18:24 +0000 |
---|---|---|
committer | Ian Stakenvicius <axs@gentoo.org> | 2012-06-22 19:18:24 +0000 |
commit | e24010079fe308ad2be2368fcf2954a3c5938fb0 (patch) | |
tree | 5980b0503ae58b924f144aebaf7e0742ce20e68f /eclass | |
parent | esethome: eerror and not die when home dir cannot be updated, due to for inst... (diff) | |
download | gentoo-2-e24010079fe308ad2be2368fcf2954a3c5938fb0.tar.gz gentoo-2-e24010079fe308ad2be2368fcf2954a3c5938fb0.tar.bz2 gentoo-2-e24010079fe308ad2be2368fcf2954a3c5938fb0.zip |
esethome: silently exit if home dir already up to date, improve messaging
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/ChangeLog | 5 | ||||
-rw-r--r-- | eclass/user.eclass | 9 |
2 files changed, 12 insertions, 2 deletions
diff --git a/eclass/ChangeLog b/eclass/ChangeLog index d095016f8f9a..8cb2b8061703 100644 --- a/eclass/ChangeLog +++ b/eclass/ChangeLog @@ -1,6 +1,9 @@ # ChangeLog for eclass directory # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.326 2012/06/22 18:57:33 axs Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.327 2012/06/22 19:18:24 axs Exp $ + + 22 Jun 2012; Ian Stakenvicius <axs@gentoo.org> user.eclass: + esethome: silently exit if home dir already up to date, improve messaging 22 Jun 2012; Ian Stakenvicius <axs@gentoo.org> user.eclass: esethome: eerror and not die when home dir cannot be updated, due to for diff --git a/eclass/user.eclass b/eclass/user.eclass index 9f9f684d66b7..fa7e747d473e 100644 --- a/eclass/user.eclass +++ b/eclass/user.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/user.eclass,v 1.21 2012/06/22 18:57:33 axs Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/user.eclass,v 1.22 2012/06/22 19:18:24 axs Exp $ # @ECLASS: user.eclass # @MAINTAINER: @@ -422,6 +422,13 @@ esethome() { if [[ ${ehome} == "-1" ]] ; then ehome="/dev/null" fi + + # exit with no message if home dir is up to date + if [[ $(egethome "${euser}") == ${ehome} ]]; then + return 0 + fi + + einfo "Updating home for user '${euser}' ..." einfo " - Home: ${ehome}" # ensure home directory exists, otherwise update will fail |