Date: Fri, 12 May 2006 20:00:52 +0300 From: Giorgos Keramidas <keramida@ceid.upatras.gr> To: freebsd-questions@freebsd.org Subject: Re: Trimming Whitespace From Beginning and end of Text Lines Message-ID: <20060512170052.GD26040@gothmog.pc> In-Reply-To: <000d01c675dc$9a36dee0$01010101@avalon.lan> References: <4464A94C.6020606@mac.com> <000d01c675dc$9a36dee0$01010101@avalon.lan>
next in thread | previous in thread | raw e-mail | index | archive | help
On 2006-05-12 17:56, "No@SPAM@mgEDV.net" <nospam@mgedv.net> wrote: >>> sed -i -e 's/^[[:space:]]*' -e 's/[[:space:]]*$//' file ... > > why not use just (you can change the "-" separator to "/" as above): > sed -e 's-^ *--g' -e 's- *$--g' Because this provides no additional help with the problem of not matching TABS and it looks very confusing so close to `-e' and other command-line options.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060512170052.GD26040>