Opening a file with vi
- vi
Editing a file after you have opened it
- Press the Insert key "Ins"
- Move to where you want to edit and start typing/make your edits
Saving your changes and exiting the file
- Press the escape key "esc"
- Press Shift and : together to open a vi command prompt
- Type in wq <-- stands for write and quit
Quitting out of a file without saving
- Press the escape key "esc"
- Press Shift and : together to open a vi command prompt
- Type in q! <-- stands for quit, I mean it because vi is dumb and must be ordered around