# The Well Tempered Ruby Application

**URL:** <https://www.ruby-forum.com/t/the-well-tempered-ruby-application/68632>\
**Category:** Ruby\
**Created:** [September 14, 2006, 1:18am UTC](https://www.ruby-forum.com/t/the-well-tempered-ruby-application/68632 "2006-09-14T01:18:48Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![tbobker](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/73ab20/32.png) [@tbobker](https://www.ruby-forum.com/u/tbobker)\
**Post date:** [September 14, 2006, 1:18am UTC](https://www.ruby-forum.com/t/the-well-tempered-ruby-application/68632/1 "2006-09-14T01:18:48Z")

</div>

Hi,

I’ve been starting to put together a small sample project like GNU’s  
“Hello” ([Hello - GNU Project - Free Software Foundation](http://www.gnu.org/software/hello/)) that provides just the  
framework of everything that a well behaved Ruby project should  
contain. The project should serve a dual role of providing a template  
for new projects and as a tutorial. I’ve done some cursory searching,  
but I haven’t found anything.

Some of the issues that I think should be addressed in such a sample  
application.

- directory structure
- files to require in a distribution (license, readme, samples)
- code style (tricky), version control usage
- comments, documentation, rdoc
- handling platform specific issues, native extension
- unit tests
- handling command line args, usage
- being a well behaved library
- distribution, rakefile, package format, gem, resolving dependancies.
- version control
- register the project: rubyforge, raa, sourceforge, anouncements here.

Does anyone know of a similar project, or would be interested in  
providing some input? Or even suggest some particularly nice  
real-world projects that can be used for inspiration.

So far, I’ve put together the basic structure of a project and have  
started filling it with some life, mainly a longish README and a well  
documented Rakefile containing basic tasks like `rdoc` and `package`.

Download here: [http://rubyforge.org/frs/?group\_id=2203](http://rubyforge.org/frs/?group_id=2203)  
or take a look at the generated docs here: [http://hello.rubyforge.org/](http://hello.rubyforge.org/)

I appreciate your feedback, thanks,  
-tim

Sorry for crossposting, I thought this might not only be of interest  
for ruby-doc.

---

<div class="post-metadata">

**Author:** ![tbobker](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/73ab20/32.png) [@tbobker](https://www.ruby-forum.com/u/tbobker)\
**Post date:** [September 14, 2006, 6:15pm UTC](https://www.ruby-forum.com/t/the-well-tempered-ruby-application/68632/2 "2006-09-14T18:15:20Z")

</div>

Tim B. wrote:

> Hi,
> 
> I’ve been starting to put together a small sample project like GNU’s  
> “Hello” ([Hello - GNU Project - Free Software Foundation](http://www.gnu.org/software/hello/)) that provides just the  
> framework of everything that a well behaved Ruby project should  
> contain. The project should serve a dual role of providing a template  
> for new projects and as a tutorial. I’ve done some cursory searching,  
> but I haven’t found anything.

i haven’t used this, but it’s relevant enought to be not OT,

> **[Pycheese | Aplikasi Dan Informasi Terupdate](https://www.pycheesecake.org/)**
>
> Aplikasi dan informasi terupdate

---

<div class="post-metadata">

**Author:** ![tbobker](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/73ab20/32.png) [@tbobker](https://www.ruby-forum.com/u/tbobker)\
**Post date:** [September 14, 2006, 6:15pm UTC](https://www.ruby-forum.com/t/the-well-tempered-ruby-application/68632/3 "2006-09-14T18:15:22Z")

</div>

Tim B. wrote:

> Hi,
> 
> I’ve been starting to put together a small sample project like GNU’s  
> “Hello” ([Hello - GNU Project - Free Software Foundation](http://www.gnu.org/software/hello/)) that provides just the  
> framework of everything that a well behaved Ruby project should  
> contain. The project should serve a dual role of providing a template  
> for new projects and as a tutorial. I’ve done some cursory searching,  
> but I haven’t found anything.

(rooting around in my bookmarks)

There’ve been different approaches to cyclomatic complexity, fan-in and  
out type metrics for ruby

[http://blog.zenspider.com/archives/ruby/parsetree/index.html](http://blog.zenspider.com/archives/ruby/parsetree/index.html)  
(search “abc.rb”)

[http://eigenclass.org/hiki.rb?call+graphs](http://eigenclass.org/hiki.rb?call+graphs)  
[http://eigenclass.org/hiki.rb?Lexical+complexity+in+Ruby](http://eigenclass.org/hiki.rb?Lexical+complexity+in+Ruby)  
[http://saikuro.rubyforge.org/](http://saikuro.rubyforge.org/)

also found this in delicious, it’s for Javascript but very interesting,

[http://wing.comp.nus.edu.sg/publications/2006/ipm06lu.pdf](http://wing.comp.nus.edu.sg/publications/2006/ipm06lu.pdf)

---

<div class="post-metadata">

**Author:** ![tbobker](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/73ab20/32.png) [@tbobker](https://www.ruby-forum.com/u/tbobker)\
**Post date:** [September 18, 2006, 1:52am UTC](https://www.ruby-forum.com/t/the-well-tempered-ruby-application/68632/4 "2006-09-18T01:52:42Z")

</div>

It seems to me that any good framework should take into account the  
possibility of running multiple applications using the famework IMHO  
this is one area where rails is severely deficient.

I would start with the rails framework because it covers so many  
bases. With any application you will need a lib, configuration, logs,  
tests etc and rails has all of that covered. I am also thinking that  
virtually every application worth writing will need some sort of  
database access even if it’s via sqlite so once again rails rulez  
there. Same with emails.

So think of a super rails hierarch. There is a top level domain where  
libraries, gems, logs, and configuration go. Inside there is a  
directory for each appliation with it’s own logs, configurations etc.  
The lower levels override the upper ones (uless there is some sort of  
a no override flag?).

Maybe some OS specific stuff too like gems/win32 and gems/linux so the  
binaries get sorted right too.

Mmmmm… Looking a bit like Zope isn’t it?
