You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Raphaël Piéroni <ra...@gmail.com> on 2007/04/24 21:29:34 UTC

Archetypes - Question about languages and file extensions

Hi

In order to implement the file resolution
during the automatic creation of an archetype,
i need to group the files potential files.

I group the files by:
- files located in directories with tree representation of package
(like in src/main/java/org/apache/... where java is one of the
language used)
- files located in directories without tree representation (files
excluded from the first pass)

I then subgroup those group by:
- files which are binary copied (based on file extension)
- text files excluded from the binary search (files which will be
velocity templates in the archetype).

My questions are:
- apart from java, groovy, aspectj, csharp, what are the common
directory names where files with packaging ability are located?

- which files extension represent text files and which represent
binary files? how to store such a huge list?

Thanks in advance for any answer.

Regards,

Raphaël

Re: Archetypes - Question about languages and file extensions

Posted by Wayne Fay <wa...@gmail.com>.
I found a few artifacts with the word "mime" in them but not sure if
any of these will be helpful...
http://www.mvnrepository.com/search.html?query=mime

Wayne

On 4/24/07, Raphaël Piéroni <ra...@gmail.com> wrote:
> 2007/4/24, Wayne Fay <wa...@gmail.com>:
> > > - which files extension represent text files and which represent
> > > binary files? how to store such a huge list?
> >
> > The mime.types file packaged by Apache webserver might prove useful
> > for file extension/type analysis.
> Is there a jar file including such a list ?
>
> Raphaël
>
> >
> > Wayne
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Archetypes - Question about languages and file extensions

Posted by Raphaël Piéroni <ra...@gmail.com>.
2007/4/24, Wayne Fay <wa...@gmail.com>:
> > - which files extension represent text files and which represent
> > binary files? how to store such a huge list?
>
> The mime.types file packaged by Apache webserver might prove useful
> for file extension/type analysis.
Is there a jar file including such a list ?

Raphaël

>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

Re: Archetypes - Question about languages and file extensions

Posted by Wayne Fay <wa...@gmail.com>.
> - which files extension represent text files and which represent
> binary files? how to store such a huge list?

The mime.types file packaged by Apache webserver might prove useful
for file extension/type analysis.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Archetypes - Question about languages and file extensions

Posted by Raphaël Piéroni <ra...@gmail.com>.
2007/4/25, Brett Porter <br...@apache.org>:
>
> On 24/04/2007, at 9:29 PM, Raphaël Piéroni wrote:
>
> >
> > My questions are:
> > - apart from java, groovy, aspectj, csharp, what are the common
> > directory names where files with packaging ability are located?
>
> Wouldn't this be anything under main/ or test/ ?
src/main/java is packaged
but src/main/webapp is not


>
> >
> > - which files extension represent text files and which represent
> > binary files? how to store such a huge list?
>
> Is it better to instead look at the content of the file to determine
> this? This seems like a good general purpose IO utility if it doesn't
> already exist in another library.

jmimemagic seems to do some work, but i cant see where to find some
usable javadoc on it

I think i will leave those definitions to the user which will provide
-Dlanguages and --Dfiltered
properties with meaningfull defaults.

Raphaël

>
> - Brett
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

Re: Archetypes - Question about languages and file extensions

Posted by Brett Porter <br...@apache.org>.
On 24/04/2007, at 9:29 PM, Raphaël Piéroni wrote:

>
> My questions are:
> - apart from java, groovy, aspectj, csharp, what are the common
> directory names where files with packaging ability are located?

Wouldn't this be anything under main/ or test/ ?

>
> - which files extension represent text files and which represent
> binary files? how to store such a huge list?

Is it better to instead look at the content of the file to determine  
this? This seems like a good general purpose IO utility if it doesn't  
already exist in another library.

- Brett


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org