- No.
- 15
- Date
- Learning goal
- Terminal Start, lesson 5
- Level
- 1 of 3
Command of the day No. 15: tail -n
Purpose: Shows only the last lines of a file.
Syntax: tail -n number file
Example:
tail -n 2 logs/app.log
WARN slow response
ERROR payment failed Output from the simulator, as on a real Linux.
Options:
Try it in the terminal Share image
Fills in the command. Nothing runs until you press Enter.