CLI: Show existing alias in error message
This commit is contained in:
parent
1bdae93ffd
commit
7d20da9a7b
@ -225,9 +225,13 @@ module Alias = functor (Entity : Entity) -> struct
|
|||||||
iter_s
|
iter_s
|
||||||
(fun (n, _v) ->
|
(fun (n, _v) ->
|
||||||
if n = s then
|
if n = s then
|
||||||
|
Entity.to_source cctxt _v >>=? fun value ->
|
||||||
failwith
|
failwith
|
||||||
"the %s alias %s already exists, use -force true to update"
|
"@[<v 2>The %s alias %s already exists.@,\
|
||||||
|
The current value is %s.@,\
|
||||||
|
Use -force true to update@]"
|
||||||
Entity.name n
|
Entity.name n
|
||||||
|
value
|
||||||
else
|
else
|
||||||
return ())
|
return ())
|
||||||
list
|
list
|
||||||
|
Loading…
Reference in New Issue
Block a user