Posted in Diari, English Linux, Rails on 04/02/2009 12:08 am by Ton
Hi there
Some of you would remember Railscast script, so I coded a new version using SQLite3.
The new version is this one and the empty database is that one.
Enjoy it
P.S. Remember to rename the empty database file from EmptyRailsCastDownloader.db to RailsCastDownloader.db.
Posted in Diari, Música, Personal on 03/31/2009 11:35 pm by Ton
Hola
Un buen amigo mio (George Mileson) acaba de sacar su segundo disco (autoproducido y autofinanciado al igual que el primero) y lo presenta este viernes en Luz de Gas. Además de este hecho, incluye un tributo a su músico preferido, el Sr Bruce Springsteen como podéis ver en la web del club de fans oficial.
Así que no os lo podéis perder, si os gusta el buén rock tenéis una cita a la que no podéis faltar este viernes dia 3 de Abril a las 22:00 (apertura de puertas a las 21:00) para escuchar a este pedazo de músico que intenta abrirse paso en el difícil mundo de la música con su propio esfuerzo (no como toda esta panda de triunfitos que tienen padrinos y van a lo comercial).
George hace la música que le gusta
Posted in Diari, English Linux, Rails on 03/29/2009 10:08 pm by Ton
Hi
As some of you know, I am coding using the Ruby On Rails framework right now. Apart of this, I am a huge fan of http://railscasts.com/ and I like to watch the screencasts published in it.
Some weeks ago and during four weeks, my internet connection took me back almost to the 56 Kb modem age (my download speed was 100 kbps) and I was not able to watch the published episodes. Years ago I coded a perl script named deb-downloader because I was in a similar situation and I had to upgrade my Debian sid so I decided to code a little ruby script to download all the episodes from wherever I was and watch them at home.
This is the script and it is used for downloading the episodes you don’t have (the episodes already downloaded are stored in a text file and to not be downloaded again). If you like this script, you are free to use it, modify it and distribute it (it is under the GPL license) and even send me suggestions about how to improve it or add new functionalities.
Btw, I have downloaded all the episodes and I’m waiting for the new one (it is usually published every Monday).
Posted in Debian, Diari, English Linux on 02/15/2009 04:08 pm by Ton
Hi
Good news for the open source world. Lenny, the new Debian’s stable version, is out

Read about it here
Posted in Diari, English Linux, Rails on 02/15/2009 02:36 am by Ton
Hi
I wrote an entry some time ago about the one-file SQL engines and I wanted to code an experiment about a website using SQLite3 as database. I coded a little site named http://www.cheatsheetsandrecipes.com and it worked ok, so that was the time to deploy it in my server in production mode.
Once the site was deployed, I spent some days trying to solve a problem with my database queries and finally I found the problem. There is a problem with rails 2.2.2 and sqlite3 version (explained here) which forces me to change to mysql and cancel my experiment because in my workstation sqlite3’s version is 3.5.9 and in my server it is 3.3.8.
Now the web is working with mysql (maybe I’ll change it again with the new debian stable version codenamed ‘lenny’ which is going to be release this weekend if everything works fine) and feel free to provide cheatsheets and recipes.
See you.
P.S. Maybe accessing to http://www.cheatsheetsandrecipes.com doesn’t work. It is because I bought the domain some hours ago and dns are replicating the ip address (be a little patient).
P.S.S. http://www.cheatsheetsandrecipes.com is beta, don’t be cruel with it (it began as an experiment and there are a lot of things to improve).
Posted in Diari on 01/17/2009 12:56 pm by Ton
Hi there
Some days ago, I knew that Euruko 2009 (the european Ruby conference) will be placed in Barcelona next May 9-10th. Some days ago too, I joined to Barcelona On Rails group and we will started a working group to help to the Euruko 2009 to be the best one done ever
Next week I will know personally (if I can go to the meeting) the BarcelonaOnRails members (although I think I already know one of them).
If you are a rubyist and you want to do things to help this meeting, join to Barcelona On Rails group (I’ll do whatever I can to help).
Posted in Diari, English Linux on 12/28/2008 08:14 pm by Ton
Hi there
After a long time without writing anything, I have decided to write this post to thank to all wordpress people the efforts done to publish this fantastic software.
I’ve upgraded this blog from 2.3.1 to 2.7 and what I have had to do are:
- Execute my wordpress database backup script.
- Untar latest.tat.gz in my apache directory.
- Copy the wordpress themes used in the new version.
- Copy the uploaded files.
- Change the blog link from the old version to the new one.
- Access to my blog after upgrading.
- Click the link to upgrade my database structure.
e voilà!!!!
Isn’t it amazing
Posted in Diari, English Linux, Rails, Variats on 10/12/2008 07:22 pm by Ton
One of the things done when a web application is done is collect the HTTP information contained in the request. I did some things in PHP5 and there was (and is) an environment variables named ‘$_SERVER’ which contained information collected by the web server about the request.
In rails, there is the array named ‘request.env’ which contains a lot of items with the http request information, for instance if you want to get the client ip address or the browser used you can use the sentences ‘client_ip = request.env["REMOTE_ADDR"]‘ and ‘client_browser = request.env["HTTP_USER_AGENT"]‘.
A list of what is retrievable is :
- SERVER_NAME
- PATH_INFO
- REMOTE_HOST
- HTTP_ACCEPT_ENCODING
- HTTP_USER_AGENT
- SERVER_PROTOCOL
- HTTP_CACHE_CONTROL
- HTTP_ACCEPT_LANGUAGE
- HTTP_HOST
- REMOTE_ADDR
- SERVER_SOFTWARE
- HTTP_KEEP_ALIVE
- HTTP_REFERER
- HTTP_COOKIE
- HTTP_ACCEPT_CHARSET
- REQUEST_URI
- SERVER_PORT
- GATEWAY_INTERFACE
- QUERY_STRING
- REMOTE_USER
- HTTP_ACCEPT
- REQUEST_METHOD
- HTTP_CONNECTION
Something simple, as everything contained in RoR
Posted in Diari, English Linux, Programació on 09/27/2008 01:49 pm by Ton
Hi
As some of your know, I am using Ruby on Rails (RoR) to develop web applications. Some time ago I read this post in the ‘Ruby On Windows‘ blog about coding Ruby and RoR using this IDE (although I think that all this effort done by the Sun boys is with JRuby in mind, not thinking in Ruby itself.
Leaving this ‘little’ detail apart, Netbeans is a good IDE (open-source and free) to code using Ruby and RoR with syntax highlight, code completion and indentation, css preview and other useful features (more info here) contained in it (and it runs on Windows, Linux, Mac OS X and Solaris).
It is available here.
Posted in Diari, English Linux, Programació on 09/26/2008 07:19 pm by Ton
Things done from time to time tend to be forgotten.
This is one of these things
GRANT ALL PRIVILEGES ON db_name.* TO 'user'@'%'
IDENTIFIED BY 'some_pass' WITH GRANT OPTION;
Creating a new user with all privileges on a database.