Sunday, November 15, 2009

Getting my head around Cocoa

I needed cvs on my new macbook, so I installed xcode, so I didn't have to figure out how to use macports.

I had xcode, so I cracked it open. And for the first time, I'm noodling a bit with a compiled version (I've compiled java from time to time, but was never sucked into actually playing with it the way I have with perl & javascript).

As always with a new toolkit, the radical differences are jumping out at me.

Messages! what a trip! [Receiver message]. So yes, I get that foo.bar() is basically, in many ways the same thing as [foo bar] (tell foo that it should "bar()". Somehow more elegant.

The other thing is passing named values is the default. Yes, you can make the default value an array, but now that I'm constantly context switching, I really can't remember what goes where in an array, so I really appreciate:

[foo bar:baz silly:YES]

And of course it's odd to be so illiterate that I can't even type two lines without generating warnings and errors. I'm such a noob!

Saturday, June 13, 2009

Adventures in Vista Land

So I finally bit the bullet a few months back and bought a computer w/ Vista when the old home server running XP pro died.

First priority was to install itunes and get everything moved over. That took a bit of fiddling as I tried over and over to convince Vista that I wanted to be able to have access to all the CDs we worked so had to rip. Eventually i got the library moved over, and then I had to figure out how to keep the playlists, and evenutally I had that done as well. Some xml files I had to copy over or something like that.

At which point we just used it as DVD player and itunes server for a while. Everyone knows you can’t use vista for anything, so trying to use it as a computer seemed unrealistic.

Finally I really bit the bullet this week and dove in. Since Vista Premium isn’t premium enough to let me use remote desktop, I had to figure out how get VNC setup. TightVNC seemed to have trouble refreshing (wouldn’t show me the start menu when I opened it, for example), so I ended up with ultraVNC, which does everything you’d expect. And I don’t have to give M$ more money, that’s a nice thing.

Next was setting up all the shares I used to have set up on the XP box. That actually turned out to be super easy.  I’d actually had the easiest printer setup ever a couple months back, when I’d just plugged it in and been able to use it. So maybe Vista isn’t evil?

Then today it was time to edit an old ASP site. Did IIS still exist? Did it still support ASP? As it turns out, IIS is still part of Windowsland, and it appears that my old ASP pages will eventually work. I’m not sure I’ve actually used active server pages this century, but interesting to see that its all still there. Key things I had to figure out:

  • I don’t like using inetpub, so had to set up permissions for IIS to use one of my document directories as root. Both IIS_IUSRS and IUSR needed to have read access to my site
  • Once a local browser could access the site, I had to open a hole in the Vista firewall on port 80. Didn’t seem to be pre-defined, so I had to create a custom firewall rule that I decided to call “Port 80”

Makes me wonder if there’s some button somewhere I could have pushed to enable anonymous web access to this directory? But mostly it makes me wonder if I really want to mess with old crufty ASP pages. I already know how to edit Apache conf files. I don’t want to learn how to use a whole new interface.

Thinking about it, the thing that really gets me is that I don’t much care for learning new operating systems. I’m comfortable with XP (I use an XP laptop at work). I can get Linux to run all the web servers I need. And none of that seems to be much help with Vista, where whenever I need to do something new I find myself using google to find answers to newbie questions.

Friday, March 20, 2009

Another Blue Screen

When I opened my laptop this morning, the blue screen was counting down as it stored some kind of information on my hard drive. Evidence, should I need it, that the operating system had lost its bearing and collapsed suddenly.

I am struck suddenly by the realization that the computers I've been living with these last fifteen years are far less reliable than the VW bus I owned in the early '90s, an antique that stripped a spline on its drive wheel in the middle of death valley once, and another time stopped running on the freeway because the fuel hose had slipped off the carburetor and was merrily spraying gasoline across the entire engine compartment.

This thing, this machine, on which my livelihood depends, these contraptions that so many of us spend our days fiddling with, constantly grappling with mechanical and software failures of one kind or another. Somehow to realize that these ubiquitous computational devices are far, far less reliable than thirty-year-old VW buses fills me with wonder. The incredible patience of millions of computer users. The unfounded optimism that today's task will somehow be completed even as thousands of us are stranded on the side of the road, wondering how to bring the contraption back to life.

Quick! To the emails! To the presentations! To the spreadsheets! Before the next blue screen stops us in our tracks!

Thursday, January 08, 2009

Javascript Cheat Sheet

Cause I don't write js often enough to remember its syntax

Add js file to a page

var s=document.createElement('script');
s.setAttribute('src','http://foo.com/bar.js');
document.getElementsByTagName('head')[0].appendChild(s);

Add jQuery to a page

http://www.learningjquery.com/2008/06/updated-jquery-bookmarklet

Append js to a node in DOM w/ jQuery

$("#tab4").append("<script> alert("hello!") </script> ");

Wednesday, September 10, 2008

IT 2.0

After working in technology since 1994, my biggest impression is this: IT costs too much.

This won't change overnight, but 50 years from now, companies will be budgeting, per user, much less for IT. And they'll get a whole lot more value.

I've very little idea of how this will happen. But for the time being, I've got a ringside seat, working for the IT department of a fairly large company.

This week, economist wrote about how AdventNet is trying to play a role in the next IT revolution:

http://www.economist.com/people/displaystory.cfm?story_id=12052307&fsrc=rss

Tuesday, September 09, 2008

It Depends

I live in a land of partial questions, where folks are constantly asking me how long it will take to build a web site or a page weeks or months before we've figured out what that site or page should consist of.

So my answer to most questions is some variation of it depends, usually dressed up a little, as in "we typically like to schedule this sort of change 2-6 months ahead of time, depending on the number of integration points, reliability requirements, and impacted processes." Big words like that convey the impression that I'm paying close attention (which in fact is something I try to do), and I've found with experience that if I just say "It depends" folks will think I'm one of those annoying tech types who refuses to give a straight answer.

Or maybe I'm just a windbag with a rationalization? Some of both I suppose.

Of course some of the reasons that things depend have little to do with the difficulties folks have in understanding that for me to build something, they need to know what they want to build.  For example:

http://www.webaim.org/blog/user-agent-string-history/

Because web browsers are wacky. Not in a way that I've figured out how to easily explain to folks who fall asleep the minute the gory details come up, and who never had to learn how hideous Netscape 4.7 was, or of the torture of working with  browsers from Redmond. Browsers are strange and twisted little things because they were coded by humans who had to make the best of of a bad set of options while on a ridiculous timeline.

So it goes.

Monday, August 25, 2008

Time

Somehow, this afternoon at least, there seems to be a connection between turning 40 and realizing how little time there are to attend to the myriad opportunities each day brings.

I stumbled over some nice writing on this topic today:

Accept that your workload exceeds your resources — that you are the first and last filter for what deserves your time — and you’ll already be better off than you were even two minutes ago.

Merlin Mann, http://www.43folders.com/2006/03/13/philosophy