I have a file with which i must remove the last line of the file (the footer). I know how to copy and redirect with tail -1 etc, but how do i delete it permanentely (4 Replies)
My data is xml'ish (here is an excerpt) :-
<bag name="mybag1" version="1.0"/>
<contents id="coins"/>
<bag name="mybag2" version="1.1"/>
<contents id="clothes"/>
<contents id="shoes"/>
<bag name="mybag3" version="1.6"/>
I want to delete line containing mybag2 and its subsequent... (5 Replies)
Hi,
How do I go about deleting a line in a text file. I have used grep to find a particlular word, now how do I delete the line?
so far I got:
grep -i $keyword file.txt (6 Replies)
I have file A with 10 lines and file B with 15 lines
I have to read each line from file A and match it with lines in file B
If matching lines are found i need to delete it from file B
The ouput will be the deleted file B
I tried the following in the loop but the deleting part is not... (5 Replies)
trying to use sed in finding a matching pattern in a file then deleting
the next line only .. pattern --> <ad-content>
I tried this but it results are not what I wish
sed '/<ad-content>/{N;d;}' akv.xml > akv5.xml
ex,
<Celebrant2First>Mickey</Celebrant2First>
<ad-content>
Minnie... (2 Replies)
PATTERN=""
sed "/$PATTERN/d" $file
In the file data is stored as
:::
:::
I need to delete only the line containing the PATTERN
pls help to point out why the above code is not working (4 Replies)
Sample file:
This is line one,
this is another line,
this is the PRIMARY INDEX line
l ;
This is another line
The command should find the line with “PRIMARY INDEX” and remove the last character from the line preceding it (in this case , comma) and remove the first character from the line... (5 Replies)
Hi,
I have a large text file with the following format:
>gi|347545744|gb|JN204951.1| Dismorphia spio voucher 5
ATCAAATTCCTTCCTCTCCTTAAA
>gi|17544664774|gb|WN204922.32| Rodapara nigens gene region
CCGGGCAAATTCCTTCCTCTCCTTAAA
>gi|555466400|gb|SG255122.8| Bombyx mandariana genbank 3... (1 Reply)
The awk below executes as expected if the id in $4 (like in f) is unique. However most of my data is like f1 where the same id can appear multiple times. I think that is the reason why the awk is not working as expected. I added a comment on the line that I can not change without causing the script... (6 Replies)
Discussion started by: cmccabe
6 Replies
LEARN ABOUT DEBIAN
qmhandle
Qmhandle(1) General Commands Manual Qmhandle(1)NAME
qmhandle - tool to manage the qmail message queue
SYNOPSIS
qmhandle [--help] [--version]
DESCRIPTION
qmHandle is a tool which can be used to manage the qmail message queue. It's written in Perl (so fully customizable) and has more features
than qmail-qread and qmail-qstat.
OPTIONS -a try to send queued messages now (qmail must be running)
-l list message queues
-L list local message queue
-R list remote message queue
-s show some statistics
-mN display message number N
-dN delete message number N
-fsender
delete message from sender
-f're delete message from senders matching regular expression re
-Stext delete all messages that have/contain text as Subject
-h're' delete all messages with headers matching regular expression re (case insensitive)
-b're' delete all messages with body matching regular expression re (case insensitive)
-H're' delete all messages with headers matching regular expression re (case sensitive)
-B're' delete all messages with body matching regular expression re (case sensitive)
-t're' flag messages with recipients in regular expression 're' for earlier retry (note: this lengthens the time message can stay in queue)
-D delete all messages in the queue (local and remote)
-V print program version
-c display colored output
-N list message numbers only
AUTHORS
Marcela Tiznado <mlt@debian.org>
Qmhandle(1)