Showing posts with label general. Show all posts
Showing posts with label general. Show all posts

From Startups to MegaCorp: Unlearning to fix everything

In the startup world when you discover an issue, whether it's a logic error or an environmental misconfiguration, being able to fix it quickly and, maybe, document the fix is a virtue.

A hard lesson that I'm learning is that in a different environment that which was a virtue in the startup world can actually be harmful. By fixing an environmental issue you can deprive the organization of the process correction necessary to handle it structurally.

This strikes me as analogous to the decision to *not* handle an error in code. Sometimes you intentionally don't handle an error even though it is anticipated because to do so masks a more fundamental problem. The "if this error occurs, something is deeply wrong in a way that can't be recovered automatically" is a widely established pattern in software construction.

The hard part is realizing that it generalizes to the organizational level. By fixing an environmental issue that another team is responsible for you may well deprive that team of a needed corrective. What happens when you're too busy working on problems that can only be handled by your team and the issue comes up again?

Quick Hit: Taming Notepad++’s Language Menu

W00t! Notepad++’s language support is awesome. It supports so many languages that navigating the languages list (e.g., if the file extension doesn’t match the registered extension) is a bit of a pain. Fortunately its contents are editable!

image

Now to remove the ones we don’t use here…

Ode to Notepad++

Slowly making the transition away from UltraEdit to Notepad++. UltraEdit is awesome and has been my main editor for probably going on a decade now. I've bought 3 upgrades.

Unfortunately it doesn't play nice with the revision control system at work. It takes a while to exit after editing a file during an interactive resolve session. And by a while I mean longer than Outlook! Outlook is notorious for its process taking forever to exit after you've exited the application.

Anyway, I'm finding all sorts of nifty stuff with Notepad++. Like being able to stuff a string into a bunch of lines at once. Alt-Click-drag (column mode) across the text you want to replace on all of the lines and start typing - presto! The text is inserted at the same location in all of the selected lines! Great for manually transforming text from copy/paste across different systems.

Another nifty feature is the highlight every word that matches the currently selected word. Great for finding things in log files.

