« February 2006 | Main | April 2006 »

March 28, 2006

Not Reboot 8.0, but ReBorn 2.0

A friend of mine mentioned Reboot 8.0 is coming up, and having attended Reboot 7.0 (and liked it a lot) he asked me if I was going.

My answer is that I'm going to ReBorn 2.0, because my second son will arrive more or less by that time.

A new son is probably the best closed source program I ever been part of.

Have fun, all of you going!

Technorati Tags:

March 18, 2006

Jingle

A quick note to point out that version 0.3 of libjingle is out. As far as I can see, the major change is the inclusion of a lite version of the media component used by Google Talk.

Technorati Tags: , , , ,

SCM systems again

I've been using darcs with some success on my personal projects for more than a year now.

The good thing about darcs is that it's very easy to start using, and some features, like the interactive record (commits for those using other SCMs), are extremely powerful.

I also had some problems with it, specially with large repos. It's getting a lot better but still, sometimes, with specific patches, it takes as long time to merge changes between repos.

In the last year, I've also started using Trac a lot, even with darcs, as I mentioned before. This is probably the best system I ever used to keep the code, wiki, bug tracking and project management all integrated, and I like so much that in the last months I've been pushing his use at work also. We now use it to manage two big projects with a Subversion repository, and it's been great. Several other projects there are also moving to Trac.

This push at work to use Trac + Subversion, and the problems with darcs that I have with two of my bigger repositories made me look around again, re-evaluating my choices.

I would love to keep the interactive record capabilities of darcs, but I also don't like using too many systems at once. Also Trac is starting to support other SCMs (Mercurial is in the trunk, a plugin for Trac to support darcs is also in the works in a separate repository, also written by Lele Gaifax), so I should be able to switch to another (well, at least Subversion or Mercurial) SCM without too much problems.

Mercurial is nice, but that would be yet another one to master, so I looked at Subversion as my SCM of choice for my projects. Unfortunately, it's a centralized design, and I want a distributed SCM for my pet projects because I do a lot of work offline and like to commit in small change-sets, and because having several remote mirror repositories is an excellent backup tool.

Enter svk.

svk its a decentralized version control system that uses the Subversion filesystem as its base, but then adds loads of other features that darcs already has. Also it allows you do mirror remote Subversion repositories (like the ones I have at Sapo), and work offline on them.

To start with svk, read the svk workflow explanation by Bieber Labs, It's probably the best one I've seen until now, and it will help you understand the rest. Then install svk, and read the output of svk help intro. The organization describes is much better than the ones you'll find in the wiki.

Then read through the wiki, the faq and other documentation (you still feel lost). There is also an excellent svk visual guide by Russell Brown.

After the intro, and a bit of browsing, I was able to mirror all the Subversion repositories I use on daily basis with no work at all.

There is also a nice tutorial on how to import darcs repos into svk, in case I need that.

The only think I'm missing is the incremental record feature of darcs, really. But good news: its on the roadmap for version 2.0.

As a bonus, for those old, very old repos still in CVS, apparently svk can also mirror them, although that feature seems broken for now. If I can make that work, even old CVS repos will be united under the same tool.

So I'm switching to svk for now. It might allow me to cut back on the number of systems I have to work on a daily basis to just one, if all goes well, but just using the same tool at work and on my projects will be a great time saver.

I'll keep you all posted on how this goes.

Technorati Tags: , , , , , ,

March 17, 2006

Lighttpd + MT 3.2 + PHP + Fast CGI

After battling with lighttpd and friends for a couple of hours, I finally have a very cool setup for this site.

I use the Moveable Type software to publish this articles. I modified the templates to publish each zone of the site in a separate HTML file. Then I use PHP to include them all in the final result. This allows me to generate the right hand-side column just once, as a index template, and include it on all the other articles.

So even if you go an see an old article, you'll still see my current right hand-side column.

In the past few weeks, though, Apache has been burning a lot of memory with all the traffic we've been getting on the several sites that are housed here. So I wanted to test another server, single threaded, and try to use FastCGI to reduce memory usage.

So after a PHP recompilation (use this page as an how-to) and some tweaking, I have a setup that works. I need to tune the other sites before moving to lighttpd but for now it looks and feels great.

My final configuration file looks something like this:

$HTTP["host"] == "www.simplicidade.org" {

  server.indexfiles    = ( "index.html" )

  $HTTP["url"] =~ "^/notes/?(.+\.html)?$" {
  fastcgi.debug        = 0
  fastcgi.server       = (
      "/" => ( (
          "socket" => "/path/to/site/simplicidade.org/fcgi.socket",
          "bin-path" => "/path/to/bin/php",
          "min-procs" => 1,
          "max-procs" => 1,
          "bin-environment" => ( 
              "PHP_FCGI_CHILDREN" => "4",
              "PHP_FCGI_MAX_REQUESTS" => "1000"
          ),
          "bin-copy-environment" => (
              "PATH", "SHELL", "USER"
          ),
          "broken-scriptfilename" => "enable"
      ) )
    )
  }
}

