10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi, i have a fasta file like this:
>contig00003 length=363 numreads=45 gene=isogroup00001 status=it_thresh
GATTTTTTACCCTGGGAGTGAGGAGGACGAGGTTGAGGATGAAGAAAAGAGAAAGATGAAGAGGTTGAGGATGTT
GTAGTCGGCGGTGGAATTAGGGGGAGCCGGCGAGCCCAAGTATTTTGCAGAGGTGTCTTCATCATCCAAACAACA... (3 Replies)
Discussion started by: the_simpsons
3 Replies
2. UNIX for Dummies Questions & Answers
I have a word file that looks like:
pens
binder
spiral
user
I want to delete all the words without the letter /s/, so output looks like:
pens
spiral
user
I tried using sed:
sed '//d' infile.txt > out.txt (5 Replies)
Discussion started by: pxalpine
5 Replies
3. Shell Programming and Scripting
Hi all,
I want to make an script using sed that removes everything between 'begin' (including the line that has it) and 'end1' or 'end2', not removing this line.
Let me paste an 2 examples:
anything before
any string begin
few lines of content
end1
anything after
anything before
any... (4 Replies)
Discussion started by: meuser
4 Replies
4. Shell Programming and Scripting
This is a Nagios situation.
So i have a list of servers in one file called Servers.txt
And in another file called hostgroups.cfg, i want to remove each and every one of the servers in the Servers.txt file.
The problem is, the script I wrote is having a problem removing the exact servers in... (5 Replies)
Discussion started by: SkySmart
5 Replies
5. Shell Programming and Scripting
Hi,
I wanted to delete data between two words.
Input:
I read gihoihsahkjlk write goal hard read hsakdjhkh write work read hlkhlkhlkh write
Desired Output:
I write goal hard write work write
We have to replace the data that comes between 'read' and 'write' with... (3 Replies)
Discussion started by: mahish20
3 Replies
6. Shell Programming and Scripting
Hi All,
I have an input file a.txt which contains the following ::
08-08-09 1:00 PM 763763762 f00_unix1_server.txt
i Just need to delete all the words which is before f
Output ::
f00_unix1_server.txt
Thanks (4 Replies)
Discussion started by: raghav1982
4 Replies
7. UNIX for Dummies Questions & Answers
hi,
I have a doubt. how we can remove few words based on search.
here im specifying my requirement with example.
ALL the words should delete between two words ...
those words will ends **
EX : cat infile.txt
"HI",ob1**,ob2,ob3,ob4**,ob5,ob6
OUTPUT... (2 Replies)
Discussion started by: spc432
2 Replies
8. UNIX for Advanced & Expert Users
Hi,
Could you please let me know, how to delete first 10 words from text files using vi?
10dw will delete it from current line, how to do it for all the lines from file?
Thanks (6 Replies)
Discussion started by: sentak
6 Replies
9. UNIX for Dummies Questions & Answers
Hi,
I have the following codes below that aims to delete every words between two pattern word. Say I have the files
To delete every word between WISH_LIST=" and " I used the below codes (but its not working):
#!/bin/sh
sed '
/WISH_LIST=\"/ {
N
/\n.*\"/ {... (3 Replies)
Discussion started by: Orbix
3 Replies
10. Shell Programming and Scripting
How can I delete lines that contain 3 or more words?
I have a file, old.txt, that has multi-word phrases in it and I want to remove the lines with 3 words or more and send the output to new.txt.
I've tried the following using sed but it doesn't seem to work:
sed '/(\b\w+\b){3,}/d' old.txt >... (5 Replies)
Discussion started by: revax
5 Replies