How can I add numbers to the beginning of every line in a file?
E.g.:
This is the text from the file.
Becomes:
000000001 This is 000
Easiest, simplest option is
awk '{print NR,$0}' file
See comment above on why nl isn't really the best option.