a bit of front-end work, changing users almost done on login, "drunk-code" no more (id hope), continuous processes and keybinds still not done.
This commit is contained in:
@@ -1,12 +1,16 @@
|
||||
import type { KeyBind } from "$lib/stores/terminal/keybindRegistry";
|
||||
import { mount } from "svelte";
|
||||
import { type Bash, type Result } from "../bash";
|
||||
import type { CommandArgs, ICommand } from "../commandRegistry";
|
||||
import type { CommandArgs, CommandResultData, ICommand } from "../commandRegistry";
|
||||
import { ExitCode } from "../metadata";
|
||||
import Login from "../../../../modules/Login.svelte";
|
||||
import Loading from "../../../../modules/Loading.svelte";
|
||||
|
||||
export const cmd_async = async function(this: Bash, args: CommandArgs): Promise<Result> {
|
||||
export const cmd_process = function(this: Bash, args: CommandArgs): Result {
|
||||
let result: Result = { exitCode: ExitCode.ERROR, path: this.getCwd() };
|
||||
|
||||
const resultData: CommandResultData = { cmd: 'ls', data: null, args: args };
|
||||
|
||||
result.resultData = resultData;
|
||||
result.exitCode = ExitCode.SUCCESS;
|
||||
return result;
|
||||
}
|
||||
@@ -28,8 +32,8 @@ const keybinds: Map<KeyBind, () => any> = new Map([
|
||||
[test_keybind,test]
|
||||
]);
|
||||
|
||||
export const aSync: ICommand = {
|
||||
method: cmd_async,
|
||||
export const testProcess: ICommand = {
|
||||
method: cmd_process,
|
||||
keybinds: keybinds,
|
||||
flags: [] as string[],
|
||||
help: 'PATH TO HELP.md',
|
||||
|
||||
Reference in New Issue
Block a user