Archive for October, 2008
Sleep well, Phoenix
Update: Ah, it’s awake!
We’ll see you when you wake up.

The Phoenix Mars Lander, with its batteries depleting, has gone to sleep mode as recovery efforts continue.
While we’re in the subject of anthromorphism, check out and follow MarsPhoenix’s other cohorts on Twitter. I wished we had this back in my science high school days — it would have been a blast. (Pointy nerd hat on.)
Gmail with Mutt
I love the command line. (It shows. Heh.) Coupled with `screen`, I also use `mutt` and `irssi` extensively. Only at home, though. At work, `screen` is more than enough.
I used to have `fetchmail`, too, but with the recent iteration of `mutt`, which fetches POP and IMAP (almost an MTA in itself now — my, my, look how it’s grown), I have fine-tuned my command-line experience, almost contrarian to the Unix philosophy of “doing one thing, and doing it well”. But, hey, I use whatever works.
Without further ado, here’s my very minimal .muttrc
# Gmail settings set imap_user = "user@gmail.com" set imap_pass = "password" set smtp_url = "smtp://user@smtp.gmail.com:587/" set smtp_pass = "password" set from = "user@gmail.com" set realname = "User Name" set folder = "imaps://imap.gmail.com:993" set spoolfile = "+INBOX" set postponed="+[Gmail]/Drafts" set header_cache=~/.mutt/cache/headers set message_cachedir=~/.mutt/cache/bodies set certificate_file=~/.mutt/certificates set move = no set sort = 'threads' set sort_aux = 'last-date-received' set imap_check_subscribed # Some tweaks set imap_keepalive = 300 set mail_check = 90 set timeout = 15 set charset = iso-8859-1 ignore * unignore From Date Subject To Cc hdr_order Date From To Cc
If your Gmail space is a bit cramped, it may take a while to download all the headers, so tweak imap_keepalive, timeout, and mail_check accordingly. I know, imap_keepalive should be left untouched in keeping with the RFC default of 30 minutes, but I’m not sure Gmail even follows that.
Using screen
My work setup is like this: I have two monitors, one for a maximized Thunderbird window, and the other for a PuTTY window, Firefox, Outlook (minimized to tray, and only used for calendar reminders mostly), and IE. Well, I do open other windows, but I tend to use the above most often.
I use PuTTY extensively to manage remote Unix systems. I also like my desktop uncluttered, so instead of multiple PuTTY windows, I only use one. I log on to a “jump” host, fire up `screen`, and I’m all set.
At home, I have a similar setup. Below is my .screenrc:
# Default sessions screen -t MISC 4 screen -t EVEY 4 screen -t INES 3 screen -t IANDEXTER_COM 2 screen -t IANDEXTER_NET 1 screen -t HOME 0 # Scrolling buffer defscrollback 99999 altscreen on # PuTTY fix term xterm termcapinfo xterm ti@:te@ # Status line hardstatus alwayslastline hardstatus string '%{= kG}%-Lw%{= bW}%50> %n %t %{= kG}%+Lw%< ' # Key bindings bindkey -k k6 detach bindkey -k k7 quit bindkey -k k8 hardstatus alwayslastline bindkey -k k9 hardstatus alwaysignore # Other stuff startup_message off autodetach on defutf8 on crlf off setenv LC_CTYPE en_US.UTF-8
The Default sessions section opens up windows for my other hosts (guess how I name my boxes ;)). I also have a pretty large scroll buffer — useful when tailing logs. The hardstatus lines show the sessions and highlights the active one. I got the (not-so) fancy-schmancy color codes from here. Lastly, I bind the F6 to F9 keys to, respectively, detach the screen session, quit screen, toggle off the status line, and put it back on.
My .screenrc at work is more or less the same, except for the sessions I open. I can also tellscreen to use a different shell (I’m an unabashedly Bash fan, heh) apart from what is default in the systems I manage.
Stand against poverty on Blog Action Day 2008
October 15 is Blog Action Day, and all bloggers are urged to participate by taking a stand against poverty.
Originally uploaded by tonyocruz.
Adding SVN keyword expansion in Tortoise SVN
When using Tortoise SVN client to access my Subversion repositories from Windows, I tend to forget to set up keyword expansion (unlike in the Linux command-line, where one can always invoke svn propset svn:keywords "Id Date Author" somefile).
In Tortoise, this can be done by enabling auto-props in the configuration. In Windows Explorer, right-click to get to the Tortoise context menu:

(Yes, I’m a bit O.C. so even my resume is under version control. :P)
Edit the Subversion configuration file, specifically the following properties:
[miscellany] ... enable-auto-props = yes ... [auto-props] *.txt = svn:keywords=Date Id Rev Author URL;svn:eol-style=native *.html = svn:keywords=Date Id Rev Author URL
This tells Tortoise to expand the keywords specified for the given files. Note that this works only on new files added to the repo after the configuration has been modified.

