[tyndur-devel] [PATCH] shell: start.lsh nur für interaktive Shells ausführen
Kevin Wolf ·
* shell: start.lsh ist in der Regel nur für interaktive Shells erwünscht; für Skripte ist es nicht nur unnötige Mühe, sondern dank dem 'cd file:/' in der Stardard-start.lsh ein echtes Problem, weill die Shell so mit relativen Pfaden aufgerufene Skripte nicht mehr findet. Signed-off-by: Kevin Wolf <kevin at tyndur.org> --- src/modules/c/shell/shell.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/modules/c/shell/shell.c b/src/modules/c/shell/shell.c index 72492f9..05b8e89 100644 --- a/src/modules/c/shell/shell.c +++ b/src/modules/c/shell/shell.c @@ -112,12 +112,12 @@ int main(int argc, char* argv[]) { tms_init(); - // Startskript ausfuehren - shell_script("file:/config/shell/start.lsh"); - // Keine Argumente wurden uebergeben, also wird die shell interaktiv // aufgerufen. if (argc == 1) { + // Startskript ausfuehren + shell_script("file:/config/shell/start.lsh"); + completion_init(); while (true) { shell_read_command(); -- 1.6.0.2