[AT&T HTC One (M7)] gunnyman:
Want to unlock your bootloader to install a custom recovery and root your One but have no idea how because you have a Mac?

Never fear, Gunnyman is here. :D

The procedure is actually pretty painless and only takes a few minutes

Some prerequisites:

ADB and Fastboot binaries for OS X, I've attached them to this post.

Your recovery of choice, I'm using Clockwork Mod Recovery, because TWRP seems to have problems with some Aroma installer based ROMS. Get CWM for the One from here

SuperUser.zip

a Unix friendly text editor. I really like Text Wrangler and it's free.

Android File Transfer for Mac macs don't work with MTP mode without this.

In developer Options on the phone, turn on USB Debugging

EDIT:

Thanks to user Shivasmith I now know you can skip textwrangler and

If you hold down the "Alt" (i.e. Option) key on the Mac keyboard in terminal you can do a "column select."

So when you generate the codes for the HTCdev unlock website, you can just do a straight copy-paste without going into TextWrangler. It made it that much quicker

So thanks for the tip!

I've been using macs for 10 years and never knew that.

1. Unzip the adb and fastboot binaries and put them where you can find them. I have a directory on my Mac called /Android and that's where my phone stuff lives, but you can put it anywhere.

2. Put the cwm recovery (or twrp if you prefer) in the same folder as adb and fastboot.

3. Got to htcdev.com and create an account there if you don't already have one.

4. Log in to htcdev.com and choose unlock bootloader.

5. pick the last option for Unlisted device.

6. Open a terminal window and navigate to where you installed fastboot,adb, and your recovery eg: cd /Users/Gunnyman/Android

7. In Terminal execute the following commands ./adb reboot bootloader once in bootloader mode In terminal execute the following command: ./fastboot oem get_identifier_token

8. Open Text Wrangler

9. Copy the output from the terminal window into Text Wrangler make sure you include every line AFTER "please cut the following message"

10. Use Text Wrangler to DELETE (bootloader) from every line and make sure the columns line up exactly.

11. Copy and Paste this output into the box you are provided on HTC Dev. This part is quite annoying, getting the lines to line up.

12. Submit your token. When successful you will be sent a key via email.

13. Put the Unlock.bin file you got via email in the same directory as adb and fastboot on your mac.

14. execute the following command in terminal with the phone in fastboot mode ./fastboot flash unlocktoken Unlock_code.bin

15. Say yes to the prompts on the phone. Bootloader will unlock and the phone will be factory reset (there is NO way to avoid this)

16. OK Now the bootloader is unlocked. Time to install a recovery. In Terminal ./adb reboot bootloader

17. In terminal ./fastboot flash recovery name_of_the_recovery.img

18. After recovery has flashed POWER DOWN PHONE COMPLETELY Then restart it

19. connect phone to the Mac Android File Transfer should fire up

20. Put the Superuser.zip file on your phone

21. in Terminal ./adb reboot recovery

22. Flash the SuperUser.zip in recovery.

23. Pat yourself on the back your phone is now rooted.