Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 02-01-2012, 03:17 PM   #1
LQ Newbie
Registered: Aug 2011
Posts: 20

Rep: Reputation: Disabled
how do i add a line with double quotes in sed?

here is the line:

i want this to be replaced with:

this is what i thought would work but doesnt:
sed -i '/"AStringHere"=dword:00000000/"AStringHere"=dword:00000001' filepath

how do i fix this?

Last edited by Beandip408; 02-01-2012 at 03:21 PM. Reason: nevermind i figured it out:
Old 02-01-2012, 03:22 PM   #2
LQ Newbie
Registered: Aug 2011
Posts: 20

Original Poster
Rep: Reputation: Disabled
so i solved it. i forgot the "c" so it looks like this:

sed -i '/"AStringHere"=dword:00000000/c"AStringHere"=dword:00000001' filepath


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] bash/sed/awk to convert comma's not in quotes in a line with many comma's oly_r Programming 23 01-25-2012 08:53 AM
[SOLVED] How to escape single quotes in sed for multi line pattern XXLRay Linux - Software 1 07-18-2011 07:35 AM
Double Quotes Inside Double Quotes youarefunny Programming 6 06-09-2010 10:21 PM
Problems with quotes and double quotes Andruha Slackware 6 01-02-2010 04:44 PM
Using single quotes vs double quotes in PHP strings vharishankar Programming 6 07-11-2005 11:41 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:59 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration