history works like its supposed to
This commit is contained in:
parent
d8b2c061df
commit
0bfaf89c9b
|
@ -25,14 +25,14 @@ function pr_char(char) {
|
||||||
function exec_cmd() {
|
function exec_cmd() {
|
||||||
let c = cmd;
|
let c = cmd;
|
||||||
reset_cmd();
|
reset_cmd();
|
||||||
history.push(c);
|
history.unshift(c);
|
||||||
terminal.writeln('zsh: command not found: ' + c);
|
terminal.writeln('zsh: command not found: ' + c);
|
||||||
print_prompt();
|
print_prompt();
|
||||||
|
history_pos = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
function print_prompt() {
|
function print_prompt() {
|
||||||
terminal.write(prompt);
|
terminal.write(prompt);
|
||||||
history_pos = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function reprint_prompt() {
|
function reprint_prompt() {
|
||||||
|
|
Loading…
Reference in New Issue