Nexus 5 unable to reflash I have a nexus 5 which has ubuntu touch on it. The OS is broken and won't boot. I am trying to flash CyanogenMod to it, i've hooked it up to my ubuntu server, and am following this: https://wiki.cyanogenmod.org/w/Install_CM_for_hammerhead

However when i get to the point of adb push to get the firmware onto the phones local storage i get:

error: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set

And on adb devices it says unauthorised. Since i have no booting OS on this phone, how can i get around this shit so i might complete my flashing process?

I've installed the Cyanogenmod recovery environment successfully and am able to boot into this.
Issues like this this are often corrected by returning to a "known good configuration" before processing additional changes.

I would suggest returning to the current official Google firmware via fastboot, then verify the device is booting and operating properly, then you can flash custom recovery and install a third party ROM such as CyanogenMod.

Instructions and factory images with flashing scripts are available directly from Google at their Factory Images for Nexus Devices page.