mirror of
https://github.com/Leonmmcoset/cleonos.git
synced 2026-04-27 05:34:00 +00:00
vim
This commit is contained in:
@@ -171,6 +171,7 @@ set(USER_SHELL_COMMAND_APPS
|
||||
diskinfo mkfsfat32 mount partctl
|
||||
shutdown restart exit clear ansi ansitest wavplay fastfetch memstat fsstat taskstat userstat
|
||||
shstat stats tty dmesg kbdstat mkdir touch write append cp mv rm kdbg bmpview qrcode browser
|
||||
vim
|
||||
)
|
||||
|
||||
foreach(SRC IN LISTS USER_APP_MAIN_SOURCES)
|
||||
|
||||
@@ -15,6 +15,7 @@ static int ush_cmd_help(void) {
|
||||
ush_writeln(" ansi / ansitest / color");
|
||||
ush_writeln(" bmpview <file.bmp> [cols]");
|
||||
ush_writeln(" qrcode [--ecc <L|M|Q|H>] <text>");
|
||||
ush_writeln(" vim [file] (vim-like editor: normal/insert/:w/:q/:wq)");
|
||||
ush_writeln(" wavplay <file.wav> [steps] [ticks] / wavplay --stop");
|
||||
ush_writeln(" fastfetch [--plain]");
|
||||
ush_writeln(" doom [wad_path] (framebuffer bootstrap renderer)");
|
||||
|
||||
@@ -2460,6 +2460,18 @@ static int ush_execute_single_command(ush_state *sh, const char *cmd, const char
|
||||
|
||||
(void)allow_external;
|
||||
|
||||
/*
|
||||
* Keep cd as a hard builtin so cwd updates never depend on
|
||||
* external command context files.
|
||||
*/
|
||||
if (ush_streq(cmd, "cd") != 0) {
|
||||
success = ush_cmd_cd(sh, arg);
|
||||
if (out_success != (int *)0) {
|
||||
*out_success = success;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (ush_try_exec_external(sh, cmd, arg, &success) != 0) {
|
||||
if (out_success != (int *)0) {
|
||||
*out_success = success;
|
||||
|
||||
1155
cleonos/c/apps/vim_main.c
Normal file
1155
cleonos/c/apps/vim_main.c
Normal file
File diff suppressed because it is too large
Load Diff
2
clks
2
clks
Submodule clks updated: 9097e6306b...3f70e14c55
Reference in New Issue
Block a user