How to flash Android M on Nexus:

While we recommend you to go through our guides for detailed steps and prerequisites, here are some steps to help you flash Android M on your Nexus:

Step 1:

Unzip the downloaded factory images for your device to a folder for later access. Locate the folder and type cmdto the address bar on Windows or launch terminal and change this folder with the one we saved, on Mac, Chrome OS or Linux. Make sure the terminal is running inside the unzipped folder if you’re operating on a Mac.

Step 2:

Your Nexus should be bootloader unlocked for the operation to succeed, if its not, better do that first. The locked device will enable all of you data to be wiped away that also includes settings and user data. Next, you have to have adb bootloader installed on your Mac, Windows or any other OS you are running. Install it if you don’t have it. Assuming you installed the adb bootloader, type the command written below in the terminal of the adb Bootloader. Hit Enter.

adb reboot bootloader

Type this In Fastboot:

fastboot oem unlock

Hit Enter and follow the onscreen instructions on your Nexus and choose to erase the device. This will remove everything on the Nexus, this might take a while.

Step 3:

This step will involve flashing the desired factory image to your Nexus device. Open the folder containing the Android M factory image in step 1. In the address bar, type cmd and type the commands written below and press enter. On a Mac, you can either access the terminal by creating a shortcut through setting or you can directly do it from the desktop.

All the necessary files will be flashed to your Nexus device to enable complete installation of the Android M update to your Nexus. Mac or other computer users will type the following command. This command has a purpose to transfer all of the necessary files to your Nexus device.

On Windows: Run flash-all.bat

On Mac: Run flash-all.sh using Terminal

On Linux: Run flash-all.sh

Step 4:

The files will be moved to your device and your Nexus device may restart. Don’t be surprised to see an Android bot and the moving logo, its part of the scheme. DO NOT UNPLUG OR POWER OFF YOUR DEVICE in this process, even though it may take a while or so. When its done, you will be asked to complete the setup that is when you can unplug your device from the computer.