9th Rubykai in Osaka Notes

Posted by stoyan Mon, 13 Mar 2006 03:17:00 GMT

To test the new wiki , i put there my notes from the 9th Ruby meeting in Osaka previous week. Interesting: now I can easy move pages between wiki, when they are work in progress and the typo pages, when they are finished.

Posted in Programing, Ruby | no comments

One ring to lead them all...

Posted by stoyan Wed, 08 Mar 2006 13:13:00 GMT

It’s not about famous The Lord of the Rings movie. It’s about increasing the performance via using the unified tools. What I’m talking about:

  • My everyday usage programming language of choice is Ruby
  • My web applications are in Ruby: Ruby On Rails
  • I hope my GUI programming will be in Ruby: RubyCocoa
  • My automation tools are in Ruby: Rake (building), Capistrano (deployment)
  • My web templates are in Ruby: eRb

The same is true for my online tools (the markup I’m using for creating the content):

All this make me productive (I hope, better ask my boss ;) )

Posted in Programing, SysAdmin, Ruby | no comments

LightS5

Posted by stoyan Tue, 07 Mar 2006 02:29:00 GMT

For the Second Rails meeting in Osaka I needed to prepare some slides for my presentation. Usually there is no projector there, but we have network, so I thought it will be good everybody to access slides with their own browser. Before I used the great S5presents open-source web-based slideshow application. I even made some modifications to it.

For the current presentation I wanted to use one of the OpenBlockS boxes we have around. So I installed Debian 3.1 (document is in japanese) on it, added ruby and rubygems . The problem was, that the box come with only 64MB RAM, that’s why I needed a light versions for all software.

For the web server I wanted to use lighttpd or Mongrel . The latest require ruby-1.8.4 and also there was no lighttpd .deb in Sarge, so I dist-upgraded to Debian Etch.

Next was the problem with the database. s5presents using MySQL for database, but the box was to weak to handle it. As a result I rewrote the whole stuff to use SQLite3 . It fact it’s pretty cool – now I have my presentations in addition to the code added to the subversion repository. I can checkout and use them without need to do some database dump/restore.

For the slides s5presents using markdown by default, but I prefer Textile (warning: rebel inside). So I added Textile and RDoc support.

Finally I moved the whole installation to my notebook (hahahaha, work for nothing a ;) ), but the LightS5 code become pretty good, so I decided to continue working on it. The result:

(WARNING: be sure after checkout to create the db/s5.db if missing:
$ cd db
$ sqlite3 s5.db < s5.sqlite3
BEFORE using the application)

The Multiusers version is running online (Thanks to William for the great hosting he gave me for free ) and there is also Trac for bugs reports and requests .

Pretty hard job only for one rails meeting a ;)

Posted in Programing, Ruby | no comments

Ajax Scaffold Generator

Posted by stoyan Wed, 01 Mar 2006 05:10:00 GMT

Ajax Scaffold Generator (for Ruby on Rails) creates a scaffold page like the typical rails one, except adding, editing and deleting are all done inline. The generated scaffold is valid XHTML strict and fully styled right out of the box…

The demo and howto are also available. Be sure you have no JavaScript disabled in your browser (NoScript in Firefox)

Posted in Ruby, Programing, Ajax | no comments

Ackbar, KirbyBase, and Rails

Posted by stoyan Tue, 21 Feb 2006 02:38:00 GMT

Intreresting stuff:

In general: if you have Ruby, you can have Rails too, no need to install some special database, webserver etc. Pure Rails :)

Posted in Programing, Ruby | no comments

Optimizing Rails Resource Usage

Posted by stoyan Sun, 19 Feb 2006 07:41:00 GMT

Found via Rails Tips , link point to TextDrive weblog

  • Minimize the amount of FCGI listeners
  • Use caching
  • NEVER run “development” on FastCGI for more than 1-2 hours
  • Observe your memory consumption
  • Rotate your logs
  • Write and run unit tests
  • Check for memory leaks when you are developing
  • Be careful with iterations
  • Watch the Rails TRAC for bug reports
  • Be vigilant when restarting your server

Use RailsHelp for quick searching through the Rails API docs.

Posted in Programing, Ruby | no comments

Stylish your code

Posted by stoyan Fri, 10 Feb 2006 17:58:00 GMT

Rules for better Rails programming :

  • Two spaces, no tabs
  • Blocks use { }, if they are one-liners, otherwise do … end
  • Surround equal signs with spaces, @myvar = ‘foo’, not @myvar=’foo’
  • Surround hash assignments with spaces, :foo => ‘bar’, not :foo=>‘bar’
  • Class.method(my_arg)—not method( my_arg ) or method my_arg

Posted in Programing, Ruby | no comments

New Books

Posted by stoyan Mon, 06 Feb 2006 05:24:00 GMT

We have some new books :) (still PDF only)

 

Posted in Ruby, Programing | no comments

Globalize (i18n for Rails)

Posted by stoyan Thu, 02 Feb 2006 01:02:00 GMT

Some people on the Rails ML was worried what’s happend to the Globalize plugin . It’s not dead, just moved to another home.

Planet Aragon has been using Globalize for a few months now on a few client projects that require support for ~30 languages … It’s a really clean way to integrate i18n into your application without cluttering it. It even works in PostgreSQL!

Posted in Programing, Ruby | no comments

Mongrel HTTP Server

Posted by stoyan Wed, 01 Feb 2006 17:59:00 GMT

A small fast HTTP server written in (mostly) Ruby that can be used to host web frameworks directly with HTTP rather than FastCGI or SCGI.

Examples already working with Camping .

See also: Mongrel RDoc pages

Posted in Programing, SysAdmin, Ruby | no comments

Older posts: 1 2 3 4 5 6 ... 9

Powered
Ruby Blogs Directory
Performa
Box.net Refer