aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--NEWS4
-rwxr-xr-xuserdrake6
3 files changed, 6 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 3c6060c..7d83f89 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
-VERSION = 2.16
+VERSION = 2.17
NAME = userdrake
BINNAME = userdrake
diff --git a/NEWS b/NEWS
index 9b0c06a..f57514e 100644
--- a/NEWS
+++ b/NEWS
@@ -1,4 +1,6 @@
-- add patch to notify of existing home directory (mga#21333)
+Version 2.17 - 7 March 2018
+
+- Notify user when home directory name already exists (mga#21333)
Version 2.16 - 5 June 2017
diff --git a/userdrake b/userdrake
index 9711db4..5bf5027 100755
--- a/userdrake
+++ b/userdrake
@@ -586,10 +586,8 @@ sub AddUser() {
$userEnt->ShadowMin(-1); $userEnt->ShadowMax(99999);
$userEnt->ShadowWarn(-1); $userEnt->ShadowInact(-1);
if ((-e $u{homedir}) && (-d $u{homedir})) {
- my $keephomedir = $in->ask_yesorno(N("Home directory already exists"), N("The requested home directory already exists. Would you like to preserve the existing home directory?"));
- if (!$keephomedir) {
- return;
- }
+ my $keephomedir = $in->ask_yesorno(N("Home directory already exists"), N("The requested home directory already exists. Would you like to preserve the existing directory?"));
+ return if !$keephomedir;
}
$ctx->UserAdd($userEnt, $is_system, $dontcreatehomedir, $homedir_perms);
$ctx->UserSetPass($userEnt, $u{passwd});