10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Trying to use sed to, in-place, remove specific text from a file. Since there are / in the text I use | to escape that character. Thank you :).
sed -i -e 's|xxxx://www.xxx.com/xx/xx/xxx/.*/|' /home/cmccabe/list
sed: -e expression #1, char 51: unterminated `s' command (4 Replies)
Discussion started by: cmccabe
4 Replies
2. Shell Programming and Scripting
Hi there, my first post, so you might find my noobness ;)
I need help to fix a thing,
find /mnt/fs01/gfx/ -iname "*.rar" > gfx.txt
Gives this contained textfile:
/mnt/fs01/gfx/toba/toba.rar
/mnt/fs01/gfx/zeta/zimba.rar
/mnt/fs01/gfx/brashe/getha.rar
And now the tricky part (for... (3 Replies)
Discussion started by: yabbah
3 Replies
3. Shell Programming and Scripting
I have test.xml XML file like
<Report account="123456" start_time="2014-09-08T00:00:00+00:00" end_time="2014-09-10T23:59:59+00:00" user="Dollar Tree" limit="1000000" more_sessions="some text ">
<Session ......rest of xml...............
I need output like
<Report>
<Session ......rest of... (3 Replies)
Discussion started by: kumars1331@gmai
3 Replies
4. Shell Programming and Scripting
I found that the following works to remove the first column in my file when my CSV is delimited with a simple comma:
sed -i 's/*,//' file.csv
However, I have a new file where the fields are encapsulated with double quotes - general example of file:
"Internal ID", "External ID", "Name"... (8 Replies)
Discussion started by: lojkyelo
8 Replies
5. UNIX for Dummies Questions & Answers
First of all let it be said that I hate sed. Every time I think I've got it figured out it proves me wrong. There, now with that out of the way here's my problem that I'm hoping one of you smart people can solve:
I have a file full of lines like this:
If x=1 then /* this is an if statement */... (10 Replies)
Discussion started by: Korn0474
10 Replies
6. Shell Programming and Scripting
Hi All
A .csv file containing multiple value on it. i need to remove some value from it. Please advise how can i find multiple value from that and remove itself. Please provide solution for this.
Thanks in advance. (4 Replies)
Discussion started by: yash1978
4 Replies
7. Shell Programming and Scripting
I have a large CSV files (e.g. 2 million records) and am hoping to do one of two things. I have been trying to use awk and sed but am a newbie and can't figure out how to get it to work. Any help you could offer would be greatly appreciated - I'm stuck trying to remove the colon and wildcards in... (6 Replies)
Discussion started by: metronomadic
6 Replies
8. Shell Programming and Scripting
what is the sed command to remove the first two characters of every line of a text file?
each line of the text file has the same amount of characters, and they are ALL NUMERIC. there are hundreds of lines though.
for example,
>cat file1.txt
10081551
10081599
10082234
10082259
20081134... (20 Replies)
Discussion started by: ajp7701
20 Replies
9. Shell Programming and Scripting
How to use sed to remove html tags including text between them?
Example: User <b> rolvak </b> is stupid. It does not using <b>OOP</b>!
and should output: User is stupid. It does not using !
Thank you.. (2 Replies)
Discussion started by: alphagon
2 Replies
10. Shell Programming and Scripting
Hello,
I have many csv file, but I would like to delete lines with some values in a column conditionally.
My example look like this,
ex1e, ex2g, ex39, pasg, ssg, mrlc, pc, kb, coop
-112, -53, -177, 64, 62, 71, 1, 487, 20
-101, -61, -53, 0, 32767, 51, 0, ... (6 Replies)
Discussion started by: Jae
6 Replies