How to create or edit a file in linux (using vi)
- At the command prompt enter
vi /path/filename
examples:
vi /root/.OneDesk
vi /etc/yum.repos.d/repo.onedesk.com_repo.repo
- Press i on your keyboard to switch to insert mode in the file
- Edit the file as required
- Press the Esc key to exit from input mode.
- Save the changes with the following command
:wq