Category : Productivity

Multiple Machine Configuration

If you are anything like me you’ll find yourself using a number of different PCs through a typical week. I have my work laptop, my work Dev machine, my home PC, my netbook and some semi permanent virtual machines that I have. It can be a bit of a pain keeping my standard installed apps updated across all of these.

I’m getting too used to my Android phone and Tablet auto updating their apps with little or no interaction – what I wanted was the same for more of the apps I use on the various PCs I use.
I haven’t quite got a full solution for it, but I do have a big step toward it – Portable Apps.image

Portable Apps are pretty good at keeping themselves updated, but the pain is the configuration. For example when I add a command to Executor (my launcher of choice) I had to update it on all machines, same with adding a new site to the Filezilla Site manager or Putty – it needed to be updated across all machines.
I could of course store the Portable Apps on a memory stick and carry that everywhere – but then the challenge is – carrying it everywhere.

So I have a solution that brings the ease of Portable Apps with the omnipresence capabilities of my free 25GB SkyDrive account (but you could use any file sync/share application).

imageI have a folder in SkyDrive that I have installed my chosen Portable Apps to, so they turn up on every machine.
I also have an install folder with tools and scripts that I run on each new machine that I install SkyDrive on that gives me common locations for the apps (regardless of the user I am logged in as), updates the PATH variable, adds apps to the Start folder and the like

The script does a number of things :-

It creates symbolically linked folders so I can go to c:\apps instead of c:\users\kenh\skydrive\apps (or different usernames on each machine)

rmdir c:\tools
rmdir c:\apps
rmdir c:\scripts
mklink /d c:\Tools "%userprofile%\SkyDrive\Tools"
mklink /d c:\Scripts "%userprofile%\SkyDrive\Scripts"
mklink /d "c:\Apps" "%userprofile%\SkyDrive\Apps"

It adds some data to the registry

regedit.exe /f CommandPromptHere.reg

It uses a tool called xxmklink (from the makers of xxcopy) to add a shortcut to Executor to the start up folder so that it runs every time Windows starts.

xxmklink "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup\Executor.lnk" "C:\Apps\PortableApps\Executor\Executor.exe" "" "C:\Apps\PortableApps\Executor"

It starts some applications

START "C:\Apps\PortableApps\Executor\Executor.exe"
START "C:\Apps\Start.exe"

And the final thing it does (currently) is to update the PATH variable using pathman.exe

pathman.exe /as c:\tools

This makes my life much easier, I can be the same kind of productive regardless of the machine I am working on – they all have the same configuration, versions of software and paths, and the best bit is that when Portable Apps updates itself on one machine, it is reflected on all others within a few minutes.

I need to look at how I can extend this further, with introducing more portable apps to replace heavyweight desktop installs. I’ll keep you updated.

Reading List – March 2010

After a brief hiatus (i.e. hectic work schedule for a few months), I am back to reading. The list is currently :-

Actually, that is wrong. I picked up ‘ReWork’ by the 37 Signals guys and read it cover to cover, so that’s no longer on the list 😉   – what a great book. Full of down to earth pragmatic advice and common sense (as you’d expect from these guys), a ton of snippets to take away and really inspiring. I must read this again to make sure I got everything.

GEO 51.4043388366699:-1.2875679731369

Enabling virtualization when booting from VHD

imageI ran into some trouble with Hyper V the other day – I had booted from a VHD into Windows Server 2008 R2 and was trying to start a VM – I got the usual  ‘The virtual machine could not be started because the hypervisor is not running” error.
I had just had a BIOS failure on the machine so I figured it may have switched hardware virtualization support off in the BIOS when it reloaded the defaults.

Checking the BIOS, I found it was switched on – strange. I Googled a bit but everything seemed to be around flipping the setting in BIOS, when I knew to be correct.
Some further investigation around the boot environment and BCDEDIT settings I found the parameter “HypervisorLaunchType”, thinking this could well be connected, I set the parameter to “auto” in the BCD configuration:

