Stampare l'n-esima riga di un file con sed

From RVM Wiki
Revision as of 20:22, 18 October 2005 by Gabriele.vivinetto (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


To print the nth line of a file:

sed -n 4711p filename

Esempio per stampare solo la trentesima riga del file pippo.txt:

cat pippo.txt | sed -n 30