Feb 25 2008

OS X Default keys

Some default key bindings in OS X are, honestly, annoying. Especially the home/end keys. Of the “big three” desktop OSes, Mac seems to be the odd man out. Most windows/linux applications treat home/end the same way. In the OS X terminal application, the home key sends you to the top of the scroll buffer. The end key sends you to the end of the window’s scroll buffer. Not the expected behavior. Home means “home” – the beginning of the line. End means “end” – the end of the line. Pgup and pgdn are supposed to serve to move in large chunks around the buffer. I can’t count the number of times I’ve hit the end key expecting to get to the end of the line (like while I’m typing this post) and instead get the end of the buffer. Highly annoying to have my work interrupted by this constantly. Instead of me trying to learn how to use yet another interface/computer, I’m making the computer learn this time.

Here is how to remap the home/end keys in the terminal application

Terminal>Window Settings>Keyboard

end:

\033[4~

home:

\033[1~

the 033 part can be obtained by ^[ (aka ctrl+[ )

After doing that, you need to modify (or create) your .inputrc file to contain the following

# Be 8 bit clean.
set input-meta on
set output-meta on
set convert-meta off

# allow the use of the Home/End keys
"\e[1~": beginning-of-line
"\e[4~": end-of-line

# allow the use of the Delete/Insert keys
"\e[3~": delete-char
"\e[2~": quoted-insert

Restart the terminal and you’ll be good. Firefox, however still acts whacked out. That one is more complicated.


Jan 14 2008

Please don’t e-mail us offline

From a tech support reply message outlining some troubleshooting tips, apparently email is now an “offline” communication:

*** Please do not respond to this email as all conversations on this matter would be best handled online. **


Jan 10 2008

OS X 10.5 (Leopard) First Impressions

Upgraded my Macbook from OS X 10.4 to .5 (Leopard) today. First impressions are mixed. The install/upgrade process took a while, but was hands-off for the most part. After a couple of reboots for software updates – including an ominous /!\ dialog about boot caches needing to be updated, and a hang during boot, it seems to have installed fine.

However, the one thing that probably drives me more nuts than anything in a computer, is when it tells me I don’t have sufficient access to perform an operation. Windows does this often enough when I try to kill a hung process. As an administrator, I should be able to kill any process or delete any file I want. The consequences are mine to bear. In Leopard’s case, I was simply trying to rename a folder. I have a folder aptly called ‘downloads’ where I store applications, tarballs, etc that I’ve downloaded from the ‘net. I point Firefox at it so that files go there automagically. Leopard figured out this was a special folder and gave it a pretty icon. I decided to rename the folder “Downloads” (capital D) to be more consistent with the other folders (Documents, Movies, etc). Except, I’m not allowed. The Finder says “You do not have sufficient privileges to perform this operation” or so such nonsense. Thankfully someone has a solution

skyhawk:~ $ mv downloads/ Downloads
mv: rename downloads/ to Downloads: Permission denied
skyhawk:~ $ ls -ld downloads/
drwxr-xr-x+ 153 sj sj 5202 Jan 10 13:13 downloads/
skyhawk:~ $ chmod -RN downloads
skyhawk:~ $ mv downloads/ Downloads

I don’t know what the trailing + means, and I have no idea what the N is either. But it worked.


Dec 28 2007

Vista “User Account Control”

As a follow up to the previous post, I had my first direct experience with UAC in Vista yesterday. While I own a Macbook, I’m not a huge Apple fan boy. However, the Apple ad doesn’t even come close. What a royal PITA. It is obviously turned on by default and I seriously cannot see any point except to do two things: shift the blame for the OS’s insecurity to the user (ie “the user clicked “Ok” so they must really understand what they’re doing and anything afterwards is on them!”) and just to be annoying.

Unfortunately, UAC doesn’t stop at being merely annoying. It actively gets in the way. I accidentally unzipped a driver package from dell onto the desktop. I couldn’t delete most of the files until I turned off UAC. I created the files, and they’re in a directory owned by me. And I’m a system Administrator. But still after clicking through 3 or 4 prompts, I get “Permission denied”. The UAC setting is not in the screen that tells you UAC is turned on and “protecting” you, another problem. I guess they don’t want you to find it. Once you turn it off, you get a nagging little bubble every few minutes that tells you your computer is insecure. Well, no frickin’ duh.

The biggest problem I see with UAC is the one that most techs I’ve read and heard say – it asks too many questions. Instead of asking about only the really important things, it asks more than once about mundane things. I’m a tech and I don’t feel like reading every stupid dialog that comes up and determining the correct answer. How is the average user supposed to cope with this?

I think part of the problem is that because Windows is slow and bloated, too many things run in kernel space. Meaning that the process gets an artificial speed increase in exchange for the security normally provided by running in userspace. So Vista tries to compensate by asking inane questions about if you really really want to do something. It reminds me of the priv separation nightmare that I experienced with Windows 2000. Non-priv users could not burn CDs. Even using the special “Run As…” wasn’t enough – you could get a little bit further but for some reason of the forked processes wasn’t inheriting the elevated privileges, so no CD for you. Unless you log out and log back in as an administrative-level user.

Several companies, including Dell, have felt the Vista backlash from customers and are allowing them in some cases to upgrade from to XP. However, my personal recommendation for anyone buying new systems, especially laptops, is to go Mac, especially if your preferred system vendor refuses to give you the option of XP or wants to charge some extra fee for it. If you’re savvy enough, at least you have the option to dump Vista and run Linux on a PC. But for most folks, save yourself the trouble and hassle of Vista. In general, OS X just works. I’m planning to upgrade this macbook to Leopard sometime within the next two weeks, so we’ll see how that goes.