BCDEDIT /set {big-long-guid} hypervisorlaunchtype auto 

This fixed it !!
So now all my BCD configurations go like this:

BCDEDIT /copy {current-or-guid} /d "New Boot Option"
BCDEDIT /set {new-guid} device vhd=[V:]vmimage.vhd
BCDEDIT /set {new-guid} osdevice vhd=[V:]vmimage.vhd
BCDEDIT /set {new-guid} detecthal on
BCDEDIT /set {new-guid} hypervisorlaunchtype auto


August 2008 Reading List

I’ve just started on a renewed reading campaign. Here’s the books I just ordered :

To keep things up on the technical side, I recently received Professional ASP.NET 3.5, so I have that to plough through also.

I am also attending the Business of Software 2008 conference in Boston next month, where some of the sessions sound really interesting. I particularly liked the title of this Pecha Kucha session by Bob Pritchett, entrepreneur and author : Fire someone today and other surprising tactics for making your business a success

GEO: 51.4043006896973 : -1.28754603862762

Workplace Productivity Tip 2

image This is the second in a series of tips about Workplace Productivity. If you want to get noticed, promoted, a pay rise or simple get out of the door quicker at the end of the day then these may be helpful.

Understand the definition of your success.

Mike is told by his boss to get rid of all the garbage in the back office. His boss leaves for the day, Mike rolls his sleeves up and cracks on with the task of moving all the garbage in the backroom to the skip/dumpster out back. It’s back breaking work, but he gets it done just as his boss is returning to the office at the end of the day. His boss hits the roof !


Boss: What the hell have you been doing all day ?
Mike: Well I got rid of all the garbage like you said.
Boss: I didn’t mean do it yourself, I meant call in the cleaning contractors to do it, now you’ve wasted a whole day and we needed to get the new packaging for widgets finished – you’ll have to stay late and finish that.  Jeez, you binned the old Monitors as well, they were supposed to go to charity.
Mike (under his breath): Tosser…
Boss (under his breath): Bloody idiot…

This is a classic miscommunication problem – who is at fault ? The boss for not clearly defining the task ? Mike for not questioning to get a full understanding of what was expected of him ?Both in my opinion.

Regardless of who you think is to blame, you need to ensure it doesn’t happen to you, and you cannot force your boss / colleagues to explain every task in detail, so the onus is on you to get a full understanding of the task.

