Solution 1:
Use the head command from coreutils:
head -n -2
See info head
for more.
Solution 2:
You simply want.
head -n-2 file
Read man head
for more information.
Use the head command from coreutils:
head -n -2
See info head
for more.
You simply want.
head -n-2 file
Read man head
for more information.