The UNIX and Linux Forums
>
Top Forums
>
Shell Programming and Scripting
SED to convert ~ in a file to newline
User Name
Remember Me?
Password
Google UNIX.COM
Forums
Directory
Register
Forum Rules
FAQ
Contribute
Members List
Search
Today's Posts
Mark Forums Read
Thread
:
SED to convert ~ in a file to newline
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
#
2
(
permalink
)
05-07-2007
reborg
Administrator
Join Date: Mar 2005
Location: Ireland
Posts: 3,824
one way:
Code:
awk 'BEGIN{FS="~" ;OFS="\n"} {$1=$1}1' file
or another:
Code:
tr '~' '\n' < file
reborg
View Public Profile
Find all posts by reborg