Unlike UltraEdit, which threw everything but the kitchen sink into the app all at once, Notepad++ seems to be relatively minimalist. It relies on extensions to add extra functionality. So, for instance, when I wanted to navigate back and forth from whichever file and line I've been at previously (CTRL+-/CTRL+SHIFT+-), I was disappointed that it wasn't built into the app. My disappointment was premature - just looking up that plugin (there's a built-in minimalist plugin manager) exposed me to all the other plugins out there. The plugin (Location Navigate) installed quickly and worked immediately.

I still keep UltraEdit installed, mainly for things that I don't know how to do in Notepad++ yet. But that list is diminishing. And Notepad++ has already replaced it as my %EDITOR%.

Internet Explorer 64-bit: What is it good for?

About the only use I get out of 64-bit mode Internet Explorer is opening and searching large documents. Like the 30 megs of spew emitted by static code analyzers. Searching in 64-bit mode is so much faster that it’s worth the WinKey + “ie 64” (without the quotes) key combo that it takes to start it.

Why I still use UltraEdit when Visual Studio 2012 is such an Excellent Editor

While Visual Studio has come a long way as an editor (not to mention as an IDE) there are still a few features in UltraEdit that keep me coming back (currently on v17.20):

  1. right click the tab for any open file and you can copy it’s path into the clipboard. This is really handy when you need to type in an outrageously long path as an argument to a command.
  2. quick open (ctrl+q). Often I’ll use this to quickly open log files. The paths are long but included in troubleshooting emails.
  3. reload changed files. Visual Studio will prompt you but UltraEdit can do it automatically (with a configurable polling interval). It can also automatically scroll to the end of changed files – a great way to keep an eye on the spew.
  4. compare files. I never sprang for UltraCompare because the comparison functionality built into UltraEdit has been more than sufficient for my needs.
  5. Regular Expressions. As of Visual Studio 2012 this gap has finally been bridged but even as late as VS 2010 there was still no way to use .net/PERL (pcre) regular expression syntax in the various find dialogs. That’s ridiculous – good thing VS 2012 provides this feature.

How Ultrabooks Will Restore Traditional PC Dominance

The “Post PC” revolution is on the tip of every pundit’s tongue these days. So I’ve been thinking about how PCs can reclaim some of their former glory. Here’s a quick list of what I’ve come up with so far:

  1. Put every low-cost sensor into every ultraportable pc. Ambient light sensors, accelerometers, GPS, thermometers, barometers, front and rear-facing webcams, etc… The PC needs to be able to accept any input that a smartphone can accept and then some.
    1. With options for more sensitive/higher resolution versions of each of these sensors.
  2. Touch, touch, touch. Windows 8 will help in a big way. It should be easier to find a mobile PC with a floppy drive than it is to find a mobile PC WITHOUT touchscreen support.
  3. Cellular connectivity in addition to WiFi and Bluetooth. Ultrabooks should be able to use voice (GSM and CDMA) and data (3G, 4G) connections from the top US-based carriers without anything dongles sticking out of the chassis. I should be able to go to AT&T, Verizon or T-mobile, pick up a SIM card, pop it into my laptop and be instantly connected. Or pay $25 and have it installed.
    1. With options for supporting top international carrier standards.

The PC’s strong point has always been its general purpose nature. Smartphones and tablets are currently able to do things that cannot be done easily on a PC (e.g., an always one cellular data connection, GPS, etc…). Making these items standard would go a long way towards bridging that gap.

What do you think traditional PCs can do to reassert their dominance over the home computing landscape?

First Week at Microsoft and Escaping Virtualization

After driving across the country I'm finally starting to settle into my new job at Microsoft.  It's only been a week though so I'm still in the honeymoon phase.  Good god they use technology here, it's awesome!

A few firsts:
  • First time ever having the option of using software as a work/desk phone.  Office Live Communicator truly rocks!
  • First time ever logging onto a domain from a copier/scanner/fax machine.
  • First time successfully using PXE boot without suspecting the network was really running on a dial-up modem. It was, and is, blindingly fast (usually).
Escaping Virtualization

Since testing involves installing lots of builds I've gotten to work with several virtualization programs.  They all seem to default to a different command sequence to 'escape' back to the host OS:
  • Virtual PC uses right ALT. Not really my favorite as it takes my hand off the mouse.
  • VirtualBox uses right CTRL.  Ditto.
  • Hyper-V uses the truly draconian CTRL+ALT+LEFT ARROW. Yikes!

Moving Windows Forms with Subversion and TortoiseSVN

If you’re using a subversion client that doesn’t have Visual Studio integration (e.g., TortoiseSVN) then moving a Windows Form can be a pain.  Here’s one slightly-less-painful way:

  1. Right click the form in Visual Studio’s Solution Explorer and exclude it from the project.
  2. Open up Windows Explorer, browse to the directory containing the Form.cs, Form.Designer.cs and Form.Resx files.
  3. Turn on Folders in Windows Explorer.  This will cause the folder tree view to appear.
  4. Select all three files, the right-drag (yes, Windows Explorer supports dragging a selection with the right mouse button) the files to the destination folder.
  5. When you release the right mouse button choose “SVN Move”.
  6. Include the files in Visual Studio project.  I usually do this by turning on “view all files” in solution explorer then using the context menu (right-click) to include the form.

That’s it.  Not too painful when you think about it but doing it this way keeps the linkage between the new location and the old location in subversion.

The Virtues of Virtualization

Back in the bad old days, say 5+ years ago, when an enthusiast user wanted to run more than one operating system he/she would run a multi-boot setup. That is, the computer would boot into a boot manager that allowed the user to choose which operating system to run.

Although this worked it was kind of a pain to maintain. Recovery was dangerous as one operating system tended to overwrite the boot setup of any other operating system. It also, usually, required separate disk partitions. Deciding how much space to allocate for each operating system was a black art that always seemed to leave lots of space unusable because it had been allocated to one of the other operating systems.

Over time setup and maintenance became easier as operating systems increased their support for multiboot scenarios. Linux users are laughing at that statement since linux has always existed in a heterogenous environment and has pretty much always had support for multiboot (via various boot loaders like grub or lilo). Windows may have been a little later to the party but boot.ini has been around since NT.

Even with improved OS support for playing nice with multiple boot scenarios there's something fundamentally unsatisfying about multiboot. One of the most common reasons to run more than one operating system on a single computer is to be able to test software on a different OS. A similar task is to be able to test a web app in multiple browsers on different OSes. Yet under multiboot each "test" requires a machine reboot. This is an incredibly inefficient way to test. Because it's so inefficient it inhibits the frequent "make small change-test change-repeat" cycle that is key to reducing bugs.

Enter virtualization. Instead of having a single computer run a single operating system at a time, virtualization allows a single computer to run multiple operating systems simultaneously. The first operating system that boots is called the host operating system. Subsequently run operating systems are called guest OSes.

Virtualization allows a single computer to run multiple operating systems simultaneously through the magic of software. The key piece of software is the virtual machine. It is exactly what it sounds like. It is a piece of software whose sole purpose is to fool an operating system into believing it is running on real hardware.

A non-virtual machine, e.g., a computer you might buy from Dell, has a CPU, chipset, memory, a hard disk and peripherals. All of these are physical devices. A virtual machine has the virtual equivalents of these; a virtual chipset, virtual video card, virtual hard disk, etc...

There are several vendors that make virtualization software. Each provides their own flavor of virtual hardware. That is, VMWare provides a different virtual video card than Microsoft's Virtual PC, which is different from the one provided by Sun's VirtualBox.

Virtualization is similar but not identical to emulation. Emulation has been around for years. You can take a quad core, 64bit machine and run software to emulate a Commodore 64. I'm not quite sure why people do this but am told it's all the rage in PC nostalgia. The difference between emulation and virtualization is that virtualization depends on a tighter integration between the virtual machine and the actual machine. An emulator runs in a process like any other; the emulation software runs in user mode, its threads are scheduled like any other user thread.

When a virtual machine is running an operating system, it is executing in the same privileged mode (with a few exceptions) as the host operating system. Programs running in the guest operating system can be pre-empted by the guest operating system. This improves performance and contributes to an illusion that also distinguishes a virtual machine from emulator software: the guest operating system need not be aware that it is running in a virtual machine.

Like physical machines an operating system must be in installed on a virtual machine to profitably take advantage of the system. Unlike physical machines the virtual machine doesn't need a physical hard disk; it uses a virtual hard disk created by the virtualization software. The flip side of this is that virtual machines can only use virtualized hardware. Most virtualization software provides support for virtualizing network adapters, USB, printers, serial ports and a few other commonly used peripherals. If the virtualization software doesn't provide a way to virtualize a given piece of hardware then that hardware probably can't be used in a virtual machine.

Yet another reason to love Google Reader

Over the past year or so more and more of the reading I do on the web is being done through Google Reader.

This has been entirely unintentional. It just happens to be very handy to have a single destination that gets updated frequently throughout the day.

Part of this accidental dependence is the result of good design. Google Reader devotes most of its space to the intended content (news, blogs, headlines, etc...).

It makes liberal use of AJAX to make the UI incredibly responsive.

It even has keyboard shortcuts though those haven't grown on me yet.

They've also got several nice bundles of content that make it easy to find interesting articles.

It even plays nice with mobile phones that are not the iPhone. It is hard to overstate how amazing it is that Google Reader works with Pocket Internet Explorer 5! Nothing works with Pocket IE5 except sites that assiduously restrict themselves to whatever meager fraction of WAP-friendly HTML is grokked by Pocket IE5.

Not only does it play nice with Pocket IE5 it even makes other sites play nice with Pocket IE5 by stripping away all of the HTML goodness that PIE5 can't deal with.

I'm not sure I could go back to standing in line without Google Reader on Windows Mobile (or something like it).

Today I discovered that they didn't forget their "raison d'etre". The convenient search bar at the top of the Reader homepage searches, among other things, any of the articles you've ever read in Google Reader! So it's a great way to track down that handy link about something or other you read a while ago but forgot about.

Getting Podcasts on Windows Mobile with BeyondPod

BeyondPod is a wonderful feed reader written entirely in .net (compact framework). There are some real small-form-factor UI gems in the program. Of course, performance could always be improved but IMHO it's definitely one of the best free feed readers out there.

Although it's great for reading feeds I've found that getting feeds into its list of feeds is a bit of a pain. Some of this is inherent in the form-factor; it's a lot easier to browse the web on a laptop or PC and web browsing is the best way that I've found to discover podcasts/feeds.

One way to get a list of feeds discovered on the web into BeyondPod is to use OPML files. These are xml files structured according to the OPML standard that can be used to aggregate feeds. There are plenty of OPML generators on the web.

So I usually load one of the web based OPML generators out there into a separate tab then copy and paste feed rss/atom links as I encounter them. Then I:
  1. Generate the opml file.
  2. Open it in an editor (UltraEdit) to remove all whitespace (BeyondPod unfortunately chokes on OPML files with whitespace between xml elements).
  3. Connect my Windows Mobile device.
  4. Copy the opml file onto the storage card.
  5. Import the opml file into BeyondPod.

With so many podcasts out there the frustrations of a long commute have been replaced with "darn, I'm at work already?" Usually in the middle of some juicy tech podcast....

Searching with Regular Expressions in Internet Explorer

Ever wish you could do a regular expression search on the text of a webpage? FindRegex adds the ability to do this to Internet Explorer. After installing it (click here to download), you can do a regular expression search by right clicking on any web page and choosing "Find Regex".

This has only been tested in Internet Explorer 7+.

NOTE: Ignore the "this can harm your computer" warning on the download page. SkyDrive does that for any file ending in .msi.

Why the AT&T Tilt/HTC Kaiser is awesome

So many reasons, so little time but here goes...

  1. Built-in GPS. This has prevented me from getting lost so many times in the past few months that I can't imagine living without it. This is especially helpful in downtown atlanta where lots of streets are closed because of construction. Since I'm still not all that familiar with the streets a detour would normally mean me getting lost OR pulling over, pulling out the paper map and trying to get my bearings. Since I bought the tilt I just start Windows Live Search, bring up a map and wallah! An alternate route becomes obvious. Downtown Atlanta IS mostly a grid but there are enough deviations that it's easy to go far out of the way while trying to find an alternate route.

    1. QuickGPS speeds up initialization.
    2. A suction cup PDA holder on the front windshield makes using this while driving much less dangerous :)
    3. GPS requires a clear view of the sky so no luck indoors ;(
  2. ActiveSync. I have no idea what iPhoners have been using but I probably rely more on the Tilt for meeting notices and reminders than my work laptop now. Calendar, Contacts, Email, Tasks and Notes all constantly available!
  3. 3G. This phone is so awesome that it even worked on a recent trip to South Korea! 3G isn't as fast as DSL but it definitely feels like high speed internet access. With a little hacking it's possible to share the Tilt's 3g internet connection with a laptop (both by USB AND by bluetooth!) - this is really handy in airports and other places that don't have free wifi.
  4. Bluetooth. I didn't have a single bluetooth device before getting this phone but it's so useful that I have since added bluetooth dongles to my home laptop, a bluetooth headset (sony dr-22) and plan on getting bluetooth speakers and a bluetooth receiver. If your music collection is entirely on a PC or other device, bluetooth is the missing "link". Windows Media Player even has built-in support for the advanced profile so I can pause and skip from the headset while listening to a playlist.
  5. Pocket IE. Despite all its shortcomings (and they are many), Pocket IE is wonderful for plain and simple text + graphics browsing. There are even some old plugins (e.g., flash) that still work. Just being able to browse the web from anywhere at anytime is a godsend if patience isn't exactly your strong point. I don't mind waiting in line any more since I can use the time to pull up google reader and catch up on internet browsing or send off a short response to an email. IT'S GREAT!!!!!
  6. Office Mobile, Adobe Reader LE - for obvious reasons.
  7. The HTC Audio Manager application. This is probably one of the best designed apps that I've seen for the Tilt. It takes advantage of the touch screen interface in all the right places. The buttons are large enough to use without fumbling. It is so well designed that it doesn't require a stylus to create a playlist on the fly or edit an existing playlist. In my opinion this app works so well because it compensates for the lack of screen space by using context. No screen has very many options (hence there is enough space to make the options available with large buttons or fonts) but when you click an option that requires more input the entire screen switches into that context. And they didn't forget to always provide a way to 'back out' of the current context. At first this was a little counter-intuitive to my desktop-centric expectations (e.g., to switch from 1 artist to another you touch the artists name at the top of the screen - this sends you back to the full artist listing where you can select another artist) but it only takes a few minutes of getting used to.

    1. I have to comment on the playlist editor. It is, hands down, light years better than the Windows Media Player mobile playlist editor. To change the order or delete tracks you switch into edit mode (a single, large button) at which point you can touch-drag tracks around or touch-hold-delete any track. To commit the changes you click done (another single, large button). If your browsing tracks, touch-hold-add to playlist takes you to the list of playlists where a single click on the target playlist adds the track. And the next time you try to add to playlist the last selected playlist is selected by default!
    2. The Windows Media Player Mobile playlist editor requires the use of a stylus (unless you happen to have really long nails). Modifying a playlist is a real pain especially if you're listening to a playlist WHILE modifying it. On the plus side, it will display the album art if it's available, something the HTC Audio Manager doesn't do. And it's playlist format is accessible to the desktop version of Windows Media Player. Still, given that I listen to music more often than not while on the go, I would readily trade playlist sync for a UI that I could use without a stylus!

  8. MicroSDHC support. Right now the biggest card I can find is 8GB but 16GB should be out soon. The manual suggests that it'll support as much as 32GB. 32GB on a mobile phone!!!
  9. The slideout keyboard. After getting used to this I don't even bother with the predictive input/text completion; it's more than fast enough for small to medium sized email messages.
  10. Voice Recorder. With a little hacking you can assign the voice recorder to the "Push To Talk" button. This came in handy in South Korea where an overeager-to-speak-english cab driver regaled me, my boss and a coworker with "Amazing Grace" and "Jingle Bells". Without the Tilt I couldn't have captured this hysterical moment for posterity ;)

Oh and for you Microsoft haters out there - I DO have google maps installed but as of the last update of Windows Live Search it is way easier to get directions with Windows Live Search than with Google Maps. Windows Live Search remembers previously entered addresses and allows you to choose from this list when setting the start and destination. This can be done in the span of a traffic light. Whereas with google maps I have to type the addresses - not possible for me unless the traffic light is really long. Windows Live Search uses an arrow for it's current location which I find helpful in getting oriented while in slow moving traffic. Windows Live Search also makes it much easier to find information on nearby restaurants, gas stations, movie theaters, etc... because of it's categories listing. This is another case where the ease of use is much greater because of large buttons + context; I can browse predefined categories by switching from the map context to the home context (via a big "home" button) then quickly browse to the category of interest. Google's search oriented interface is too cumbersome for use while driving.