10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Have multiple files with the same format and certain text is the same. Have specific text to search for and then need to replace the next line. Can search on the text DEVICE and multiple lines will be found. The line after each DEVICE line has {. Want to replace the line { with {-someadditiontext.... (2 Replies)
Discussion started by: bigdaddywags
2 Replies
2. UNIX for Dummies Questions & Answers
I want to replace lines. The files 1 are (separated by \t)
Gm01 phytozome9_0 three_prime_UTR 70641 70759 . - . ID=PAC:26323927.three_prime_UTR.1;Parent=PAC:26323927;pacid=26323927
Gm01 phytozome9_0 three_prime_UTR 90230 90692 . - . ... (1 Reply)
Discussion started by: grace_shen
1 Replies
3. Shell Programming and Scripting
I have a file which requires modification via a shell script.
Need to do the following: 0. take input from user for new text. 1. search for a keyword in the file. 2. replace the line next to this to this keyword with user supplied input.
for e.g., my file has the following text:
(some... (7 Replies)
Discussion started by: chingupt
7 Replies
4. Shell Programming and Scripting
Literally cannot get this one, guys. Single line replacement is simple, but I am not understanding the correct syntax for including a new line feed into the substitution part.
Here's what I got. (Cannot use perl)
#!/bin/sh
set -f
#Start Perms
export HOME=/home/test_user
# End Perms... (6 Replies)
Discussion started by: Parallax
6 Replies
5. Shell Programming and Scripting
Hi,
i want to replace
"Hi How
are You when
did you go to
delhi"
to
"Hi How
are you when
did you come from
delhi"
in a file.
Any idea how to do it? (2 Replies)
Discussion started by: abhitanshu
2 Replies
6. Shell Programming and Scripting
i have something like this...
cat filename.txt
<complexType name="abc">
bklah vlah
blah
blha blha blah
blha
</complexType >
<complexType name="def">
bklah vlah
blah
blha blha blah
blha
</complexType >
.
.
.and so on.. its a very large file (11 Replies)
Discussion started by: vivek d r
11 Replies
7. UNIX for Dummies Questions & Answers
I want to replace this line : "test compare visible] true" and make it "#test compare visible] true".
How can I do it ? And it should be checked in many sub folder files also. (6 Replies)
Discussion started by: manoj.b
6 Replies
8. UNIX for Dummies Questions & Answers
hi all,
i am new bee to Unix.
i know how to replace text for range of lines in vi
for e.g. replace | with |||| for line 4 through 7 using vi
: 4,7s/|/||||/g
but i have to replace | with |||| only for line no 4, 7 and 10 using vi only!!!
your help will be appreciated!
thanks,... (4 Replies)
Discussion started by: pranav.pandya
4 Replies
9. UNIX for Advanced & Expert Users
I have a file which contains the following data.
Parameters "CParameters"
BEGIN DSSUBRECORD
Name "TgtDB"
Prompt "TgtDB"
Default "edwdev"
ParamType "0"
ParamLength "0"
ParamScale "0"
END DSSUBRECORD
MetaBag... (6 Replies)
Discussion started by: ukatru
6 Replies
10. UNIX for Dummies Questions & Answers
I need to change the first line a file from
"HDR,{any_number}",,,,,
where {any_number} is incremental for each file
to
HDR,{any_number}
Can someone please suggest an easy way please
Regards
Col (3 Replies)
Discussion started by: colinchase
3 Replies