Bored of the standard Android OS on your Nexus 5X? You might be interested in installing LineageOS, a free and open-source operating system for various devices based on the Android mobile platform. I created this post partly as a guide, and partly as a reminder for when I need to do this again in three months. This was written on 1st of March 2018.
Prerequisite downloads
- Download TWRP to your Downloads folder.
- Download LineageOS package to your Downloads folder.
- Download Google Apps (arm64 version) to your Downloads folder.
Unlock the bootloader
- Enable USB debugging on phone.
- Toggle OEM Unlock on phone.
- Run
brew cask install android-platform-tools
in terminal.
- Plug phone into computer.
- Allow USB debugging on the phone using the popup.
- Run
adb reboot bootloader
in terminal.
- Run
fastboot devices
to verify the computer can find the phone.
- Run
fastboot flashing unlock
in terminal.
Install a custom recovery package using fastboot
- Run
adb reboot bootloader
in terminal.
- Run
fastboot devices
to verify the computer can find the phone.
- Run `~/Downloads
- Run
fastboot flash recovery twrp-x.x.x-x-bullhead.img
. Change the file name to reflect the TWRP .img
file you downloaded in Step 1.
- Turn the phone off.
- Hold the
Volume Down
and Power
buttons down until you see the fastboot menu.
Install LineageOS from recovery
- Run
adb push filename.zip /sdcard/
. Change the filename to reflect the LineageOS .zip
file you downloaded in Step 1.
- Run
adb push filename.zip /sdcard/
. Change the filename to reflect the Google Apps .zip
file you downloaded in Step 1.
- On the phone, select Wipe and then Advanced Wipe.
- Select Cache, System, and Data.
- Swipe the bar at the bottom of the screen to wipe the partitions.
- Go back to the main menu using the back arrow at the bottom of the screen.
- Select Install.
- Navigate to
/sdcard
and select the LineageOS .zip
file you copied to the phone in Step 3.
- Select Add another ZIP.
- Navigate to
/sdcard
and select the Google Apps .zip
file you copied to the phone in Step 3.
- Follow the on-screen prompts to install the packages.
- When the installation has finished select Reboot, and then System.