Archive for June, 2008

Using Site Specific Browsers to Enhance the Web Experience

As a developer for Appcelerator, Inc. one of the most important aspects of my job is keeping in touch with the community through our Developer Network community site. It’s where people ask for help, suggest ways to make our product better and discuss all things Appcelerator. Therefore, the Groups page is always open in a browser tab on my desktop.

This approach has a few drawbacks. The groups page does not automatically refresh. There’s also no real good way to tell if there is something new to look at. Now, of course, I work for Appcelerator, so I can grab the Developer Network source, make the necessary changes, and push a new version. But what if I was just a plain user of another site using Appcelerator? Is there anything I can do to get the experience that I want?

Enter Todd Ditchendorf’s Fluid project (Mac only). You could probably do something similar in Mark Finkle’s Prism if you aren’t on a Mac.

Fluid lets me do two things. It gets the developer network out of the browser and into an application. This means that it shows up as it’s own entity on my Dock. The second is that since it’s integrated into OSX, I can write a little bit of javascript to display a Dock badge and display a Growl notification.

By itself, this is really neat, but there are a few problems. If you auto-refresh a page, you’re going to lose all client state. This is less than useful if you want to show a notification if something changes.

This is where the SOUI (service oriented user interface) paradigm of Appcelerator really shines. To refresh the groups page, all I need to do is send a message. To display a notification, all I need to do is read the message response. That’s it. No funky regex based parsing required.

The Dev Network Doc

If you want to set this up for your Fluid Developer Network app, then you can grab the latest version of the user script, and a nifty icon off the Appcelerator svn server.

This post is cross-posted on the Appcelerator corporate blog, Appcelerant.

  • Share/Bookmark

Elephants on Leopards (aka PostgreSQL on the Mac)

For some reason, PostgreSQL is sorta a pain to get working on the Mac. Much of this is that the ports version does bizarre things, such as make all the directories you expect to have end with the Postgres version number. Once you install it, you have to go symlink a bunch of things just to make it work sensibly. To top it off, the way ports (used to, maybe not now) adds the Postgres user makes it so that it shows up on the login screen. The Mysql installs don’t do that. It’s odd to me that a database that’s some weird conglomeration of Oracle and Sun is easier to get up and running, but it’s true and annoying.

Apparently, my brainwaves have been radiating that annoyance somewhat strongly, and was picked up by a developer who appears to live right here in Atlanta. Andy Satori is maintaining PostgreSQL binary installers for mac. He’s also built a few lightweight gui tools to use along with Postgres, including a pretty decent Cocoa query tool:

Installing the package was easy and there’s no Postgres user on my login screen. Double win. If you want Postgres on your mac, this is definitely the way to go.

Making my Postgres filled evening even better, I didn’t even have to go through a series of elaborate contortions to get my gem to build. gem install postgres was all I needed.

To round out the Postgres post, check out this visualization on the PostgreSQL project commit history.

  • Share/Bookmark

Fluid userscript for Zimbra Mail

This week I noticed that there are about 5 tabs in my browser that are never closed. Personally, I think OSX is much better at managing windows than Safari, so I converted these sites to applications with Fluid.

In that process, I noticed that my new gReader.app had a shiny doc badge:

Well now that I had one for my RSS, I wanted one for my email too. I’ve been running Zimbra in Fluid for some time, but I completely ignored the power of the userscripting ability, as well as the Fluid extensions to the JS API. The end result is that I now see a dock badge and get growl notifications when I get an email.

There are a few problems with what I’ve done. You’ll only get notifications if your inbox is open (and is called “Inbox”). Also, this means that you won’t get notifications for events on your calendar.

If you want to run this yourself, you can grab the script from github and install it into your Fluid instance. One thing that you will have to change is the included domains on a line that looks like:

// @include     https://mail.vijedi.net/*
  • Share/Bookmark

A Passenger on Ruby on Rails

One Rails thing that has always felt just a bit un-rails like is deployment. There are a ton of solutions out there. I’ve used Lighttpd, fast-cgi, and mongrel proxied by Apache. Almost all of these have been tedious, a pain, and failure prone.

The Dutch have come to our rescue with Passenger (aka mod_rails). Passenger allows you to run your Rails apps natively within Apache. No need for proxies, mongrel clusters or anything else. They even claim that it recovers from server errors.

The best part is that it’s brain-dead simple. If you can execute a few lines on a command line and add a virtual host to Apache, you can host your Rails app in Passenger.

  • Share/Bookmark
Return top

About

This is my blog about programming. For random stuff, checkout my Twitter or Tumblr