What do i do after i get here?

What should I do if I vi via ssh and get this weird message?

  • If I press enter enough times, it will finally clear itself of this error message. But it takes like 30 seconds for the screen to entirely clear itself. If I access the computer non-remotely and vi a file, it's all fine. E20: Mark not set line  191: E492: Not an editor command:   1. Press  <ESC>  to make sure you are in Normal mode. line  193: E492: Not an editor command:   2. Move the cursor to the line below marked --->. line  195: E492: Not an editor command:   3. Move the cursor to the beginning of a word that needs to be deleted. line  197: E492: Not an editor command:   4. Type   dw^I to make the word disappear. line  199: E492: Not an editor command:   NOTE: The letter  d  will appear on the last line of the screen as you type line  200: E492: Not an editor command: ^Iit.  Vim is waiting for you to type  w .  If you see another character line  201: E492: Not an editor command: ^Ithan  d  you typed something wrong; press  <ESC>  and start over. line  203: E16: Invalid range: ---> There are a some words fun that don't belong paper in this sentence. line  205: E492: Not an editor command:   5. Repeat steps 3 and 4 until the sentence is correct and go to Lesson 2.2. line  208: E33: No previous substitute regular expression line  209: E492: Not an editor command: ^I^I      Lesson 2.2: MORE DELETION COMMANDS line  212: E20: Mark not set line  214: E492: Not an editor command:   1. Press  <ESC>  to make sure you are in Normal mode. line  216: E492: Not an editor command:   2. Move the cursor to the line below marked --->. line  218: E492: Not an editor command:   3. Move the cursor to the end of the correct line (AFTER the first . ). line  220: E492: Not an editor command:   4. Type    d$    to delete to the end of the line. line  222: E16: Invalid range: ---> Somebody typed the end of this line twice. end of this line twice. line  225: E492: Not an editor command:   5. Move on to Lesson 2.3 to understand what is happening. line  231: E33: No previous substitute regular expression line  232: E492: Not an editor command: ^I^I     Lesson 2.3: ON OPERATORS AND MOTIONS line  235: E492: Not an editor command:   Many commands that change text are made from an operator and a motion. line  236: E492: Not an editor command:   The format for a delete command with the  d  delete operator is as follows: line  238: E488: Trailing characters:   ^Id   motion line  240: E492: Not an editor command:   Where: line  241: E488: Trailing characters:     d      - is the delete operator. line  242: E492: Not an editor command:     motion - is what the operator will operate on (listed below). line  244: E492: Not an editor command:   A short list of motions: line  245: E172: Only one file name allowed:     w - until the start of the next word, EXCLUDING its first character. line  246: E172: Only one file name allowed:     e - to the end of the current word, INCLUDING the last character. line  247: E481: No range allowed:     $ - to the end of the line, INCLUDING the last character. line  249: E492: Not an editor command:   Thus typing  de  will delete from the cursor to the end of the word. line  251: E492: Not an editor command: NOTE:  Pressing just the motion while in Normal mode without an operator will line  252: E14: Invalid address line  254: E33: No previous substitute regular expression line  255: E492: Not an editor command: ^I^I     Lesson 2.4: USING A COUNT FOR A MOTION line  258: E20: Mark not set line  260: E492: Not an editor command:   1. Move the cursor to the start of the line marked ---> below. line  262: E492: Not an editor command:   2. Type  2w  to move the cursor two words forward. line  264: E492: Not an editor command:   3. Type  3e  to move the cursor to the end of the third word forward. line  266: E492: Not an editor command:   4. Type  0  (zero) to move to the start of the line. line  268: E492: Not an editor command:   5. Repeat steps 2 and 3 with different numbers. line  270: E16: Invalid range: ---> This is just a line with words you can move around in. line  272: E492: Not an editor command:   6. Move on to Lesson 2.5. line  277: E33: No previous substitute regular expression line  278: E492: Not an editor command: ^I^I     Lesson 2.5: USING A COUNT TO DELETE MORE line  281: E20: Mark not set line  283: E492: Not an editor command:   In the combination of the delete operator and a motion mentioned above you line  284: E488: Trailing characters:   insert a count before the motion to delete more: line  285: E488: Trailing characters: ^I d   number   motion line  287: E492: Not an editor command:   1. Move the cursor to the first UPPER CASE word in the line marked --->. line  289: E492: Not an editor command:   2. Type  d2w  to delete the two UPPER CASE words line  291: E492: Not an editor command:   3. Repeat steps 1 and 2 with a different count to delete the consecutive line  292: E492: Not an editor command:      UPPER CASE words with one command line  294: E16: Invalid range: --->  this ABC DE line FGHI JK LMN OP of words is Q RS TUV cleaned up. line  300: E33: No previous substitute regular expression line  301: E492: Not an editor command: ^I^I^I Lesson 2.6: OPERATING ON LINES line  304: E20: Mark not set line  306: E492: Not an editor command:   Due to the frequency of whole line deletion, the designers of Vi decided line  307: E492: Not an editor command:   it would be easier to simply type two d's to delete a line. line  309: E492: Not an editor command:   1. Move the cursor to the second line in the phrase below. line  310: E492: Not an editor command:   2. Type  dd  to delete the line. line  311: E492: Not an editor command:   3. Now move to the fourth line. line  312: E492: Not an editor command:   4. Type   2dd   to delete two lines. line  314: E16: Invalid range: --->  1)  Roses are red, line  315: E16: Invalid range: --->  2)  Mud is fun, line  316: E16: Invalid range: --->  3)  Violets are blue, line  317: E16: Invalid range: --->  4)  I have a car, line  318: E16: Invalid range: --->  5)  Clocks tell time, line  319: E16: Invalid range: --->  6)  Sugar is sweet line  320: E16: Invalid range: --->  7)  And so are you. line  323: E33: No previous substitute regular expression line  324: E492: Not an editor command: ^I^I^I Lesson 2.7: THE UNDO COMMAND line  327: E20: Mark not set line  329: E492: Not an editor command:   1. Move the cursor to the line below marked ---> and place it on the"PlotVariances.m" "PlotVariances.m" [dos] 23L, 711C line  331: E492: Not an editor command:   2. Type  x  to delete the first unwanted character. line  332: E492: Not an editor command:   3. Now type  u  to undo the last command executed. line  333: E492: Not an editor command:   4. This time fix all the errors on the line using the  x  command. line  334: E492: Not an editor command:   5. Now type a capital  U  to return the line to its original state. line  335: E492: Not an editor command:   6. Now type  u  a few times to undo the  U  and preceding commands. line  336: E492: Not an editor command:   7. Now type CTRL-R (keeping CTRL key pressed while hitting R) a few times line  337: E488: Trailing characters:      to redo the commands (undo the undo's). line  339: E16: Invalid range: ---> Fiix the errors oon thhis line and reeplace them witth undo. line  341: E492: Not an editor command:   8. These are very useful commands.  Now move on to the Lesson 2 Summary. line  346: E33: No previous substitute regular expression line  347: E492: Not an editor command: ^I^I^I       Lesson 2 SUMMARY line  350: E492: Not an editor command:   1. To delete from the cursor up to the next word type:    dw line  351: E492: Not an editor command:   2. To delete from the cursor to the end of a line type:    d$ line  352: E492: Not an editor command:   3. To delete a whole line type:    dd line  354: E492: Not an editor command:   4. To repeat a motion prepend it with a number:   2w line  355: E492: Not an editor command:   5. The format for a change command is: line  356: E492: Not an editor command:                operator   [number]   motion line  357: E492: Not an editor command:      where: line  358: E492: Not an editor command:        operator - is what to do, such as  d  for delete line  359: E492: Not an editor command:        [number] - is an optional count to repeat the motion line  360: E492: Not an editor command:        motion   - moves over the text to operate on, such as  w (word), line  361: E492: Not an editor command: ^I^I  $ (to the end of line), etc. line  363: E492: Not an editor command:   6. To move to the start of the line use a zero:  0 line  365: E492: Not an editor command:   7. To undo previous actions, type: ^I       u  (lowercase u) line  366: E492: Not an editor command:      To undo all the changes on a line, type:  U  (capital U) line  367: E492: Not an editor command:      To undo the undo's, type:^I^I       CTRL-R line  369: E33: No previous substitute regular expression line  370: E492: Not an editor command: ^I^I^I Lesson 3.1: THE PUT COMMAND line  373: E20: Mark not set line  375: E492: Not an editor command:   1. Move the cursor to the first ---> line below. line  377: E492: Not an editor command:   2. Type  dd  to delete the line and store it in a Vim register. line  379: E492: Not an editor command:   3. Move the cursor to the c) line, ABOVE where the deleted line should go. line  381: E492: Not an editor command:   4. Type   p   to put the line below the cursor. line  383: E492: Not an editor command:   5. Repeat steps 2 through 4 to put all the lines in correct order. line  385: E16: Invalid range: ---> d) Can you learn too? line  386: E16: Invalid range: ---> c) Intelligence is learned, line  387: E16: Invalid range: ---> a) Roses are red, line  391: E33: No previous substitute regular expression line  392: E492: Not an editor command: ^I^I       Lesson 3.2: THE REPLACE COMMAND line  395: E20: Mark not set line  397: E492: Not an editor command:   1. Move the cursor to the first line below marked --->. line  399: E492: Not an editor command:   2. Move the cursor so that it is on top of the first error. line  401: E492: Not an editor command:   3. Type   r^Iand then the character which should be there. line  403: E492: Not an editor command:   4. Repeat steps 2 and 3 until the first line is equal to the second one. line  405: E16: Invalid range: --->  Whan this lime was tuoed in, someone presswd some wrojg keys! line  406: E16: Invalid range: --->  When this line was typed in, someone pressed some wrong keys! line  408: E492: Not an editor command:   5. Now move on to Lesson 3.3. line  410: E492: Not an editor command: NOTE: Remember that you should be learning by doing, not memorization. line  414: E33: No previous substitute regular expression line  415: E492: Not an editor command: ^I^I^ILesson 3.3: THE CHANGE OPERATOR line  418: E20: Mark not set line  420: E492: Not an editor command:   1. Move the cursor to the first line below marked --->. line  422: E492: Not an editor command:   2. Place the cursor on the  u  in  lubw. line  424: E492: Not an editor command:   3. Type  ce  and the correct word (in this case, type  ine ). line  426: E492: Not an editor command:   4. Press <ESC> and move to the next character that needs to be changed. line  428: E492: Not an editor command:   5. Repeat steps 3 and 4 until the first sentence is the same as the second. line  430: E16: Invalid range: ---> This lubw has a few wptfd that mrrf changing usf the change operator. line  431: E16: Invalid range: ---> This line has a few words that need changing using the change operator. line  433: E492: Not an editor command: Notice that  ce  deletes the word and places you in Insert mode. line  437: E33: No previous substitute regular expression line  438: E492: Not an editor command: ^I^I       Lesson 3.4: MORE CHANGES USING c line  441: E20: Mark not set line  443: E492: Not an editor command:   1. The change operator works in the same way as delete.  The format is: line  445: E488: Trailing characters:          c    [number]   motion line  447: E492: Not an editor command:   2. The motions are the same, such as   w (word) and  $ (end of line). line  449: E492: Not an editor command:   3. Move to the first line below marked --->. line  451: E492: Not an editor command:   4. Move the cursor to the first error. line  453: E492: Not an editor command:   5. Type  c$  and type the rest of the line like the second and press <ESC>. line  455: E16: Invalid range: ---> The end of this line needs some help to make it like the second. line  456: E16: Invalid range: ---> The end of this line needs to be corrected using the  c$  command. line  458: E492: Not an editor command: NOTE:  You can use the Backspace key to correct mistakes while typing. line  460: E33: No previous substitute regular expression line  461: E492: Not an editor command: ^I^I^I       Lesson 3 SUMMARY line  464: E492: Not an editor command:   1. To put back text that has just been deleted, type   p .  This puts the line  465: E492: Not an editor command:      deleted text AFTER the cursor (if a line was deleted it will go on the line  466: E492: Not an editor command:      line below the cursor). line  468: E492: Not an editor command:   2. To replace the character under the cursor, type   r   and then the line  469: E492: Not an editor command:      character you want to have there. line  471: E492: Not an editor command:   3. The change operator allows you to change from the cursor to where the line  472: E492: Not an editor command:      motion takes you.  eg. Type  ce  to change from the cursor to the end of line  473: E492: Not an editor command:      the word,  c$  to change to the end of a line. line  475: E492: Not an editor command:   4. The format for change is: line  477: E488: Trailing characters: ^I c   [number]   motion line  479: E492: Not an editor command: Now go on to the next lesson. line  483: E33: No previous substitute regular expression line  484: E492: Not an editor command: ^I^I  Lesson 4.1: CURSOR LOCATION AND FILE STATUS line  486: E20: Mark not set line  487: E492: Not an editor command:      Type  G  to move to a line in the file. ** line  489: E492: Not an editor command:   NOTE: Read this entire lesson before executing any of the steps!! line  491: E492: Not an editor command:   1. Hold down the Ctrl key and press  g .  We call this CTRL-G. line  492: E492: Not an editor command:      A message will appear at the bottom of the page with the filename and the line  493: E492: Not an editor command:      position in the file.  Remember the line number for Step 3. line  495: E492: Not an editor command: NOTE:  You may see the cursor position in the lower right corner of the screen line  496: E492: Not an editor command:        This happens when the 'ruler' option is set (see  :help 'ruler'  ) line  498: E492: Not an editor command:   2. Press  G  to move you to the bottom of the file. line  499: E492: Not an editor command:      Type  gg  to move you to the start of the file. line  501: E492: Not an editor command:   3. Type the number of the line you were on and then  G .  This will line  502: E133: :return not inside a function line  504: E492: Not an editor command:   4. If you feel confident to do this, execute steps 1 through 3. line  506: E33: No previous substitute regular expression line  507: E492: Not an editor command: ^I^I^ILesson 4.2: THE SEARCH COMMAND line  510: E20: Mark not set line  512: E492: Not an editor command:   1. In Normal mode type the  /  character.  Notice that it and the cursor line  513: E492: Not an editor command:      appear at the bottom of the screen as with the  :^Icommand. line  515: E492: Not an editor command:   2. Now type 'errroor' <ENTER>.  This is the word you want to search for. line  517: E492: Not an editor command:   3. To search for the same phrase again, simply type  n . line  518: E492: Not an editor command:      To search for the same phrase in the opposite direction, type  N . line  520: E492: Not an editor command:   4. To search for a phrase in the backward direction, use  ?  instead of  / . line  522: E492: Not an editor command:   5. To go back to where you came from press  CTRL-O  (Keep Ctrl down while line  523: E492: Not an editor command:      pressing the letter o).  Repeat to go back further.  CTRL-I goes forward. line  525: E16: Invalid range: --->  "errroor" is not the way to spell error;  errroor is an error. line  526: E492: Not an editor command: NOTE: When the search reaches the end of the file it will continue at the line  527: E488: Trailing characters:       start, unless the 'wrapscan' option has been reset. line  529: E33: No previous substitute regular expression line  530: E492: Not an editor command: ^I^I   Lesson 4.3: MATCHING PARENTHESES SEARCH line  533: E20: Mark not set line  535: E492: Not an editor command:   1. Place the cursor on any (, [, or { in the line below marked --->. line  537: E492: Not an editor command:   2. Now type the  %  character. line  539: E492: Not an editor command:   3. The cursor will move to the matching parenthesis or bracket. line  541: E492: Not an editor command:   4. Type  %  to move the cursor to the other matching bracket. line  543: E492: Not an editor command:   5. Move the cursor to another (,),[,],{ or } and see what  %  does. line  545: E16: Invalid range: ---> This ( is a test line with ('s, ['s ] and {'s } in it. )) line  548: E492: Not an editor command: NOTE: This is very useful in debugging a program with unmatched parentheses! line  552: E33: No previous substitute regular expression line  553: E492: Not an editor command: ^I^I      Lesson 4.4: THE SUBSTITUTE COMMAND line  556: E20: Mark not set line  558: E492: Not an editor command:   1. Move the cursor to the line below marked --->. line  560: E492: Not an editor command:   2. Type  :s/thee/the <ENTER> .  Note that this command only changes the"PlotVariances.m" "PlotVariances.m" [dos] 23L, 711C line  563: E492: Not an editor command:   3. Now type  :s/thee/the/g .  Adding the  g  flag means to substitute line  564: E492: Not an editor command:      globally in the line, change all occurrences of "thee" in the line. line  566: E16: Invalid range: ---> thee best time to see thee flowers is in thee spring. line  568: E492: Not an editor command:   4. To change every occurrence of a character string between two lines, line  569: E492: Not an editor command:      type   :#,#s/old/new/g    where #,# are the line numbers of the range line  570: E492: Not an editor command:                                of lines where the substitution is to be done. line  571: E492: Not an editor command:      Type   :%s/old/new/g      to change every occurrence in the whole file. line  572: E492: Not an editor command:      Type   :%s/old/new/gc     to find every occurrence in the whole file, line  573: E492: Not an editor command:      ^I^I^I       with a prompt whether to substitute or not. line  575: E33: No previous substitute regular expression line  576: E492: Not an editor command: ^I^I^I       Lesson 4 SUMMARY line  579: E492: Not an editor command:   1. CTRL-G  displays your location in the file and the file status. line  580: E492: Not an editor command:              G  moves to the end of the file. line  581: E488: Trailing characters:      number  G  moves to that line number. line  582: E492: Not an editor command:             gg  moves to the first line. line  584: E492: Not an editor command:   2. Typing  /^Ifollowed by a phrase searches FORWARD for the phrase. line  585: E492: Not an editor command:      Typing  ?^Ifollowed by a phrase searches BACKWARD for the phrase. line  586: E492: Not an editor command:      After a search type  n  to find the next occurrence in the same direction line  587: E492: Not an editor command:      or  N  to search in the opposite direction. line  588: E492: Not an editor command:      CTRL-O takes you back to older positions, CTRL-I to newer positions. line  590: E492: Not an editor command:   3. Typing  %^Iwhile the cursor is on a (,),[,],{, or } goes to its match. line  592: E492: Not an editor command:   4. To substitute new for the first old in a line type    :s/old/new line  593: E492: Not an editor command:      To substitute new for all 'old's on a line type^I   :s/old/new/g line  594: E492: Not an editor command:      To substitute phrases between two line #'s type^I   :#,#s/old/new/g line  595: E492: Not an editor command:      To substitute all occurrences in the file type^I   :%s/old/new/g line  596: E492: Not an editor command:      To ask for confirmation each time add 'c'^I^I   :%s/old/new/gc line  598: E33: No previous substitute regular expression line  599: E492: Not an editor command: ^I^ILesson 5.1: HOW TO EXECUTE AN EXTERNAL COMMAND line  602: E20: Mark not set line  604: E492: Not an editor command:   1. Type the familiar command^I:  to set the cursor at the bottom of the line  605: E492: Not an editor command:      screen.  This allows you to enter a command-line command. line  607: E492: Not an editor command:   2. Now type the  !  (exclamation point) character.  This allows you to line  608: E121: Undefined variable: any E15: Invalid expression: any external shell command. line  610: E492: Not an editor command:   3. As an example type   ls   following the ! and then hit <ENTER>.  This line  611: E492: Not an editor command:      will show you a listing of your directory, just as if you were at the line  612: E488: Trailing characters:      shell prompt.  Or use  :!dir  if ls doesn't work. line  614: E492: Not an editor command: NOTE:  It is possible to execute any external command this way, also with line  615: E492: Not an editor command:        arguments. line  617: E492: Not an editor command: NOTE:  All  :  commands must be finished by hitting <ENTER> line  618: E492: Not an editor command:        From here on we will not always mention it. line  621: E33: No previous substitute regular expression line  622: E492: Not an editor command: ^I^I      Lesson 5.2: MORE ON WRITING FILES line  625: E20: Mark not set line  627: E492: Not an editor command:   1. Type  :!dir  or  :!ls  to get a listing of your directory. line  628: E492: Not an editor command:      You already know you must hit <ENTER> after this. line  630: E492: Not an editor command:   2. Choose a filename that does not exist yet, such as TEST. line  632: E492: Not an editor command:   3. Now type:^I :w TEST   (where TEST is the filename you chose.) line  634: E492: Not an editor command:   4. This saves the whole file (the Vim Tutor) under the name TEST. line  635: E492: Not an editor command:      To verify this, type    :!dir  or  :!ls   again to see your directory. line  637: E492: Not an editor command: NOTE: If you were to exit Vim and start it again with  vim TEST , the file line  638: E492: Not an editor command:       would be an exact copy of the tutor when you saved it. line  640: E492: Not an editor command:   5. Now remove the file by typing (MS-DOS):    :!del TEST line  641: E492: Not an editor command: ^I^I^I^Ior (Unix):^I:!rm TEST line  644: E33: No previous substitute regular expression line  645: E492: Not an editor command: ^I^I    Lesson 5.3: SELECTING TEXT TO WRITE line  648: E20: Mark not set line  650: E492: Not an editor command:   1. Move the cursor to this line. line  652: E492: Not an editor command:   2. Press  v  and move the cursor to the fifth item below.  Notice that the line  653: E492: Not an editor command:      text is highlighted. line  655: E492: Not an editor command:   3. Press the  :  character.  At the bottom of the screen  :'<,'> will appear. line  657: E492: Not an editor command:   4. Type  w TEST  , where TEST is a filename that does not exist yet.  Verify line  658: E492: Not an editor command:      that you see  :'<,'>w TEST  before you press Enter. line  660: E492: Not an editor command:   5. Vim will write the selected lines to the file TEST.  Use  :!dir  or  !ls line  661: E492: Not an editor command:      to see it.  Do not remove it yet!  We will use it in the next lesson. line  663: E492: Not an editor command: NOTE:  Pressing  v  starts Visual selection.  You can move the cursor around :!make the selection bigger or smaller.  Then you can use an operator | tee /tmp/vGLFFSt/0 make: *** No rule to make target `the'.  Stop. shell returned 2 Press ENTER or type command to continue

  • Answer:

    It looks like the terminal is not properly set. You can give a hint to your terminal, or you can use a rawer form, like TERM=vt100. Also, sometimes calling 'reset' (which doesn't reboot your machine, but resets your terminal) after setting the TERM environment value will help you get a clean session with vim. It's an issue with vim, really, not with your SSH connection. It might be possible that you set your TERM to something fancier in the .bash_profile or something similar. Before running anything, it's worth having a look at the current value of TERM to see what's going on.

Dorin Lazăr at Quora Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.