Using the same files, and the syntax from the SYNOPSIS section of the
man page:


grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new(); say $m->get_mime("1-wrong.html")'
text/plain
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new(); say $m->get_mime("2-wrong.html")'
text/plain
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new(); say $m->get_mime("2-1.html")' 
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new(); say $m->get_mime("2-2.html")'
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new(); say $m->get_mime("2-3.html")'
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new(); say $m->get_mime("2-4.html")'
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new("/etc/magic"); say $m->get_mime("1-wrong.html")'
text/plain
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new("/etc/magic"); say $m->get_mime("2-wrong.html")'
text/plain
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new("/etc/magic"); say $m->get_mime("2-1.html")'   
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new("/etc/magic"); say $m->get_mime("2-2.html")'
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new("/etc/magic"); say $m->get_mime("2-3.html")'
text/html
grove@mary> perl -E 'use File::MMagic::XS; my $m =
File::MMagic::XS->new("/etc/magic"); say $m->get_mime("2-4.html")'
text/html

Reply via email to