Hi,
I have this problem of separating 10 consecutive lines from a file, say starting from 21 to 30... I have used a filter like this..
head -n 30 myfile | tail -n 10
Is there a simpler way than this? (2 Replies)
Hi,
I am planning to implement a scheduled script that will go against my log files (every hour), search for a set of key words (errors, exceptions, faults etc). The script must be intelligent enough to scan only the new lines added to the log file since it last ran.
I can use grep for... (3 Replies)
Hi ,
I'm looking for a way to merge two lines only for a given pattern / condition.
Input :
abcd/dad + -49.201 2.09 -49.5 34 ewrew rewtre *
fdsgfds/dsgf/sdfdsfasdd +
-4.30 0.62 -49.5 45 sdfdsf cvbbv *
sdfds/retret/asdsaddsa +
... (1 Reply)
Hello
I have a file in following format:
IV 08:09:07
NM 08:12:01
IC 08:12:00
MN 08:14:20
NM 08:14:15
I need a script to compare time on each line with previous line and show the inconsecutive line. Ex.:
08:12:00
08:14:15
A better way... (6 Replies)
Hi guys
I am deleting a unique line from the file and also need to remove the line above it which is NOT unique and servers as a record separator. Here is an example:
#
101 803E 823F 8240
#
102 755f 4F2A 4F2B
#
290 747D 0926 0927
#
999 8123 813E ... (5 Replies)
i want to write a shell script that correct a text file.for example if i have the input file:
"john has has 2 apples
anne has 3 oranges oranges"
i want that the output file be like this:
"john has 2 apples
anne has 3 oranges"
i've tried to read line by line from input text file into array... (11 Replies)
We have very large transaction logs that have transactions which start with a line that starts with 'Begin :' and ends with a line that starts with 'End :'. For most transactions there is valid data between those two lines.
I am trying to get rid of lines that look like this:
Begin :... (11 Replies)
I have a text file that is about 90,000 lines long. How would I delete lines 64-89, 152-177, 240-265, 328-353... etc? The sections I would like to delete are 26 lines long and the number of lines between the sections I would like to delete is 62 lines. Thanks very much in advance. (6 Replies)
I have a file lake this
cat ex1.txt
</DISCOUNTS>
<B2B_SPECIFICATION elem="0">
<B2B_SPECIFICATION elem="0">
<DESCR>Netti 2 </DESCR>
<NUMBER>D02021507505</NUMBER>
</B2B_SPECIFICATION>
<B2B_SPECIFICATION elem="1">
<DESCR>Puhepaketti</DESCR>... (2 Replies)
I have some data that looks like this:
PXD= ZW< 1,6
QR> QRJ== 1,2(5)
QR> QRJ== 4,1(2)
QR> QRJ== 4,2
QRB= QRB 4,2
QWM QWM 6,2
R<C ZW< 11,2
R<H= R<J= 6,1
R>H XZJ= 1,2(2)
R>H XZJ= 2,6(2)
R>H XZJ= 4,1(2)
R>H XZJ= 6,2
RDP RDP 1,2
What I would like to do is if fields $1 and $2 are... (5 Replies)
Discussion started by: jvoot
5 Replies
LEARN ABOUT DEBIAN
auscanevents
AuScanEvents(3) Library Functions Manual AuScanEvents(3)Name
AuScanEvents - return the first event that satisfies the predicate
Synopsis
#include <audio/audiolib.h>
AuBool AuScanEvents(server, mode, dequeue, predicate, arg, event)
AuServer *server;
int mode;
AuBool dequeue;
AuBool (*predicate)(AuServer *,AuEvent *, AuPointer);
AuPointer arg;
AuEvent *event; /* RETURN */
Arguments
server Specifies the connection to the audio server.
mode Specifies how far to look for a match. This should be one of these constants: AuEventsQueuedAlready, AuEventsQueuedAfterReading,
or AuEventsQueuedAfterFlush.
dequeue Specifies if a matching event is found, should it be removed from the queue.
predicate Specifies the procedure that is called to determine if an event matches the criteria.
arg Specifies any additional arguments to be passed to the predicate procedure.
event Returns the matching event if found.
Description
AuScanEvents scans the event queue looking for the first event that satisfies the caller-supplied predicate. If mode is AuEventsQueuedAl-
ready, AuScanEvents only checks for events already in the queue. If mode is AuEventsQueuedAfterReading, and a matching event isn't found
already in the queue, AuScanEvents attempts to read more events out of the application's connection. If mode is AuEventsQueuedAfterFlush
and a matching event isn't already in the queue or isn't waiting to be read, AuScanEvents flushes the output queue and attempts to read
more events out of the application's connection. If dequeue is AuTrue, and a matching event is found, it is removed from the queue. The
predicate procedure is called with the arguments server, event, and arg and should return AuTrue to indicate a match.
See Also
AuEventsQueued, AuScanForTypedEvent, AuNextEvent.
audiolib - Network Audio System C Language Interface
audiolib - event handling 1.9.3 AuScanEvents(3)