Skip to content

Commit

Permalink
Updating: minor cli update
Browse files Browse the repository at this point in the history
  • Loading branch information
gallettilance committed Apr 29, 2018
1 parent ce9b848 commit 41e7ef3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions lambda/lisp_parser.dats
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ in
end
end

(* ****** ****** *)

implement
parse_lisp(f) = let
Expand Down
6 changes: 4 additions & 2 deletions src/cli.dats
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,10 @@ implement
do_execute(args) =
case+ args of
| nil0() => (println!("must provide file path to execute"); ())
| cons0(f, args) => file_write_contract((f, val2str(interp(parse_lisp(f)))))

| cons0(f, args) =>
if file_exists(f)
then file_write_contract((f, val2str(interp(parse_lisp(f)))))
else (println!("Invalid file path"); ())

implement
do_code(args) = let
Expand Down

0 comments on commit 41e7ef3

Please sign in to comment.