Hi,
I want to get a Line count of a file and append that at the end of the file. The Line count should not include the Headers :
------------------
COL1,COL2,COL3
123,abc,011
111,abd,0212
Record Count: 2
-------------------
Thanks. (7 Replies)
leviathan:/lcl/apps/Tivoli/netcool/omnibus/bin>more pmonfile.dat
entp_stdby
ot1p_stdby
lawp_stdby
I am wonder how to remove the _stdby from all the values in this dat file using #!/bin/ksh
Thanks! (4 Replies)
Hi,
I have a file where I need to count the total for the first element and put it back at the end of file...
here is the example...
input..
FHDR|ABC|20100607|
|ABC|8453|CDE|E166||||
123|ABC|8453|CDE|E166||||
123|ABC|8453|CDE|E166||||
111|ABC|8453|CDE|E166||||... (8 Replies)
Hi
I have the following info in a file -
<Cell id="25D"/>
<Cell id="26A"/>
<Cell id="26B"/>
<Cell id="26C"/>
<Cell id="27A"/>
<Cell id="27B"/>
<Cell id="27C"/>
<Cell id="28A"/>
I would like to know how would you go about counting all... (4 Replies)
I am looking help in awk, quick overview. we will get feed from external system . The input file looks like below.
Detail Id Info Id Order Id STATUS Status Date FileDetail
99127942 819718 CMOG223481502 PR 04-17-2011 06:01:34PM... (7 Replies)
Hi All,
test file
Begin Script Run at Thu Mar 14 09:24:16 PDT 2013
tst_accounts: ws zip: WS_out_20130313.tar.gz dat: test_20130313.dat count: 63574 loaded: xx pre-merge: xx post-merge: xx timestamp: Thu Mar 14 09:30:42 PDT 2013
tst_accounts: ws zip: WS_out_20130313.tar.gz dat: s_20130313.dat... (6 Replies)
Hello fellow awkers and seders:
need to figure out a way to ensure a software deployment has completed by checking its trace file in which I can store the deployment results as follows:
echo $testvar
===== Summary - Deploy Result - Start ===== ===== Summary - Deploy Result - End =====... (1 Reply)
Hi I have a file with contents like :
101,6789556897,0000795369 - seq - fmt_recs187] - avg_recs
101,4678354769,0000835783 - seq - fmt_recs98] - avg_recs
221,5679787008,0001344589 - seq - fmt_recs1283] - avg_recs
I need to find the sum of the all the values (which are in bold).
here... (6 Replies)
Hi guys,
I have to append the word count of a file at the end of the file name like this - > "filename_2345" where 2345 is the word count of "filename". How do i achieve this using one command ? I am not allowed to store the word count in a variable and then concatenate. Request your... (1 Reply)
In the below perl I am trying to extract and print the values AF1=, the GT value, and F or QUAL diveded by 33 (rounded to the nearest whole #). The GT value is at the end after the GT:PL so all the possibilities are read into a hash h, then depending on the value that is in the line the... (1 Reply)
Discussion started by: cmccabe
1 Replies
LEARN ABOUT DEBIAN
file::type::webimages
File::Type::WebImages(3pm) User Contributed Perl Documentation File::Type::WebImages(3pm)NAME
File::Type::WebImages - determine web image file types using magic
SYNOPSIS
use File::Type::WebImages 'mime_type';
my $type_1 = mime_type($file);
my $type_2 = mime_type($data);
DESCRIPTION
"mime_type()" can use either a filename, or file contents, to determine the type of a file. The process involves looking the data at the
beginning of the file, sometimes called "magic numbers".
THE BIG TRADE OFF
For minimum memory consumption, only the following common web image file types are supported:
BMP, GIF, JPEG and PNG. ( image/bmp, image/gif, image/jpeg and image/png ).
Unlike with File::Type and File::MMagic, 'undef', not "application/octet-stream" will be returned for unknown formats.
Unlike File::Type, we return "image/png" for PNGs, not "image/x-png";
If you want more mime types detected use File::Type or some other module.
TODO
It would be even better to have a pluggable system that would allow you to plug-in different sets of MIME-types you care about.
SEE ALSO
File::Type. Similar, but supports over 100 file types.
ACKNOWLEDGMENTS
File::Type::WebImages is built from a mime-magic file from cleancode.org. The original can be found at
<http://cleancode.org/cgi-bin/viewcvs.cgi/email/mime-magic.mime?rev=1.1.1.1>.
AUTHORS
Paul Mison <pmison@fotango.com> - wrote original File::Type Mark Stosberg <mark@summersault.com> - hacked up this.
COPYRIGHT
Copyright 2003-2004 Fotango Ltd.
LICENSE
Licensed under the same terms as Perl itself.
perl v5.10.1 2011-04-23 File::Type::WebImages(3pm)