My prefered text editor is nano/pico but some distros use vi for editing.
Here are some quick commands to remember when editing in vi.
To access vi you would type the following:
vi yourfile.txt
To quit the program hit Esc then SHIFT :
This will give you a prompt to type the following to quit(and not save)
q!
If youwant to quit and save what you have done type the following:
!wq