Feeds:
Posts
Comments

Archive for January, 2009

Initially, I wrote this Vim plugin to emulate TextMate’s cmd-t functionality.

Here’s what you get:

  1. type ESC-t
  2. you get a new buffer filled with the “find” command
  3. search for the file you want with /
  4. press ENTER, it opens the file under the cursor

I consider this an 80/20 solution … it does most of what I need and it’s under 50 lines of code.

Review the code on github and download it here.

The plugin is also featured in this screencast.

Read Full Post »

Anatomy of a Home Page

What do you see when you open your browser?

Is it a blank page? (Nothing is faster!) Or is it a convenience page? (google.com?)

I open a new browser tab/window in two circumstances:

  1. I want to search something
  2. I want to open a bookmark

For problem #1, I used yubnub for a long time. Yubnub is supposed to be “a (social) command line for the web”, but to me the only interesting aspect is user-contributed search engine shortcuts. You want to use Google image: “gim hajime no ippo”. You want to use Google map: “gmap olympic stadium, montreal”. But it goes further, yubnub provides direct access to the search engines of specialized sites: amazon (.com/.ca), bestbuy, tigerdirect, apple trailers, newegg, the pirate bay … the list goes on and on. (There’s a command to find a yubnub command: ls) The idea of having to first go to a website and THEN do a search seems so backward to me … so 2001.

For problem #2, if you don’t want to go insane and have many computers, you have to look into synchronizing your bookmarks. What a pain! In fact, yubnub served as a kind of bookmark for sites I would do searches on … but there is still a list of other sites which don’t fit that pattern.

Here’s my solution to all these problems: home.acidfog.com.
default home page

Pretty simple, no?

Here’s the breakdown:
analysis1

  1. the logo: thematic
  2. the search field
  3. JavaScript-hijacked submit button
  4. JavaScript-hijacked “show links” anchor

When the page loads, the focus is placed on the search field automatically. On submit, it looks up in my JavaScript yubnub clone. Clicking on “links” makes a list of bookmarks appear. Finally, the page captures the “ESC” key and also shows the bookmarks. (vim habits)

I captured the essence of yubnub and distilled it into my own JavaScript code. This allowed me to completely stop using yubnub which was sometimes slow and sometimes down. Also, I’m not too keen on having yet another trace of EVERYTHING I’m searching appearing in the yubnub’s log files.

Another downside of using yubnub is that you have to agree with the shortcut command picked by the community. Since it’s my code, I can pick what I want.

Feel free to steal and extend on the general idea here.

Read Full Post »

This year, I’m going with SMART resolutions. I’m looking for statements like: one [thing] per [time period]. On the technical side, I’ve got:

  • half an hour of reading code per day
  • one (programming) project per month

I’ve got ~8 items on my list, but the 2 above are the ones I decided to do.

I’ve always found reading other people’s code challenging. (I might not be alone.) In a true agile way, I believe that if it hurts do it more often. This year, I’ll crack open a lot of code and force myself to read through it.

As for projects, 12 throwaway projects are just what the doctor ordered. These will serve multiple purposes:

  • force myself to code “crazy” things I wouldn’t normally invest time into
  • expose myself to more topics
  • serve as programming exercises

There are no downsides!

I bought a span-a-year wall calendar and I’m going to follow Seinfeld’s productivity secret.

I know resolutions are cheesy. However, by only picking a few in the might-have-done-anyway category, I’m setting myself up for success.

Read Full Post »

Follow

Get every new post delivered to your Inbox.