Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

You know the command line is ready for input when you see the command line prompt. It can be configured differently on different systems, but on our system it shows your account name, server name, current directory, then a dollar sign ($). Note the tilde character ( ~ ) signifies your Home directory.

Code Block
languagebash
titleMultiple command on a line
student01@gsafcomp01:~$

Like everything in Unix, the command line has similarities to a text file. And in Unix, all text file "lines" are terminated by a linefeed character (\n, also called a newline).

...

Tip
titleBackslash for line continuation

When using the backslash ( \ ) to continue a text line, be careful not to enter any text after the backslash – just press Enter after it. Why?

The backslash ( \ ) metacharacter is used to escape the next character, which means to treat it as a literal even if it is a metacharacter.

As a line continuation indicator, the next character should be the linefeed from you pressing Enter. So instead of treating Enter as a metacharacter (ending the line and starting a new one) it treats it as a literal and inserts a literallinefeed character ( \n ) in the text, then performs performing a linefeed operation and giving you the > prompt on a new line.

...