Commit ff16a3d 1 parent 5aad207 commit ff16a3d Copy full SHA for ff16a3d
File tree 1 file changed +6
-3
lines changed
1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ let prompt ?default ?style ~options message =
41
41
()
42
42
| n ->
43
43
Ansi. move_bol () ;
44
- Ansi. move_cursor 0 (- 1 * (n - 1 ) );
44
+ Ansi. move_cursor 0 (- 1 * n );
45
45
Ansi. erase Ansi. Below ;
46
46
flush stdout
47
47
in
@@ -50,8 +50,8 @@ let prompt ?default ?style ~options message =
50
50
let select i =
51
51
input := Some i;
52
52
reset () ;
53
- print_input () ;
54
- print_options ()
53
+ print_options () ;
54
+ print_input ()
55
55
in
56
56
print_prompt ?style message;
57
57
print_string " \n " ;
@@ -63,6 +63,9 @@ let prompt ?default ?style ~options message =
63
63
| 10 , Some input ->
64
64
(* Enter *)
65
65
reset () ;
66
+ Ansi. move_cursor 0 (- 1 );
67
+ Ansi. erase Ansi. Eol ;
68
+ print_prompt ?style message;
66
69
let input = List. nth options input in
67
70
print_string input;
68
71
print_string " \n " ;
You can’t perform that action at this time.
0 commit comments