guys... I wanna use xargs in such a way that i can use it in grepping the fileds..
something like this:
grep -p <xargs values> *
lemme know how to do this.. (5 Replies)
Dear all,
I have tried the following 2 lines
xargs -t -i -exec grep -i -w {} file_1 >>test < file_2
cat -s file_2| xargs -t -i -exec grep -i -w {} file_1 >> test
They were meant to search for the contents of file_2 in file_1 and write the respective lines of file_1 into file "test" .... (15 Replies)
I am trying to delete files older than 60 days from a folder:
find /myfolder/*.dat -mtime +60 -exec rm {} \;
ERROR - argument list too long: find
I can't just give the folder name, as there are some files that I don't want to delete. So i need to give with the pattern (*.dat). I can... (3 Replies)
hi,
i've been trying to figure this weird error but I cannot seem to know why. I am using below find command:
find . \( ! -name . -prune \) -type f -mtime +365 -print
The above code returns no file because no files are really more then 365 days old. However, when I use xargs, its... (9 Replies)
Folks
I've been struggling this with for far too liong now and need your help!
I've been happily using grep for a search of a directory, to list the files which contain a string:
find . -type f -mtime -5 -print | xargs grep -l 'invoiceID=\"12345\"'
Now the list of 'invoiceID' I am... (4 Replies)
Guys i want to run a command to list all directories that havn't been modified in over 548 days ( 1.5 yrs ).
Id like to run a script to first print what the command finds ( so i get a list of the files pre move ... i have a script set for this :
find /Path/Of\ Target/Directory/ -type d -mtime... (4 Replies)
Hello,
I'm interested in finding all occurrences of the terms in file1 in file2, which are both csv files. I can do this with a loop but I'm interested in knowing if I can also do it with the help of xargs and grep. What I have tried:
cat file1 | xargs grep file2
The problem is that... (15 Replies)
How can I recursively find all files in a directory and print out the file and first line number of any text blocks that match the below cases?
This would seem to involve find, xargs, *grep, regex, etc.
In summary, I want to find so-called empty "try-catch blocks" that do not contain code... (0 Replies)
Hi,
I want to find some files and then search for some lines in it with a particular pattern and then write those lines into a file. To do this I am using something like this from command prompt directly.
cd /mdat/BVG
find -name "stmt.*cl" -newer temp.txt | xargs -i awk '/BVG-/{print}' {} >... (7 Replies)
In a directory I have two lists, all files which could contain certain fields (they all share copied code) and a list of fields. My two scripts are
<appl.list xargs grep $1
where appl.list contains files (source programs) with the fields. This script is named YY
<fields.list xargs YY
... (4 Replies)
Discussion started by: wbport
4 Replies
LEARN ABOUT FREEBSD
bus_release_resource
BUS_RELEASE_RESOURCE(9) BSD Kernel Developer's Manual BUS_RELEASE_RESOURCE(9)NAME
bus_release_resource -- release resources on a bus
SYNOPSIS
#include <sys/param.h>
#include <sys/bus.h>
#include <machine/bus.h>
#include <sys/rman.h>
#include <machine/resource.h>
int
bus_release_resource(device_t dev, int type, int rid, struct resource *r);
DESCRIPTION
Free a resource allocated by bus_alloc_resource(9). The resource must not be in use on release, i.e., call an appropriate function before
(e.g. bus_teardown_intr(9) for IRQs).
dev is the device that owns the resource.
type is the type of resource that is released. It must be of the same type you allocated it as before. See bus_alloc_resource(9) for valid
types.
rid is the resource ID of the resource. The rid value must be the same as the one returned by bus_alloc_resource(9).
r is the pointer to struct resource, i.e., the resource itself, returned by bus_alloc_resource(9).
RETURN VALUES
EINVAL is returned, if the device dev has no parent, 0 otherwise. The kernel will panic, if it cannot release the resource.
EXAMPLES
/* deactivate IRQ */
bus_teardown_intr(dev, foosoftc->irqres, foosoftc->irqid);
/* release IRQ resource */
bus_release_resource(dev, SYS_RES_IRQ, foosoftc->irqid,
foosoftc->irqres);
/* release I/O port resource */
bus_release_resource(dev, SYS_RES_IOPORT, foosoftc->portid,
foosoftc->portres);
SEE ALSO bus_alloc_resource(9), device(9), driver(9)AUTHORS
This manual page was written by Alexander Langer <alex@big.endian.de>.
BSD May 18, 2000 BSD