valibuk.net

A place for opinions and notes of a valibuk.

Slovak Ruby and RoR fans will meet in Bratislava on April 25

Tagged with: — ondrej at 8:24 am on Thursday, April 23, 2009

Slovak Ruby and Ruby on Rails fans will meet in Bratislava on April 25, 2009. For more details see the Slovak Ruby on Rails site or directly the post about the meeting [all in Slovak].

Ruby on Rails, Capistrano, Mongrel and nginx on Gentoo

Tagged with: — ondrej at 1:25 am on Thursday, August 30, 2007

Ruby on Rails A few months ago I wrote quite popular :) manual how to install and use RoR, Capistrano and Mongrel with Apache on Gentoo. Things changed a little as the time goes and after some experiences with the nginx server on a Slicehost slice, I decided to write an updated manual and to use the nginx server instead of the Apache HTTP Server. Let’s start :)

A deployment process should be straightforward and automatic as much as possible. The main reason is that this process will be repeated many times and omitted or wrong steps usually cause hey-what-are-you-doing-the-site-does-not-work calls or e-mails from your customers. Fortunately, there is a nice tool for Ruby on Rails applications — Capistrano.

Larry the CowNow we know about a tool to automate the deployment of an application, but we need to deploy our application to a production environment — I decided for the combination of Mongrel and nginx.

…and everything runs on Gentoo :)

Here is my short howto:
(There is more where this came from … )

Focus On Form Element

Tagged with: — ondrej at 3:34 pm on Sunday, August 19, 2007

Ruby on Rails Ruby on Rails supports forms very comfortably: generating a form from a model, updating data of a model or validating input values. But I always missed one functionality: to set a focus on an element.

It is quite frustrating: a form shows in your browser, you start typing and you are overwriting the actual URL or you are typing to a quick find box. Well, it is my fault, because I did not check if the text cursor | is blinking in one of the form input boxes, so then I click to a wanted input box and, finally, I am typing to the right box :)

But there is a way how to save a movement with a mouse and one mouse click: to set the focus on one of the form elements. (Btw. you can also use the Tab key, but I need to press it 4-times to get to the first input box on a form in my Firefox. Surprisingly, I do not use this way so often. :)

(There is more where this came from … )

Ostrava On Rails - Talk / Prezentácia

Tagged with: — ondrej at 1:31 am on Saturday, June 23, 2007

Ruby on Rails I will give a talk about localisation (localization, l10n) and internationalisation (internationalization, i18n) in Ruby on Rails applications on the Ostrava on Rails conference on 23. June in Ostrava, Czech republic. I am looking forward to meet you there :)

Slides and examples will be available here after the conference, probably on Sunday.

Budem mať prednášku o lokalizácii (aby to pekne po našom :) a internacionalizácii (či podpore viacerých jazykov) v Ruby on Rails aplikáciách na konferencii Ostrava on Rails, ktorá sa koná 23. júna v Ostrave. Teším sa na stretnutie…

Prezentácia a príklady budú prístupné po konferencii, pravdepodobne v nedeľu.

O pár hodín vstávam aby som stihol byť v Ostrave ráno…

Ostrava On Rails

Tagged with: — ondrej at 9:27 pm on Monday, May 14, 2007

Ruby on Rails With a great pleasure I read about a Ruby On Rails conference in Ostrava, Czech Republic on 22 - 23 June. Time permitted, I would like to be there. Well, at last something is happening, although we still do not have meetings of Ruby on Rails fans in every bigger city :)

S potešením som sa dozvedel o Ruby On Rails konferencii v Ostrave, ktorá sa koná 22 a 23 júna. Dúfam, že sa mi podarí nájsť si čas a zájdem tam. Konečne sa niečo deje, hoc máme ešte stále ďaleko od zrazov RubyOnRails-istov v každom väčšom meste :)


Ostrava on Rails

P.S.
Keď tak premýšlam, bol by záujem o niečo také v Bratislave?

Generating PDF With Another Encoding

Tagged with: — ondrej at 12:42 am on Thursday, March 8, 2007

Ruby on Rails A PDF document is a favourite way how to display and store a view on data, sometimes called as a report. Of course, your Ruby On Rails application can display data in a very nice form, but definitively a PDF document is a way how to store a report. Actually, it is one of the most wanted ways.

There is a nice page How to Generate PDF in Ruby on Rails that describes different frameworks for generating a PDF document in RoR.

Everything seems be fine, shiny… But did you try to generate PDF with a different encoding then ISO-8859-1? Well, maybe you know, maybe not, but there are also another languages and some of them use also special small funny waves or lines under or above (sometimes also on the sides of) a letter. Experts may call them acute, wedge or umlaut. But in the computer world, we can simply call them: complications.

So, are you a lucky person that should to put to a report words like čučoriedka?
(There is more where this came from … )

How To Handle Model In Module?

Tagged with: — ondrej at 10:53 pm on Sunday, February 4, 2007

Ruby on RailsThe number of models in your Ruby on Rails application is growing and one day you will get a brilliant idea.. Let’s put them to modules (that is to different subdirectories in the modules directory). Well, I had this day some weeks ago and, honestly, it is not a good idea… Helpers and tools in RoR, that work without any problems and manual changes when models do not use modules, will require some manual changes to work.

(There is more where this came from … )

One Model With acts_as_list and acts_as_tree

Tagged with: — ondrej at 8:49 pm on Sunday, February 4, 2007

Ruby on Rails Ruby on Rails provides nice ways to create a list (acts_as_list), that is to keep order of items, and to create a tree (acts_as_tree), that is to organise items with parent–children relationships. But what to do, if you need both functionalities at once?

My model has name Outline and it holds one textual information.

(There is more where this came from … )

Rails, Capistrano, Mongrel and Apache (with SSL) on Gentoo

Tagged with: — ondrej at 2:25 am on Monday, January 8, 2007

Ruby on Rails
There is a happy occasion in the development of an application — deployment. Users will use it, you will receive (hopefully) some money, there will be some bugs.. well, maybe not so happy occasion.. ;>
In most situations you will have to repeat a deployment process several times (bug fixes, new features, etc.). Maybe the process is not very complicated, but an automation will minimise possible mistakes such as typos or omitted commands.
Fortunately, there is a nice tool for Ruby on Rails applications — Capistrano.

Larry the CowNow we know about a tool to automate the deployment of an application, but we need to deploy our application to a production environment — I decided for the combination of Mongrel and Apache.

…and everything runs on Gentoo :)

Let’s start — here is my short howto:
(There is more where this came from … )

Podpora slovenčiny i s triedením v PostgreSQL a Ruby on Rails

Tagged with: — ondrej at 5:33 pm on Friday, October 13, 2006

Ruby on RailsAk používate PostgreSQL databázu a radi by ste slovenké písmenká i triedenie mali, nasledujúci návod vám k tomu pomôže.

Keďže používam Gentoo distribúciu, uvediem aj kroky potrebné pre úspešné používanie slovenčiny na tejto distribúcii.

A ako posledné si ukážeme, ako to všetko použiť v Ruby on Rails.
(There is more where this came from … )

Next Page »