While gTxtEdit is a pretty nice GUI text editor for jailbreakers, I really don't like that you have to retype the entire file path when saving. Plus, I need something I can use from the command line for doing minor edits to config files without having to leave the shell.
I was very happy then to find that both vi and nano are available for download through Cydia. FYI, when you call vi from the command line, you will need to use vim, not vi.
I also tried installing mg, which is based on emacs, and though it seemed okay for new files, I got bus errors when opening existing files. Google showed others experiencing this as well. Never mind though, 'cause having vi and nano on my iPod is out of this free world!