Kitkat update on Nexus 4 fails
The trouble I encountered was that the fastboot program could not find my phone even though it was in bootloader mode. The solution was to run fastboot as sudo, but then the problem changed to be that sudo didn’t have the path to fastboot so I needed to give the explicit path to that as well: sudo ./fastboot devices worked (when I was in the directory android-sdk-linux/platform-tools). So I figured that I needed to change two things in the setup instructions: 


run fastboot as sudo, and  
add explicit paths in the flash script. 


I've written a blog post that gives step-by-step instructions if anyone else needs this:
How to update your Nexus 4 to Android 4.4