Entradas no planeta de rogeriopvl


  • Rogério Vicente

    This week I had the oportunity to give an introduction talk about Test Driven Development with PHP at DRI Code Sessions. I’m no TDD expert, but I’ve been using this methodology on some of my personal projects, and this was a great way to consolidate what I’ve been learning and also share and discuss it with other programmers.

    The slides are very concise, as they had the sole purpose of guiding my speech. But I believe that they give, along with the code examples, a good notion of what TDD is about.

    You can find the code examples on Github and also the slides in PDF and ODP formats.

  • Rogério Vicente

    I’ve been wanting to leave the Wordpress platform for a while now, and last week I finally managed to start rebuilding this blog with Jekyll - a blog-aware, static site generator in Ruby.

    Don’t get me wrong, I still think that Wordpress is a great blogging/CMS platform. But for me and the purpose of this blog, it has become a little overkill.

    Jekyll is my ideal way to maintain a blog. I get to use my favorite daily work tools (Git and Textmate) and in terms of performance, static files are just great, no need to spend precious VPS resources. Oh, did I mention that this blog is now running on a VPS? That’s right, prgmr.com powered. I’m gradually moving all content in the Dreamhost account to the VPS.

    Regarding the migration, it went almost perfect except for the feed. Feed subscribers may notice some weird behavior, like sudden unread posts showing up that aren’t new at all and stuff like that. Things will get stable with new posts.

    The blog design has also changed from a modified Wordpress template to something built from scratch. This new design keeps things simple and readable, just the way I like. So no fancy stuff, just plain focus on content. And it’s still being improved along with the markup, so there will be some changes in the next few days.

    Update: I’m now using the Google Webfonts API to serve the some beautiful fonts. The header title font is Lobster, the body font is Droid Sans and the code font is Droid Sans Mono. If your browser does not support Webfonts the CSS will fallback to Georgia, the original font of this blog.

  • Rogério Vicente

    Things is probably one of the best task management applications for Mac that I’ve come across. And the only that I didn’t completely forgot after 2-3 days. The iPhone/iPod app is just the cherry on top of the cake. You can sync with your Mac app and all.

    The one feature Things is missing (besides being Mac only), is sync between different computers. I constantly use 2 Macs (personal and work) so this was a major turn off. But that’s where Dropbox kicks in and saves the day.

    Although not very explicit, Things has the option to select the location of your tasks database. So it’s pretty much obvious: save the database in a Dropbox folder, configure all you’re Things apps to use the new database location and you’re done.

    This is where you’re Things database is stored:

    ~/Library/Application Support/Cultured Code/
    

    Just copy the Things/ folder that lives in the path above to your Dropbox and then open the Things app pressing simultaneously the option key (alt). A popup will show up asking you to choose the library (database) location:

    Things - Choose A Library Dialog

    Now choose the Things folder in your Dropbox and that’s it. Repeat this step for every application that you use on a different Mac, and you’re ready to kick some serious ass at Getting Things Done.

    You can find this info about selecting Things library/database on the Cultured Code wiki.

    Update: One thing I forgot to mention is that this approach I described does not work with multiple Things applications running at the same time in different computers. Because Things only reloads the database.xml file on startup, if you don’t close the application, it won’t be aware of the new changes made to the database, and will eventually save the current state over the changes you’ve made in other instances of the application.

  • Rogério Vicente

    Things is probably one of the best task management applications for Mac that I've come across. And the only that I didn't completely forgot after 2-3 days. The iPhone/iPod app is just the cherry on top of the cake. You can sync with your Mac app and all.

    The one feature Things is missing (besides being Mac only), is sync between different computers. I constantly use 2 Macs (personal and work) so this was a major turn off. But that's where Dropbox kicks in and saves the day.

    Although not very explicit, Things has the option to select the location of your tasks database. So it's pretty much obvious: save the database in a Dropbox folder, configure all your Things apps to use the new database location and you're done.

    This is where you're Things database is stored:

     ~/Library/Application Support/Cultured Code/ 
    

    Just copy the Things/ folder that lives in the path above to your Dropbox and then open the Things app pressing simultaneously the option key (alt). A popup will show up asking you to choose the library (database) location:

    Things - Choose A Library Dialog

    Now choose the Things folder in your Dropbox and that's it. Repeat this step for every application that you use on a different Mac, and you're ready to kick some serious ass at Getting Things Done.

    You can find this info about selecting Things library/database on the Cultured Code wiki.

    Update: One thing I forgot to mention is that this approach I described does not work with multiple Things applications running at the same time in different computers. Because Things only reloads the database.xml file on startup, if you don't close the application, it won't be aware of the new changes made to the database, and will eventually save the current state over the changes you've made in other instances of the application.
  • Rogério Vicente

    Yesterday I've released hashr extension for Google Chrome. This is the first version, and it was just to try out the extensions platform for Google's browser.

    So basically this extension does the same as the Firefox addon, and the website, but in Chrome. Here's a screenshot of it in action:

    hashr chrome extension

    You can find more screenshots, info and install it at the Extension Gallery page. Or you can just check out the source at GitHub.

  • Rogério Vicente

    Yesterday I’ve released hashr extension for Google Chrome. This is the first version, and it was just to try out the extensions platform for Google’s browser.

    So basically this extension does the same as the Firefox addon, and the website, but in Chrome. Here’s a screenshot of it in action:

    hashr chrome extension

    You can find more screenshots, info and install it at the Extension Gallery page. Or you can just check out the source at GitHub.

  • Rogério Vicente

    On my spare time I’ve been learning the Ruby language. And Tinyscrobbler is the first result.

    Tinyscrobbler is a lightweight Last.fm scrobbler library. It can be used to implement the track scrobbling feature in a ruby player app.

    You can find the source (GitHub) here and install the ruby gem from Gemcutter.

    If you opt to install from Gemcutter, you need to add it to your gem sources. Just type the following in your terminal (depending on your system you might need to execute these commands with sudo):

    $ gem sources -a http://gemcutter.org

    This will add gemcutter to your gem sources. Finally to install the gem just type:

    $ gem install tinyscrobbler

    Tinyscrobbler contains a helper class to read the audio files metadata, but for now it only supports .mp3 files. I’ll be working on extending the support to other file formats like .ogg, .mp4a and .wma.

  • Rogério Vicente

    On my spare time I've been learning the Ruby language. And Tinyscrobbler is the first result.

    Tinyscrobbler is a lightweight Last.fm scrobbler library. It can be used to implement the track scrobbling feature in a ruby player app.

    You can find the source (GitHub) here and install the ruby gem from Gemcutter.

    If you opt to install from Gemcutter, you need to add it to your gem sources. Just type the following in your terminal (depending on your system you might need to execute these commands with sudo):

    $ gem sources -a http://gemcutter.org
    

    This will add gemcutter to your gem sources. Finally to install the gem just type:

    $ gem install tinyscrobbler
    

    Tinyscrobbler contains a helper class to read the audio files metadata, but for now it only supports .mp3 files. I'll be working on extending the support to other file formats like .ogg, .mp4a and .wma.

  • Rogério Vicente

    Finally I just got some time to update the hashr website.

    I decided to give it some color and some usability improvements. The resulting hash now shows up in a readonly text box so that when you choose long hash algorithms like whirlpool the hash doesn’t break the website design.

    Also related with this change it’s the copy button. I know, I hate flash too, but unfortunately due to security issues like clipboard-jacking, there’s no cross-browser compatible way to place text in user’s clipboard unless you use flash and the user clicks that.

    Anyway, the button is there to make it easy to copy the hash. But you can still do it the usual way.

    Apart from the interface changes, hashr now also has a stats page. This page for now only shows a chart of the top 10 most used hashing algorithms in the website and api and the total generated hashes. But it will have more charts in the future.

    And finally I rewrote the api and made it public with some documentation. It now supports xml, json and text responses.

    The Firefox extension is still using the old api, but soon I’ll upload to Mozilla Addons a new version using the new one.

  • Rogério Vicente

    Finally I just got some time to update the hashr website.

    I decided to give it some color and some usability improvements. The resulting hash now shows up in a readonly text box so that when you choose long hash algorithms like whirlpool the hash doesn't break the website design.

    Also related with this change it's the copy button. I know, I hate flash too, but unfortunately due to security issues like clipboard-jacking, there's no cross-browser compatible way to place text in user's clipboard unless you use flash and the user clicks that.

    Anyway, the button is there to make it easy to copy the hash. But you can still do it the usual way.

    Apart from the interface changes, hashr now also has a stats page. This page for now only shows a chart of the top 10 most used hashing algorithms in the website and api and the total generated hashes. But it will have more charts in the future.

    And finally I rewrote the api and made it public with some documentation. It now supports xml, json and text responses.

    The Firefox extension is still using the old api, but soon I'll upload to Mozilla Addons a new version using the new one.