Computing.Net > Forums > Unix > sed :Unterminated s command

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

sed :Unterminated s command

Reply to Message Icon

Name: Bala123
Date: November 29, 2008 at 03:15:43 Pacific
OS: Unix
CPU/Ram: Core 2 Duo, 1GB
Product: Intel
Comment:

Hi

I'm getting this unterminated s command prob.
#echo $out ==> Unix Command and then a newline character
(When i tried seeing octal dump by using "echo $out | od -bc"), it showed a newline character


#echo $string ==> "Welcome.Unix Command" and then a newline at the end..

#echo $string | sed "s/$ban//g"

this command is giving "unterminated s command" bcoz shell is interpreting the newline character.. how can i prevent this..

Also, can i remove a newline character at the end of a string using sed..??



Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Unix Forum Home


Sponsored links

Ads by Google


Results for: sed :Unterminated s command

sed or awk command www.computing.net/answers/unix/sed-or-awk-command/6141.html

sed dropping last line of file www.computing.net/answers/unix/sed-dropping-last-line-of-file/5125.html

Small sed bug - line below www.computing.net/answers/unix/small-sed-bug-line-below/5438.html