Unix vi command?

Discussion in 'Linux Discussion' started by BenL, May 5, 2008.

  1. BenL Guest

    What command do you type to read the output of the 'who'
    into the file 'test' in command mode?

    What initialization file is started each time you start editing seesion with vi?

    What command instructs vi to map the command # to append the
    output of the date utility after the current line?
  2. Search in google
  3. 1) !who > test

    2) File .exrc in your home directory, or the file pointed to by EXINIT environment variable if it's defined.

    3) :map # :r !date^M

    The ^M character is the Carriage Return character.
    It would have been typed into vi or the .exrc file as CTRL-V followed by CARRIAGE-RETURN.

Share This Page