From 6e71dd3f1d6f2291c6859b9d5d88b179e3e0ad36 Mon Sep 17 00:00:00 2001 From: "Sunrim KIM (keen)" <3han5chou7@gmail.com> Date: Mon, 1 Sep 2014 22:51:04 +0900 Subject: [PATCH] add -l option --- contrib/30.main/main.scm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/contrib/30.main/main.scm b/contrib/30.main/main.scm index fb075749..92dba342 100644 --- a/contrib/30.main/main.scm +++ b/contrib/30.main/main.scm @@ -14,6 +14,7 @@ (display "\n") (display "Options:\n") (display " -e [program] run one liner script\n") + (display " -l [file] load the file then enter repl\n") (display " -h or --help show this help\n")) (define (getopt) @@ -26,6 +27,8 @@ (exit 1)) ((-e) (values 'line (cadr args))) + ((-l) + (values 'load (cadr args))) (else (values 'file (car args))))))) @@ -45,6 +48,7 @@ (lambda (type dat) (case type ((repl) (repl)) + ((load) (load dat) (repl)) ((line) (exec-line dat)) ((file) (exec-file dat))))))