mirror of
https://github.com/tldr-pages/tldr.git
synced 2026-08-30 17:33:50 +08:00
head: fix errors and improve descriptions (#18967)
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
This commit is contained in:
+8
-8
@@ -3,18 +3,18 @@
|
||||
> Output the first part of files.
|
||||
> More information: <https://keith.github.io/xcode-man-pages/head.1.html>.
|
||||
|
||||
- Output the first few lines of a file:
|
||||
- Output the first 10 lines of a file:
|
||||
|
||||
`head {{[-n|--lines]}} {{8}} {{path/to/file}}`
|
||||
`head {{path/to/file}}`
|
||||
|
||||
- Output the first few bytes of a file:
|
||||
- Output the first 5 lines of multiple files:
|
||||
|
||||
`head {{[-c|--bytes]}} {{8}} {{path/to/file}}`
|
||||
`head {{[-5|--lines 5]}} {{path/to/file1 path/to/file2 ...}}`
|
||||
|
||||
- Output everything but the last few lines of a file:
|
||||
- Output the first `count` lines of a file:
|
||||
|
||||
`head {{[-n|--lines]}} -{{8}} {{path/to/file}}`
|
||||
`head {{[-n|--lines]}} {{count}} {{path/to/file}}`
|
||||
|
||||
- Output everything but the last few bytes of a file:
|
||||
- Output the first n `bytes` of a file:
|
||||
|
||||
`head {{[-c|--bytes]}} -{{8}} {{path/to/file}}`
|
||||
`head {{[-c|--bytes]}} {{bytes}} {{path/to/file}}`
|
||||
|
||||
Reference in New Issue
Block a user