Commit Graph

51 Commits

Author SHA1 Message Date
Qi Xiao
be1df5ffc3 add a -debuglog flag 2016-02-05 22:12:05 +01:00
Qi Xiao
51df7b1263 main.go: reorder to top-down 2016-02-05 20:16:22 +01:00
Qi Xiao
67c2687a07 sys.DumpStack now returns a string 2016-02-03 02:50:15 +01:00
Qi Xiao
2823ffb540 more elaborate signal handling 2016-02-03 02:19:09 +01:00
Qi Xiao
c1b7701a68 combine Error and error into an error in eval functions 2016-01-31 01:40:49 +01:00
Qi Xiao
82e027e435 Exitus -> Error 2016-01-30 17:11:43 +01:00
Qi Xiao
a3c2bf37d8 eval: NewEvaler no longer takes dataDir 2016-01-29 14:01:51 +01:00
Qi Xiao
1a490de6fd sysutil -> osutil; add package doc 2016-01-29 03:04:31 +01:00
Qi Xiao
b0568168e8 exitus cleanup 2016-01-28 23:39:20 +01:00
Qi Xiao
0b19995a02 install a global panic handler that exec's /bin/sh 2016-01-28 01:25:17 +01:00
Qi Xiao
7b4db8509b main: always catch signals 2016-01-28 00:22:54 +01:00
Qi Xiao
cca6d75c36 Store a pointer to eval.Evaler in edit.Editor 2016-01-25 22:14:12 +01:00
Qi Xiao
233a8f4b07 parse-ng -> parse 2016-01-24 18:15:21 +01:00
Qi Xiao
aa7ca8eea1 New eval. Currently broken. 2016-01-24 18:13:20 +01:00
Cheer Xiao
6dfa18bf4c Expose eval.HasFailure 2015-07-08 00:13:50 +02:00
Cheer Xiao
f68b0eb1f9 A chunk now stops execution as soon as a failure is encountered. 2015-07-08 00:12:24 +02:00
Cheer Xiao
876b7ac40c Move util/path.go into dedicated sysutil package 2015-02-26 16:50:20 +01:00
Cheer Xiao
f407b94d09 Use persistent history in the editor
This resolves issue #45.
2015-02-26 00:40:35 +01:00
Cheer Xiao
e82e67fd4e Move mutable states of Evaler into evalCtx.
This is work on #47.
2015-02-25 12:21:06 +01:00
Cheer Xiao
9495a6adfa Evaluator -> Evaler 2015-02-25 00:37:18 +01:00
Cheer Xiao
c19a982221 Remove dependency of the editor on the evaluator 2015-02-24 21:31:37 +01:00
Cheer Xiao
1d59566aaf Implement module file search mechanism for "use"
This resolves issue #44.
2015-02-23 18:36:46 +01:00
Cheer Xiao
2a40e1e13b Only catch signals when in the editor 2015-02-10 12:23:25 +01:00
Cheer Xiao
0b46817902 Very minor refactor 2015-02-10 12:22:01 +01:00
Cheer Xiao
948db2db97 Don't evaluate if parsing failed 2015-02-10 12:21:21 +01:00
Cheer Xiao
c23a4e2ece Source ~/.elvish/rc.elv on interact startup.
This resolves issue #42.
2015-02-09 14:01:13 +01:00
Cheer Xiao
fd2e26700a Move error-related utilities from util to errutil 2015-02-09 12:28:36 +01:00
Cheer Xiao
b20b0acf9d Make store.Store part of Evaluator 2015-01-26 16:43:32 +01:00
Cheer Xiao
82f07e1ab1 Cleanup main package 2015-01-22 23:23:29 +01:00
Cheer Xiao
7605eff82f Add a Source method to Evaluator. Simplify the main package. 2015-01-22 23:15:54 +01:00
Cheer Xiao
dd2a47152c Let channel output on terminal use Repr instead of String 2015-01-21 23:55:10 +01:00
Cheer Xiao
d7ca67f3fd Import store package in main.go
This is needed to ensure that dependencies of the store package are installed
with `go get` so that `go test ./store` can be run.
2015-01-21 20:56:52 +01:00
Cheer Xiao
1ad8fcaa1f **.go: xiaq/elvish -> elves/elvish 2014-10-29 20:50:10 +01:00
Cheer Xiao
47f22c64e8 Channel output in interactive mode is supported (again).
This is implemented by making ev.ports[1] a hybrid port. Channel outputs are
collected with a goroutine and written to stdout prepended by some fancy
Unicode symbols.

This resolves issue #23.
2014-09-21 00:32:09 +02:00
Cheer Xiao
9c1a6fb638 main.go: Don't assume Evaluator.Eval returns ContextualError 2014-07-30 17:02:42 +08:00
Cheer Xiao
8157620ba8 Support execution of script file.
Unfortunately the parser seems to be unable to go beyond the first line.
2014-05-25 17:55:53 +08:00
Cheer Xiao
a7bfa40302 edit.New -> .NewEditor 2014-03-20 13:16:20 +08:00
Cheer Xiao
af03fe9014 main: DON'T PANIC 2014-03-16 23:16:27 +08:00
Cheer Xiao
dfb8e16c2c Revert the accidental commenting of signal.Notify in main 2014-03-10 21:24:03 +08:00
Cheer Xiao
0624368bcc Use util.AsyncReader to build a new async edit.Reader
Now we can start really dealing with signals!
2014-03-10 21:22:54 +08:00
Cheer Xiao
b2f4e8f781 edit: ReadLine now accepts funcs as prompt and rprompt.
The prompt is now correctly updated when cding in navigation mode
2014-03-10 14:51:37 +08:00
Cheer Xiao
3365759b21 Print eval errors with fmt.Print, not fmt.Println 2014-03-06 16:42:03 +08:00
Cheer Xiao
4be72a848a Handle signals by ignoring them (for now) 2014-03-03 17:53:23 +08:00
Cheer Xiao
f5d6fdc6da Make eval.Env zero value useful by populating it on use 2014-02-10 21:35:15 +08:00
Cheer Xiao
42fcb8eb22 goimports 2014-02-10 11:33:53 +08:00
Cheer Xiao
9b4713e727 Make edit.Editor instance persistent 2014-02-08 21:21:01 +08:00
Cheer Xiao
e50b08466b Reword main package doc 2014-02-08 19:26:06 +08:00
Cheer Xiao
7d7814ef9b golint fixes 2014-01-31 19:18:10 +08:00
Cheer Xiao
3ce8ab1e6f Document main package 2014-01-30 22:09:04 +08:00
Cheer Xiao
c1711bbd0a Project rename: das -> elvish 2014-01-29 18:44:07 +08:00