editor: now has [ ] to move to start, end of file

FossilOrigin-Name: 8bb96123f16e8a104abdc8104a72f4c1caf49c9e81f50fc8d9c0089b6d518eda
This commit is contained in:
crc 2017-11-15 01:11:34 +00:00
parent 119f1c6e20
commit fd7f121f04
2 changed files with 11 additions and 2 deletions

View file

@ -18,7 +18,7 @@ adapt to various uses.
For FreeBSD, macOS, Linux:
make
./build
Binaries will be found in the `bin` directory. The ones of interest
are:
@ -44,4 +44,3 @@ working directory to operate.
Wrapping a shell script, some RETRO code, and using the `rre` interface,
this is a slightly nicer alternative to the basic `repl` for interactive
use.

View file

@ -238,6 +238,14 @@ One more command: a word to jump to a particular line in the file.
gets s:to-number !CurrentLine ;
~~~
~~~
:goto-start (-)
#0 !CurrentLine ;
:goto-end (-)
@LineCount !CurrentLine ;
~~~
And now tie everything together. There's a key handler and a top level loop.
~~~
@ -268,6 +276,8 @@ And now tie everything together. There's a key handler and a top level loop.
$v [ paste-line ] case
$< [ dedent-line ] case
$> [ indent-line ] case
$[ [ goto-start ] case
$] [ goto-end ] case
$j [ &CurrentLine v:inc constrain ] case
$k [ &CurrentLine v:dec constrain ] case
$g [ goto constrain ] case