On 12/25/11, Anthony J. Bentley <anthonyjbent...@gmail.com> wrote: On 12/24/11, Szabolcs Nagy <n...@port70.net> wrote: >> * hiro <23h...@googlemail.com> [2011-12-24 02:00:47 +0100]: >>> >> sed -i 1d original.dat > > That’s a GNUism. > What about $(rp "sed 1d" original.dat) ;)
To address the original (-er) question, I think moreutils sponge(1) is the answer, filename duplication notwithstanding. % sed 1d <original.dat | sponge original.dat