2
0
mirror of https://github.com/chubin/cheat.sheets synced 2024-11-19 03:25:44 +00:00
cheat.sheets/sheets/nl

8 lines
263 B
Plaintext
Raw Normal View History

# Number lines given to `nl` via STDIN.
printf "Here\nis\nsome\nexample\ntext." | nl
# Number (all) lines given to `nl` via provided file(s).
nl -b a /path/to/file
# The above can also be achieved with `cat`, which is perhaps more portable:
cat -n /path/to/file