Post date: Jun 29, 2014 9:57:30 PM
Get lines from text file
## The first line onlyhead -1 mds_out_2014-01-01_2014-01-31_2014-06-28.csv > tmp## Get the second line onlysed -n 2p mds_out_2014-02-01_2014-02-28_2014-06-28.csv >> tmp## Get line 10th to 20th (11 lines)sed -n '10,20p' mds_out_2014-02-01_2014-02-28_2014-06-28.csv >> tmp## get all lines from 2nd line to the endtail -n +2 mds_out_2014-02-01_2014-02-28_2014-06-28.csvmore resources:
http://www.commandlinefu.com/commands/view/3802/to-print-a-specific-line-from-a-file
http://stackoverflow.com/questions/339483/how-can-i-remove-the-first-line-of-a-text-file-using-bash-sed-script