The $HTTP["url"] match makes sure that only files with the HTML extension will be processed by FastCGI, leaving all the images and CSS to lighttpd static file engine, which is very fast.

I also don't use the min-procs/max-procs settings for now. They seem broken to me because lighttd will always start max-procs no matter what I do. I think I'm missing something from the documentation.

Anyway, I'll move the other sites to similar setups and then I'll switch DNS to the new IP address with all this sites on lighttpd.

Technorati Tags: , , , ,

March 13, 2006

Starting a new day with a smile

Rui hates mondays. I know what he means, but given that monday is one of my days off, I don't hate them myself. I'm more a Tuesday-hater myself.

So, to make him and all those monday-o-fobics out there smile at least once today, listen to the blind man.

Programming in Python will make your girlfriend happy

The subject says it all, really.

I think Pedro is on to something here.

Technorati Tags:

March 11, 2006

Lisbon.pm: tech meeting and a new course

Last thursday we had another technical meeting of the Lisbon.pm group. It was a great success, with 29 people attending.

There where three presentations: one by João Gomes about Catalyst, another by me about POE with an example of process control, and the last one by Miguel Duarte about when not to use Perl, which was, as you can expect, a hot topic.

If you are interested in Perl and live or work around Lisboa, please join our mailing list (instructions can be found at the Lisbon.pm website).

The meeting was organized by José Castro, and the space (and first round of drinks afterwards) was sponsored by Log. Kudos to them both.

I've been the Lisbon.pm leader for some time now, and since the reactivation of the group last September, our social meetings have been better each time and our technical meetings have also been great.

Yet most of the work of organizing our events is being done by José, so it's only fair to make him the leader of the group. So after forcing^H^H^H^H^Htalking with him about this, he finally accepted.

I think the group is now in better hands.

Technorati Tags: ,

Sexy hardware

Is it just me or did anybody else smiled slightly at the cover of April 2006 issue of Linux Journal?

I do agree with the picture though, a PowerBook 12" is a sexy piece of hardware, even running Linux.

Technorati Tags: ,

March 09, 2006

iDeck

I bought an iPod Video to replace my aging 2G iPod (well, officially I stole the 2G from my wife after my 1G broke the firewire port...) and to be able to carry my photos of my kid with me: grandmothers love that part.

Anyway, when I arrive at home in the evening, I like to listen to music and usually what I did was start iTunes and use the built-in TiBook speakers. It should be obvious that it's not a very good experience.

Given that this home is not my main residence, just the place I spend the night when I'm working in Lisbon, I don't want to spend a lot of money buying some audio system, so after talking a bit with Pedro, I decided to buy an iDeck.

The first week was great: excellent quality of sound (for my amateur standards), the remote control worked very well, and as a side benefit, the iPod gets a full charge and I have my sync cable always ready.

Then one night, the remote stopped working, and the sound was super-loud, I could not control the volume. Then the left speaker stopped working. Not good. I changed batteries on the remote, checked all cables, looked at the documentation (printed and online) and nothing I could find was able to solve this problem.

I took the system back to the local dealer, DelAudio, and they replaced my set with a new one after checking that indeed the system was not working properly.

Tonight I did the setup again, and right now I'm enjoying the sound and all the niceties that this system provides.

It's a great speaker set, a bit pricey, but I think it will be worth it in the long run. I like the fact that I can leave my sync cable connected in the back of the amplifier, so that I can just connect in the evening to sync up. I also like the fact that the iPod gets charged while I'm using it. And finally, the sound quality is excellent.

The thing I don't like in the iDeck is the fact that if you plug a cable to the back of the amplifier, to the aux in line, the system immediately switches to it, and silences the iPod. I would prefer a switch on the remote or on the amplifier to make that switch between input lines. This would allow me to connect the iDeck to a Aiport Express at all times and switch to a remote iTunes easily.

Apart from that, I can't find any flaws. Even with the problem I had with my first set, which was solved rapidly and without any fuss by my local dealer, I would recommend this system to anyone looking for a good set of speakers to connect their iPod.

BTW, Apple has the iPod HiFi system now, but from reports I've heard, I think the iDeck is still superior. At least, from what I've seen, you cannot sync the iPod with it, and thats a major issue for me.

Technorati Tags: , ,