Basic CommandsLesson 9Free preview
Bash Concatenate (cat)
This lesson is part of Bash · All levels
Summary
The paint command displays the contents of the file to the screen and can combine several files into one. It is also often used to create new files from keyboard inputs using the redirect operator. The -n option numbers each line that is displayed.
Key points
- File paint displays file content to stdout
- Paint file1 file2 combines content in sequence
- n is a line number
- Paint > file reading from keyboard to Ctrl+D
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.