click below
click below
Normal Size Small Size show me how
CIs301-Lab4
Linux Text Editors
| Term | Definition |
|---|---|
| vim | Command used to open this particular text editor and edit a new file; file name can be specified when you write the file. |
| vim | (vi IMproved) - A clone of Bill Jay's vi text editor for Unix. |
| vim File_name | Command used to open vim text editor and edit the file named: File_name. |
| EMACS | _____ is another Linux/Unix based text editor. |
| ESC :wq | Command used to save your file in vim before you exit (alternative way is: ESC zz). |
| ESC :wq newname | Vim command used to save a new file named: newname. |
| ESC :q! | Command used to exit vim without saving changes. |
| Command Mode | Mode in vim, where your keystrokes are interpreted as editing commands. |
| 2 Basic Modes of VIM | 1) Insert mode 2) Command mode |
| Insert Mode | To begin typing new text into the file, you must switch to ______ ____ by pressing i. |
| Insert Mode | vim mode in which anything you type (except some special keys) will appear on the screen and become part of your file buffer. |
| Command Mode | Vim mode in which your key strokes are interpreted as commands. |
| Command mode | After starting vim, you are automatically in _______ ____. |
| ESC | To go from using insert mode to command mode, type ___. |
| True | The most effective way of moving the cursor around in vim is by going to command mode by pressing ESC, and use vim's cursor-moving commands. |
| 4 Basic vim Cursor-Moving Commands | 1) J - move down one line 2) K - Move up one line 3) H - move left one character 4) L - move right one character |
| X | _ is just one of the many powerful vim deletion commands that are used to delete characters in command mode. |
| i | To insert text in command mode, move the cursor to the desired location, then type _. |
| yy; dd; p | To copy in vim, press ESC to enter command mode, move cursor to command you want to copy, press __ to make a copy of the line, or __ to cut it; to paste, move cursor to proper location and press _. |
| 8yy; 8dd | ___ before a line copies 8 lines of text in vim (to cut use ___). |
| /searchWord | To search while in vim, enter command mode, and type: ___________ and press enter. This highlights the first occurrence of your search criteria; type n to find the next occurrence. |
| Nano | A simple GNU terminal-based text editor; not as powerful as EMACS or vim; created as a free replacement for the non-free Pico editor. |
| nano filename | Command used to open an existing file named: filename in nano text editor. |
| True | nano -w .bashrc starts nano with line wrapping set to off. |
| Bottom | The ______ two lines in nano show the key combinations for common operations. |
| True | Limitations of nano include: you cannot use the mouse to cut or delete text, nor can you use the mouse to scroll through the file. |
| ALT+M | Use _____ key to toggle between the terminal's mouse services and nano's built-in mouse services. |
| True | While in nano, typing at the keyboard will insert text at the current cursor location. |
| CTRL+R | Open a file while in nano with the read file command, ______. |
| CTRL+T | In nano, use the ______ key combination to use nano's built-in file browser to navigate to the file you want to open. |
| CTRL+O | Key combination used to save and save as for specified file, in nano. |
| CTRL+X | In nano, close a file with the ______ key combination. |
| ALT-6; CTRL+K; CTRL+U | In nano, use the _____ key combination to copy text to the "cut buffer"; use the ______ key combination to delete text; use ______ key combination to paste text from the "cut buffer," into the file. |
| CTRL+X; y; n | To quit nano, use ______ key combination; type _ to save the file, or _ to exit without saving changes to the file. |
| ec2-user | Must be in ________ to add group to sudoers file. |
| visudo | Command used to open /etc/sudoers file in vi. |
| sudo usermod -G wheel Jimmy | Command used to add existing user Jimmy to the wheel group. |
| True | If you tyry to use sudo as yourself (in your user profile), you were told that the "user is not in the sudoers file" and "this incident will be reported." to fix this, type sudo visudo in ec2-user and edit sudoer file were appropriate. |