application/x-perl vs text/x-perl

Clarence Dang dang at kde.org
Sun Apr 13 15:04:42 BST 2003


On Fri, 11 Apr 2003 01:03 am, David Faure wrote:
> On Thursday 10 April 2003 16:42, Scott Wheeler wrote:
> > On Thursday 10 April 2003 16:39, Clarence Dang wrote:
> > > Hi,
> > >
> > > Does anyone know the difference between these 2 mimetypes?  A "Perl
> > > Program" is also a "Perl Source File" after all...I don't see the need
> > > for a distinction between the two, nor the distinction itself.
> > >
> > > And to make things worse, they have overlapping patterns:
> > > application/x-perl: Patterns=*.pl;*.perl;
> > > tex/x-perl: Patterns=*.pl;*.pm;
> >
> > The key is in the last line.  .pm == Perl Module != Perl program.  A .pl
> > is often also a Perl 4 style collection of fucntions with no "main".  So,
> > potentially these two could be consolidated into "Perl Source File" but
> > not the other way around.
>
> Yes but we definitely can't have the same pattern (*.pl) in two mimetypes.
>
> The shared mime database on freedesktop.org only defines application/x-perl
> BTW: freedesktop.org.xml:  <mime-type type="application/x-perl">
>
> with
>     <glob pattern="*.pl"/>
>     <glob pattern="*.perl"/>
>
> (and magic looking at the first line)
>
> *.pm could be application/x-perl-module IMHO.
So is this patch ok?  Scott?
Disclaimer: I know absolutely nothing about PERL (atm, anyway) - I'm just 
interested in getting rid of conflicting patterns.

BTW, does anyone know how I can get "cvs diff" to respect -N...I tried "cvs 
remove"'ing and "cvs add"'ing the various files (without "cvs commit" of 
course) but "cvs diff -N" still wouldn't do it.

Clarence

-------------- next part --------------
A non-text attachment was scrubbed...
Name: perl-module-mime.patch
Type: text/x-diff
Size: 4625 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20030414/3cac57ca/attachment.patch>


More information about the kde-core-devel mailing list