10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
sed /'1-2'/&^/ filename
suppose there is a file containing three lines , how do we do delete the word from each line?
hyter efr frf
rerfer efe ewd
cdcf evrfgf erfv
the output has to look like
frf
ewd
erfv (2 Replies)
Discussion started by: Rajeev Nukala
2 Replies
2. UNIX for Dummies Questions & Answers
I have a file from which I am trying to delete a particular word on a particular line.
NEW
NEW
/v/engine
NEW
/ifs/list
NEW
/ifs/vdrome
NEW
I am trying to delete the first line only if it contains the word NEW. I am also trying to delete the last line only if it contains the word NEW. I... (11 Replies)
Discussion started by: newbie2010
11 Replies
3. Shell Programming and Scripting
I have a file that contains the following:
^field LINE_1 data
^field LINE_2 data
^field LINE_3 data
^field LINE_4 data
^field LINE_5 data
...
And im looking to do a line break at the end of the number before the text to make it look like this
^field LINE_1 ... (11 Replies)
Discussion started by: darbs121
11 Replies
4. UNIX for Dummies Questions & Answers
Hi,
I have gone through may posts and dint find exact solution for my requirement.
I have file which consists below data and same file have lot of other data.
<MAPPING DESCRIPTION ='' ISVALID ='YES' NAME='m_TASK_UPDATE' OBJECTVERSION ='1'>
<MAPPING DESCRIPTION ='' ISVALID ='NO'... (11 Replies)
Discussion started by: tmalik79
11 Replies
5. Shell Programming and Scripting
Hi Gurus
I am new to this forum.. I am using HP Unix OS.
I have one single string in input file as shown below
Abc123 | cde | fgh | ghik| lmno | Abc456 |one |two |three | four | Abc789 | five | Six | seven | eight | Abc098 | ........
I want to achive the result in a output file as shown... (3 Replies)
Discussion started by: kannansr621
3 Replies
6. Shell Programming and Scripting
<td>
CIS
</td>and I tried to sed 's/<td>\/nCIS\/n<\/td>/<td><\/td>' and sed 's/<td>\/rCIS\/r<\/td>/<td><\/td>' , but no joy. This is an html page that I need to clean. (4 Replies)
Discussion started by: dba_frog
4 Replies
7. Shell Programming and Scripting
Hi there,
I'd like to delete the beginning of a line up until it finds a certain word or character string: in this case, I'd like to delete each line up to the word "mounting".
Thanks ;)
Susan (12 Replies)
Discussion started by: kitykity
12 Replies
8. Shell Programming and Scripting
Hello,
I'm trying to move the last word of matching pattern to the begining of next line. Appreciate if anyone post the script.
From the below line I'm getting the last word, Note: this word also appears in many places in my file
#return the last word of line that contains ListenPort
sed... (4 Replies)
Discussion started by: baskar
4 Replies
9. Shell Programming and Scripting
*Note, I thought I was in Shell Programming and Scripting Q&A and posted in a wrong forum. To avoid confusion and to inform people that I'm not trying to "spam" the forums, I'm adding this note up top*
Hi Everyone thanks in advance for any input you can provide on the following question! I'm... (2 Replies)
Discussion started by: Janus
2 Replies
10. Shell Programming and Scripting
Hello !
I have a result of ls command in a file:
file1 file2 file3.out file4.pdf file5
they all are separated by space.
I need to put them on a separate line
example:
file1
file2
file3.out
file4.pdf
fil35
i tried
sed 's/ /\n/g' inputfile > outputfile
but did not help (3 Replies)
Discussion started by: hemangjani
3 Replies