mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-03-15 13:00:03 +00:00
Update cheatsheets
This commit is contained in:
12
tldr/tail
12
tldr/tail
@@ -11,24 +11,24 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Show last 'count' lines in file:
|
||||
|
||||
`tail --lines {{count}} {{path/to/file}}`
|
||||
`tail {{[-n|--lines]}} {{count}} {{path/to/file}}`
|
||||
|
||||
- Print a file from a specific line number:
|
||||
|
||||
`tail --lines +{{count}} {{path/to/file}}`
|
||||
`tail {{[-n|--lines]}} +{{count}} {{path/to/file}}`
|
||||
|
||||
- Print a specific count of bytes from the end of a given file:
|
||||
|
||||
`tail --bytes {{count}} {{path/to/file}}`
|
||||
`tail {{[-c|--bytes]}} {{count}} {{path/to/file}}`
|
||||
|
||||
- Print the last lines of a given file and keep reading it until `<Ctrl c>`:
|
||||
|
||||
`tail --follow {{path/to/file}}`
|
||||
`tail {{[-f|--follow]}} {{path/to/file}}`
|
||||
|
||||
- Keep reading file until `<Ctrl c>`, even if the file is inaccessible:
|
||||
|
||||
`tail --retry --follow {{path/to/file}}`
|
||||
`tail --retry {{[-f|--follow]}} {{path/to/file}}`
|
||||
|
||||
- Show last 'num' lines in 'file' and refresh every 'n' seconds:
|
||||
|
||||
`tail --lines {{count}} --sleep-interval {{seconds}} --follow {{path/to/file}}`
|
||||
`tail {{[-n|--lines]}} {{count}} {{[-s|--sleep-interval]}} {{seconds}} {{[-f|--follow]}} {{path/to/file}}`
|
||||
|
||||
Reference in New Issue
Block a user