how about cksum - that is far easier to use. It gives a filesize. Or you can use the check sum, either way.
This code assumes your cksum implmentation gives:
hi all,
in my server there are some specific application files which are spread through out the server... these are spread in folders..sub-folders..chid folders...
please help me, how can i find the total size of these specific files in the server... (3 Replies)
Hi,
Could anyone help me to solve this problem?
I have two files "f1" and "f2" having 2 fields in each, a) file size and b) file name. The data are almost same in both the files except for few and new additional lines. Now, I have to find out and print the output as, the difference in the... (3 Replies)
hi,
Please help me to write a command to delete duplicate lines from a file. And the size of file is 50 MB. How to remove duplicate lins from such a big file. (6 Replies)
Hi !
I wonder if anyone can help on this : I have a directory: /xyz that has the following files:
chsLog.107.20130603.gz
chsLog.115.20130603
chsLog.111.20130603.gz
chsLog.107.20130603
chsLog.115.20130603.gz
As you ca see there are two files that are the same but only with a minor... (10 Replies)
Hi champs,
I have one of the requirement, where I need to compare two files line by line and ignore duplicates. Note, I hav files in sorted order.
I have tried using the comm command, but its not working for my scenario.
Input file1
srv1..development..employee..empname,empid,empdesg... (1 Reply)
Hello,
I have a huge directory (with millions of files) and need to find out duplicates based on BOTH file name and File size.
I know fdupes but it calculates MD5 which is very time-consuming and especially it takes forever as I have millions of files.
Can anyone please suggest a script or... (7 Replies)
Perl::Critic::Policy::Variables::RequireNegativeIndices(User Contributed Perl DocumentPerl::Critic::Policy::Variables::RequireNegativeIndices(3pm)NAME
Perl::Critic::Policy::Variables::RequireNegativeIndices - Negative array index should be used.
AFFILIATION
This Policy is part of the core Perl::Critic distribution.
DESCRIPTION
Conway points out that
$arr[$#arr];
$arr[$#arr-1];
$arr[@arr-1];
$arr[@arr-2];
are equivalent to
$arr[-1];
$arr[-2];
$arr[-1];
$arr[-2];
and the latter are more readable, performant and maintainable. The latter is because the programmer no longer needs to keep two variable
names matched.
This policy notices all of the simple forms of the above problem, but does not recognize any of these more complex examples:
$some->[$data_structure]->[$#{$some->[$data_structure]} -1];
my $ref = @arr;
$ref->[$#arr];
CONFIGURATION
This Policy is not configurable except for the standard options.
AUTHOR
Chris Dolan <cdolan@cpan.org>
COPYRIGHT
Copyright (c) 2006-2011 Chris Dolan.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2012-06-07 Perl::Critic::Policy::Variables::RequireNegativeIndices(3pm)