With the launch of the Nexus 4, Google has released the Jelly Bean 4.2 factory image for the Galaxy Nexus. Though there have been reports of Galaxy Nexus users getting OTA updates, some just don’t want to wait. You can download it from here. Installation is pretty simple, just follow these steps.
Download the factory image for your device here. (GSM Galaxy Nexus = yakju/takju, Verizon Galaxy Nexus = toro, Sprint Galaxy Nexus = toroplus)
Ensure fastboot is in your path. On Mac and Linux you can do this by running `PATH=$PATH:/path/to/android-sdk/platform-tools` in the Terminal.
Plug your phone into your USB port and unlock your bootloader with `fastboot oem unlock`.
Boot your phone into fastboot mode by holding down both volume keys and pressing the power button to turn on the phone. Alternatively you can use `adb reboot bootloader` in the Terminal to reboot your phone in fastboot.
From the extracted download directory, run `./flash-all.sh` to flash the rom to your phone.
Lock your boot loader with `fastboot oem lock`.
Keep in mind that flashing the factory image to your phone will delete all user data by default, so back up your phone.