These are the steps I
noted down when flashing custom ROM to update from HTC (Android 5.0) to Lineage OS
(Android 7.1). Yours should be pretty much similar.
Cyanogen OS is now replaced by Lineage OS.
1. Unlock
Bootloader from htcdev site for HTC using fastboot and adb
You can also get ADB files
from Android SDK
a.
fastboot oem get_identifier_token
b.
fastboot flash unlocktoken
Unlock_code.bin
Install TWRP recovery using fastboot and adb
a.
fastboot flash recovery
twrp-3.0.0-2-m7.img
b.
fastboot erase cache
You should now have these
files in your folder
adb.exe
AdbWinApi.dll
AdbWinUsbApi.dll
fastboot.exe
Unlock_code.bin
openrecovery-twrp-2.5.0.0-m7wls.img
SuperSU-v2.79-201612051815.zip
3. Backup
data
4. Root
the phone by flashing latest SuperSU via TWRP Install. Remember you are still
in old OS only now unlocked and rooted.
5. Download
the custom ROM OS and openGapps (for google apps)
6. Wipe
and then Flash Lineage OS followed by opengapps
Reference: https://www.youtube.com/watch?v=MLYJA6KqA5U
Happy Android folks!
I am using for my phone for last few months and it works great, except at few times when it crashes :-)