[Paid Software Announcement and Discussion] nkk71:
you have an M8 right?

I have one (ruu mode flashable TWRP) here: https://www.androidfilehost.com/?fid=96039337900114512

here's how you flash it, and subsequently unlock using adb:

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot devices[/COLOR][/B]
SHxxxxxxxxxx fastboot [I][COLOR="Purple"]<- we are in bootloader[/COLOR][/I]

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot getvar all[/COLOR][/B]
(bootloader) version-bootloader: 3.19.0.0000
(bootloader) version-main: 3.28.401.9[I][COLOR="Purple"] <- note my current firmware[/COLOR][/I]
(bootloader) version-misc: PVT SHIP S-OFF
(bootloader) product: m8_ul
(bootloader) modelid: 0P6B10000
(bootloader) cidnum: 11111111
(bootloader) security: off
all: Done!
finished. total time: 0.125s

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot reboot-bootloader[/COLOR][/B]
rebooting into bootloader...
OKAY [ 0.018s]
finished. total time: 0.022s

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot oem rebootRUU[/COLOR][/B]
...
(bootloader) Start Verify: 0
OKAY [ 0.063s]
finished. total time: 0.064s

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot flash zip fw_M8_TWRP_2.8.6.0.zip[/COLOR][/B]
target reported max download size of 1826418688 bytes
sending 'zip' (12429 KB)...
OKAY [ 1.422s]
writing 'zip'...
(bootloader) zip header checking...
(bootloader) zip info parsing...
(bootloader) checking model ID...
(bootloader) checking custom ID...
(bootloader) total_image_number=1

(bootloader) start image[recovery] unzipping & flushing...
(bootloader) [RUU]UZ,recovery,0
(bootloader) [RUU]UZ,recovery,6
(bootloader) [RUU]UZ,recovery,12
(bootloader) [RUU]UZ,recovery,18
(bootloader) [RUU]UZ,recovery,26
(bootloader) [RUU]UZ,recovery,36
(bootloader) [RUU]UZ,recovery,67
(bootloader) [RUU]UZ,recovery,72
(bootloader) [RUU]UZ,recovery,78
(bootloader) [RUU]UZ,recovery,84
(bootloader) [RUU]UZ,recovery,90
(bootloader) [RUU]UZ,recovery,96
(bootloader) [RUU]UZ,recovery,100
(bootloader) [RUU]WP,recovery,0
(bootloader) [RUU]WP,recovery,96
(bootloader) [RUU]WP,recovery,100
(bootloader) ...... Successful
(bootloader) current_image_number=0

OKAY [ 2.999s]
finished. total time: 4.425s

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot reboot-bootloader[/COLOR][/B]
rebooting into bootloader...
OKAY [ 0.019s]
finished. total time: 0.023s

C:\ADB5_1.0.32>[B][COLOR="Blue"]fastboot getvar all[/COLOR][/B]
(bootloader) version-bootloader: 3.19.0.0000
(bootloader) version-main: 2.86.000.0 [I][COLOR="Purple"]<- my firmware wasnt actually changed
but any ruu mode flash will change this
2.86.000.0 is just my way of saying TWRP 2.8.6.0
you'll need to flash a firmware or ruu for
that to change again[/COLOR][/I]
(bootloader) version-misc: PVT SHIP S-OFF
(bootloader) product: m8_ul
(bootloader) modelid: 0P6B10000
(bootloader) cidnum: 11111111
(bootloader) security: off
all: Done!
finished. total time: 0.170s

-> enter RECOVERY, you should now be in TWRP 2.8.6.0, and then UNLOCK bootloader while in TWRP

C:\ADB5_1.0.32>[B][COLOR="Blue"]adb devices[/COLOR][/B]
List of devices attached
SHxxxxxxxxxx recovery [I][COLOR="Purple"]<- we are in recovery[/COLOR][/I]

C:\ADB5_1.0.32>[B][COLOR="Blue"]adb shell[/COLOR][/B]

~ # ←[6n[B][COLOR="Blue"]echo -ne "HTCU" | dd of=/dev/block/mmcblk0p2 bs=1 seek=33796[/COLOR][/B]
echo -ne "HTCU" | dd of=/dev/block/mmcblk0p2 bs=1 seek=33796
4+0 records in
4+0 records out
4 bytes (4B) copied, 0.070964 seconds, 56B/s
~ # ←[6nexit
exit

C:\ADB5_1.0.32>[B][COLOR="Blue"]adb reboot bootloader[/COLOR][/B]