Ask Questions
You said get rid of the garbage, do you want me to actually move it ?
When do I need to have it done it by ?
(if the response is ‘as soon as possible’ then clarify with another question – ‘is the end of the day acceptable’

Set Expectations
Okay, I can do that, there’s a lot of garbage there though, it’s likely to take me all day.
That new packaging for widgets stuff I was working on will have to wait.

Restate the Task
Okay, just to be clear, I’m going to take all the garbage from the back room and move it to the skip/dumpster out back. There’s a lot of garbage so it’ll take me all day and the new packaging for widgets will have to wait till tomorrow.

Understanding the definition of your success is key. If you do not understand what your success looks like, how can you get there.

There is a lot more to cover here that helps with getting a better (and bigger picture) understanding of your success – interviewing your boss, agreeing priorities, understand others priorities in relation to yours, but we’ll save those for another post.

GEO: 51.4043059062107 : -1.28754615783691

Workplace Productivity Tip 1

image This is the first in a series of tips about Workplace Productivity. If you want to get noticed, promoted, a pay rise or simple get out of the door quicker at the end of the day then these may be helpful.

Get a system in place for recording your task list / projects / todo. It must be :-

There should be no opportunity for items to be forgotten, skipped or missed. If it’s on your list then it gets actioned (even if that action is to discard it). There is nothing worse than hearing someone saying ‘oh yeah, I forgot about that’ – it makes me think you didn’t my request seriously. Even worse is hearing someone saying ‘oh yeah, I wrote that down somewhere but lost it’ – that makes me think you’re an absent minded fool that I shouldn’t even trust to make a list correctly.

Easy To Use
You don’t want to create extra work for yourself, it’s about productivity. If it takes longer than a few seconds to jot down a new task or action a task then it’s not efficient. Likewise the organization / management of that list should not require more than a couple of minutes a day.

To Hand
If it’s not to hand then it wont get used. Keep it close, take it with you to meetings, keep it open on your desk. For electronic systems if it requires hunting through 3 levels of start menu, opening the app, putting it in the right mode, waiting for the most recent list to load etc then it’s not something you’ll use to take ‘quick’ notes.

In My Opinionimage
A paper based system is based (notepad, Moleskine, notebook whatever). I prefer this, and think it is considerably better than a PC based solution for a number of reasons :

  • People get annoyed at others in a meeting typing away on a laptop. There is always a suspicion that your updating Facebook, checking mail or whatever (especially if you laugh/snigger at something).
  • A paper notebook is considerably easier to carry around (less cables). If you don’t always carry your laptop around (and in a state that can be working within a few seconds) then you have to rely on memory to record tasks – this doesn’t work.
  • I never annoy everyone in a meeting by having to get up, fiddle about in my bag for a power block, move chairs around to find a socket and get some juice into my laptop before the final 4% of battery life fade.
  • There is a certain satisfaction to seeing a number of items crossed off a list (as opposed to just a shorter list). It gives much more of an impression of getting through your workload, than a view of just a smaller workload ahead of you.

image This is a quick sample of my (high level) system. Page is dated and has a number of tasks listed, one per line.

A task is done if it is checked, has been discarded if it is crossed and if it has a right pointing arrow against it then it has been ‘carried forward’ to another page / task list. this way I know that looking back to any older page, every line should have a sign against it (it is easily visible if any do not, so nothing slips through a gap).

A couple of other indicators I use are peoples initials if I have delegated to them or am awaiting a response and to the right of the task 9where I often make additional task notes, I put a date in square brackets if it has a deadline.

Simple, but effective. What system do you use ??

GEO 51.4043197631836:-1.28760504722595 

A couple of handy scripts

I have been updating some of my ‘magicwords’ for SlickRun recently. This a great tool for getting focus on a particular task. Instead of having to mess about opening folders, word documents, web sites all in preparation for a task you can enter one ‘magicword’ and have it do all that work for you.sr_header

For example when we (C2C) release a new hotfix the process requires :

  • Review of the technical notes / fix details (from a database report)
  • Grab all the relevant files into a .zip package (I really should have this section automated)
  • Update the ‘versions’ xml file that our app checks so that end users get notified of the fix availability
  • Post the zip file containing the hotfix to our support website.

(in fact I really should automate ALL of this)

Anyway, there were a couple of things that I had wanted to do to make SlickRun a touch better at getting this environment set up for me…

The first was to minimize all current windows (before opening the set of new ones)
The second was to automatically post form data to a website.

Both of these required a little scripting….


' Minimize all windows to the taskbar
' Ken Hughes
' 23 Jan 2008

Set objShell = CreateObject("Shell.Application")
Set objShell = Nothing

Just run the script for the results….



' HTTP POST script
' Post form data to a url
' Ken Hughes
' 23rd Jan 2008

' Check cmd line args
If (WScript.Arguments.Count <> 2) Then
    ' none - show usage
    Wscript.echo ""
    Wscript.echo "USAGE: httppost.vbs url ""data"""
    ' got them - so post the data
    sURL = Wscript.Arguments(0)
    sFormData = Wscript.Arguments(1)

    Dim objIE
    Set objIE = CreateObject("InternetExplorer.Application")
    objIE.Visible = True
    objIE.Navigate sURL, , , sFormData, "Content-Type: application/x-www-form-urlencoded;"
End If

Run the script with the URL and the post data as command line parameters – for example httppost.vbs “field1=value1&field2=value2”

GEO 51.4043197631836:-1.28760504722595

Todo.txt scripts

I’ve been spending a bit of time at LifeHacker recently, there is some pretty good tips over there (it’s where I found the PointUI for windows mobile 6). lifehacker-book-cover-sm

One of the posts I came across was this The command line tool caught my eye, as I always have a todo.txt hanging around on my desktop, or often a ‘todo list’ email languishing in my inbox.

Baulking at the idea of installing Cygwin to get a bash shell and getting to grips with ‘another’ scripting tool / language, I decided to port it to plain old VBScript.

The first thing was to set the systems default scripting host to cscript instead of wscript (wscript directs all input/output to windows instead of the command line). To do this simply open a command prompt and enter :

cscript //h:cscript //s                           (NOTE: to change back simply use cscript //h:wscript //s)

Then there is a whole bunch of code around parsing of the command line arguments and manipulation of text files – simple stuff really. There are two aspects not implemented in this version.image

  • Output colouring (the standard windows command line does not support this
  • The ‘list’ output does not sort the entries alphabetically (I may get around to this later…)

It follows most of the features of the original (see the details here), in the example displayed todo.vbs has been shortened to t.vbs and you can shorten the ‘actions’ (optionally list becomes l, add becomes a, replace becomes rep, append becomes app, prioritize becomes pri, archive becomes arc and do becomes d – it’s all clearly visible from the script source)

The script source is attached to this post, feel free to use / modify / ping me with questions…

t.vbs (5.24 KB)

GEO 51.4043197631836:-1.28760504722595

The killer UI for Windows Mobile

I am totally blown away by this. This is (IMHO) exactly what Windows mobile has been waiting for.


I have downloaded and am using this on my HTC TyTN II (Kaiser) – works like a dream, very easy to use and responsive to finger touch / navigation.
There are a number of known issues with it and some reports of it not being great on devices without touch screens, but run (seriously, run very quickly) over there and grab a copy.

pointui1 pointui2 pointui3 pointui4 pointui5

It is still in beta and the guys at Pointui have made it free (paypal donation optional). Unfortunately it does not cover all apps and aspects of the Windows Mobile UI, but the parts they have covered off are stunning – when these folks get all the common apps covered (Contacts, Dialer, Mail etc) then it will be incredible!

I love the list of known issues they have on the release announcement on their forums – it includes : Not enough time in the day and Red Bull wearing off – classy.

GEO 51.4043197631836:-1.28760504722595

Automating Installs

I was spending far too much time installing OS’s – virtual machines, lab machines etc.

Unattended In order to automate / streamline this I wanted to look at not just the Windows tools as well as other options. Remote Installation Service (RIS) and unattended.txt files go so far, but during my investigations I came across ‘Unattended‘. This open source tool takes unattended.txt, mixes in silent installs for hundreds of other common applications and supercharges the whole lot…

So the deal is, you extract some files from 4 zip archives, configure a DNS alias, share the folder, copy over the i386 folder from your OS CD/DVD, burn an ISO (or create a boot disk) image and your done – 25 minutes end to end.

The boot CD/Disk loads some network drivers, maps a Z drive to ‘ntinstallinstall’ (the machine and share with the files and OS on it) and passes control to a bunch of Perl scripts, these ask some questions from which it creates an unattended.txt file and executes the OS install (reboots and all). When the install completes it can also (optionally) run silent installers for other applications (Office, Open Office, Acrobat Reader, PDF Creator, Visual Studio, Perl etc..) as well as Windows Updates and critical fixes (they keep an up-to-date list on the homepage).

So, in summary, after booting from the install CD then 2 minutes of console based questions I can leave things for an hour or two and come back to a fully installed Windows OS, office applications, sales tools, developer tools – whatever. The scripts that install the additional apps are customizable (you can even enter your product keys) and you can build up suites from individual scripts (so I can have a script to install Visual Studio, another for the MSDN library, another for each of the various developer tools and then I can combine them all into a ‘developer_machine’ script…

Have a look – if you are doing more than one install (even just two) then this can save you time…