home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!sun-barr!news2me.ebay.sun.com!cronkite.Central.Sun.COM!texsun!netdev!mic!lerami!amix!janc
- From: janc@amix.commodore.com (Jan Carlson)
- Newsgroups: comp.unix.amiga
- Subject: Re: Broken term? sag?
- Message-ID: <1992Sep5.164342.8224@amix.commodore.com>
- Date: 5 Sep 92 16:43:42 GMT
- References: <1992Aug28.192133.15423@kbsw1> <1992Aug31.222806.8131@ckctpa.UUCP> <179@gimlet.herndon.va.us>
- Distribution: usa
- Organization: Amiga UNIX Software Development
- Lines: 29
-
- In article <179@gimlet.herndon.va.us> logan@gimlet.herndon.va.us (Jim Logan) writes:
- >In article <1992Aug31.222806.8131@ckctpa.UUCP> crash%ckctpa@tct.com
- >(Frank "Crash" Edwards) writes:
- ># Errr, it should be pointed out that KSH does not "use" the editor.
- ># KSH has built-in emulations for EMACS and VI _only_. Don't expect to
- ># be able to use wordstunt^H^H^Har keystrokes, or any other arbitrary editor.
- >
- >Under certain conditions it does. In the "vi" command-mode you
- >can press 'v' and it will invoke the real thing. I think 'v' is
- >mapped to "fc -e".
- >
- > -Jim
-
- If a ksh user has FCEDIT exported with the path of any editor, he can
- type "fc abc" to pop the last command from his command history
- starting with "abc" into your editor, be it emacs, vi, mg, word*tar,
- ve, etc. When you do a save and exit from the editor, ksh will
- execute the edited version of the command.
-
- This is really handy for editing for and while loops, etc.
-
- Try this:
- FCEDIT=mg export FCEDIT
- for f in a b c
- do
- echo $f
- done
- ls
- fc for
-