Allow users to initialize project names that already exist.
This commit is contained in:
parent
51b3032118
commit
94224a7ba0
@ -241,11 +241,17 @@ initialize_check(P = #project{id = PackageID}) ->
|
||||
true ->
|
||||
Message =
|
||||
"~nDHOH!~n"
|
||||
"Sadly this package already exists.~n"
|
||||
"Two packages with the same name cannot exist in a single realm.~n"
|
||||
"Please pick another name.~n",
|
||||
"Sadly this package already exists in the selected realm.~n"
|
||||
"What do?~n",
|
||||
ok = io:format(Message),
|
||||
initialize(P#project{id = none});
|
||||
Options = [{"Pick another name.", 1},
|
||||
{"Continue anyway.", 2},
|
||||
{"Abort and do it later.", 3}],
|
||||
case zx_tty:select(Options) of
|
||||
1 -> initialize(P#project{id = none});
|
||||
2 -> zompify(P);
|
||||
3 -> ok
|
||||
end;
|
||||
maybe ->
|
||||
Message =
|
||||
"~n∑(。・Д・。)???~nHmmm...~n"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user