Lunix Tech Tips

Almost every engineer at Yahoo! gets a *NIX workstation in addition to a PC/laptop (in my case, I requested a Linux box instead of the more traditional BSD, and a Powerbook). While KVMs come standard, a fair number use their the workstations almost exclusively headlessly for local development, me among them. I’ve never been a fan of X Windows (can’t I just have working mouseless copy and paste for all my applications?), and my life seemed like it was fine without it.

Yesterday, I couldn’t log in through my laptop, and I decided to bite the bullet and finally try to get X working for me. I’ve actually made a lot more progress than I thought I would, and I’ve learned some interesting new things (that I’m writing down so I don’t forget), but this experience has served to confirm my previous assumptions that my life will continue to be fine without interacting with UNIX on the desktop.

  • 1920×1200 on 2405FPW – One problem that plagued me was that I couldn’t get the 2405FPW monitor running at native resolution in X. As far as I knew, it should have been working, but it wasn’t. I finally tracked down a lead that I had missed, and after downloaded and compiling read-edid, I found out the missing ModeLine arguments, and also had to correct the HorizSync settings in the Monitor Section of the xorg.conf
  • RHEL4 up2date sucks – Many of the problems I’ve had wouldn’t be issues in Debian. Up2date reads YUM repositories, so I added the Fedora Extras in. (RHEL4 is based off of FC3) It’s not perfect, and some of the packages just fail (or have unresolved dependency trees), but it’s an improvement
  • Quicksilver-like tools – I found a couple, but ended up switching window managers (for a bunch of other reasons) so I never got to try it out. ion, the window manager I’m now using lets you do keyboard binds and scripting, which is good enough for my purposes, even if it’s not very slick
  • A better window manager – so, being fed up with how I couldn’t have a decent copy-and-paste experience (1 set of keyboard shortcuts across all applications – honestly, can it be that hard?) I set off to find something to solve my clipboard woes… and I haven’t found it. I did however try a bunch of window managers (on my list: tiling w/ arbitrary window splitting and sizing, remembering layouts, full keyboard access, customizability). Ratpoison and wmii proved too limiting, but ion seems to be almost there with the other window manager features I was looking for. It has built in Lua for high-level scripting of behaviors and arbitrary keybinding, so if I had a couple days to spare (which I don’t), I could probably get it near how I think a window manager should actually work. Of course, it falls down on the copy and pasting, but maybe I can find a third party app to do what I want.
  • RHEL4 window manager switching – RHEL4 uses gdm to handle X Windows logins. It’s really bizarre. There are lots of config files lying around, none of which seem to work in actually displaying a third-party window manager in the selection list. After lots of searching, I found that that the script I wanted to access was switchdesk-helper. I then added custom branches for my window managers and the appropriate switchdesk files. I suspect there’s a better and easier “correct” way to do it, but I know better than to assume that’s the case…
  • Reversing mouse buttons – One of the things employees go through arriving at Yahoo is a full ergo review. Since then, I’ve been mousing w/ my left hand at work. It takes a while to get used to it, and I have to admit, I still don’t feel very comfortable doing fine dragging operations (hence my extreme desire for the shift-arrow control-key ranging and copy-and-paste that you get with any non-terminally retarded UI). While KDE had this built into its preferences, other Window Managers don’t. While it’s a command is given in the BSDE FAQ, it’s actually wrong and doesn’t work on Linux. You need to run xmodmap with the command “pointer = 3 2 1 4 5” not “pointer = 3 2 1”. If you do the latter, it’ll barf at you. wee!
  • xterm colors – The defaults for xterm are a blinding black on white. I solved this problem years ago, but for some reason, my .Xdefaults changes weren’t loading. Turns out that if that happens you have to rund xrdb on the .Xdefaults to update (ha ha!, of course!) I also finally got around to changing the xterm*color4, which by default is an illegibly dark blue when running on a dark background to something better (I’ve settled for now on RoyalBlue

As you can see, that’s what I like about Linux. It just works.

On an unrelated techie note, in Firefox with Adblock Plus, you can go into about:config, filter for the adblock preferences, and change extensions.adblockplus.defaultstatusbaraction to 3 so that clicking the statusbar icon will default to toggling Adblock Plus on and off. I was just playing around with that and I realized it was just countint down the menu. Very cool.