[Nitro] Default dir structure
rob
rob at motionpath.com
Wed Jan 4 14:56:29 EST 2006
It is good to retain the flexibility to choose different directory
structures as peoples tastes and conceptions vary and some projects
are naturally more complex than others and thus require greater
division into categories to make them manageable. The /src directory
could go in most cases but I have played and end up putting it back
after a while as I prefer the additional level of visual segmentation
for all but mini projects. For what it's worth our projects often
start out similar to this (which would definitely be cluttered rather
than useful for a smaller project):
/conf/*
/conf/main.yml # sample configuration file for use by application
/conf/debug.rb
/conf/stage.rb
/log/*
/public/css/*
/public/js/prototype.js # the well known handy javascript library
/public/js/*
/public/images/*
/public/*
/run.rb
/scripts/generate_rdoc.rb # i do not expect most people would want this
/scripts/*
/src/models/*
/src/views/*
/src/views/main/index.xhtml # bare-bones template
/src/views/main/*
/src/controllers/main.rb # bare-bones controller
/src/controllers/*
/src/elements/*
/src/elements/generic.rb # bare-bones element
/src/lib/*
My opinion is that the user should be given a multiple-choice with
each template assigned as being suitable for a different sized
(small,medium,large,etc) as one consideration and the users like or
dislike of folders as another consideration. Other things the
generator should do is offer the user multiple choices about which
store to use (creates the conf files), how things such as the
compiler pipeline car constructed and if Nitro is to be included into
the default namespace. Extra swish touches could be options to
include a shebang in run.rb, say between "/where/is/bin/env ruby" and
"/where/is/bin/ruby" I have a rudimentary implementation of this that
we use to start our own projects but do not think it would be
generally useful as it is heavily tied-in to our own systems and is
console interactive only. Something I have considered is that it
would be fun although a little time consuming to construct a GTK
toolkit that allows you to draw our your nitro application with
controllers, models, etc linked visually and a skeleton source code
is produced for you. While this is unlikely to happen, a Nitro
application with selector boxes (or javascript widgets but then you
may have well as used GTK) that allow you to visually do the same. If
someone is has time on their hands, there is a great project for you!
Create a visual construction kit for the innovative and intelligent
ruby web development framework. We would even need a new acronym RRAD
(rocket-rapid application development/really rapid application
development) perhaps. Or better yet, NRAD - Nitro-Rapid application
development....
- rp
On 3 Jan 2006, at 11:11, George Moschovitis wrote:
> BTw,
>
> I mean the USERS application dir. And this is only the suggested dir.
> Unlike Rails you can use any dir structure you need for Nitro
> applications.
>
> -g.
>
> On 1/3/06, Yvon Thoraval <thoraval.yvon at free.fr> wrote:
>>
>>
>> Le 3 janv. 06 à 11:32, George Moschovitis a écrit :
>>
>>
>> What do you think about this one:
>>
>>
>>
>>
>> run.rb
>>
>> controller.rb
>>
>> model.rb
>>
>> template/*
>>
>> public/*
>>
>> log/*
>>
>>
>> i do agree, their is no needs of a subdir src...
>>
>>
>> Yvon
>>
>>
>>
>> _______________________________________________
>> Nitro-general mailing list
>> Nitro-general at rubyforge.org
>> http://rubyforge.org/mailman/listinfo/nitro-general
>>
>>
>>
>
>
> --
> http://www.gmosx.com
> http://www.navel.gr
> http://www.nitrohq.com
>
> _______________________________________________
> Nitro-general mailing list
> Nitro-general at rubyforge.org
> http://rubyforge.org/mailman/listinfo/nitro-general
More information about the Nitro-general
mailing list