Hi,
I have around 200,000 files in a given directory.
I need to cat each of these files and grep them for thousands of identifier values (or strings) in a given text file.
The text file looks something like this:
1234
1243545
1234353
121324
etc with thousands of entries.
Can you please assist how I can do this, and in the most efficient manner possible because this script will
have you tried grepping your file system for hdmi or grepping the name of the card ?maybe some file somewhere, the hdmi card is set before other cards. remember any changes you make might need reboot.grep -r "hdmi" /etcor that /proc directory
arobson73
https://bbs.archlinux.org/profile.php?id=67534
2013-04-16T10:55:47Z
Mac Os X does not have the useful linux command rename, which has the following format:
rename 'perl-regex' list-of-files
So here's what I have put together but it does not rename any files ($new is always the same as $file):
#!/usr/bin/env perl -w
use strict;
use File::Copy 'move';
my $regex=shift;
my @files=@ARGV;
for my $file (@files)
{
my $new=$file;
$new =~ "$regex"; # this i
Hello,
I have a text file which contains a list of strings which I want to grep from another file where these strings occur and print out only these lines.
I had earlier used the grep command
Quote:
grep -f File1 File2
where File1 was the file containing the strings to be grepped (Source File) and File2 the Target File from which the strings ha
Hello,
I have a file with a large number of words each listed in sequential order one word per line.
Hi Guys!
1st of all, i am sorry for my bad english!
I got a Sat-Receiver and i recorded some Stuff for my Children, now the Harddrive is full and i want to convert and rename it, that i can put it on DVDs
But I've got a big Problem!
In my app i am getting the images from a folder in gallery and saving it into an array list.Now i want to extract only the files with .jpg extension.How can i do it
The code for saving to array list is
private List<String> ReadSDCard()
{
//It have to be matched with the directory in SDCard
File f = new File("sdcard/data/crak");
File[] files=f.listFiles();
for(i
Hi!
I recently downloaded a wordlist file called 2of12.txt, which is a wordlist of common words, part of the 12dicts package.
I have about 40 zip files each with a different name. However, the txt file inside each zip is called the same thing File.txt
How can I unzip them all and rename the file inside it so that it does not overwrite each time?
unzip '*.zip' is for the unzipping but the renaming?
Or alternatively, create a folder for each file.