Skip to content

Instantly share code, notes, and snippets.

@00Kush00
Forked from j-jith/miui-fastboot-howto.rst
Created December 31, 2020 18:26
Show Gist options
  • Select an option

  • Save 00Kush00/adaab77071454967a292c1175b3962fe to your computer and use it in GitHub Desktop.

Select an option

Save 00Kush00/adaab77071454967a292c1175b3962fe to your computer and use it in GitHub Desktop.

Revisions

  1. @j-jith j-jith revised this gist Nov 23, 2020. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -2,7 +2,7 @@ How to flash MIUI Fastboot ROM from Linux
    =========================================

    - Download the fastboot ROM suitable for your device from the `MIUI
    site <http://en.miui.com/a-234.html>`_ and extract the downloaded archive [edit: MIUI page is dead. Use `Xiaomi Formware Updater <https://xiaomifirmwareupdater.com/>`_]
    site <http://en.miui.com/a-234.html>`_ and extract the downloaded archive [edit: MIUI page is dead. Use `Xiaomi Firmware Updater <https://xiaomifirmwareupdater.com/>`_]

    - Download and extract the `Android SDK Platform Tools
    <https://developer.android.com/studio/releases/platform-tools.html>`_
  2. @j-jith j-jith revised this gist Nov 23, 2020. 1 changed file with 4 additions and 4 deletions.
    8 changes: 4 additions & 4 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -1,8 +1,8 @@
    How to flash MIUI Fastboot ROM from Linux
    =========================================

    - Download the ROM suitable for your device from the `MIUI
    site <http://en.miui.com/a-234.html>`_ and extract the downloaded archive
    - Download the fastboot ROM suitable for your device from the `MIUI
    site <http://en.miui.com/a-234.html>`_ and extract the downloaded archive [edit: MIUI page is dead. Use `Xiaomi Formware Updater <https://xiaomifirmwareupdater.com/>`_]

    - Download and extract the `Android SDK Platform Tools
    <https://developer.android.com/studio/releases/platform-tools.html>`_
    @@ -60,6 +60,6 @@ How to flash MIUI Fastboot ROM from Linux
    - You may need to run ``sudo ./flash_all.sh`` if you had to use ``sudo`` with ``fastboot``

    - Sit back and relax. The script needs no user interaction. After flashing the
    ROM, the scipt will reboot your device.
    ROM, the script will reboot your device.

    - Reboot will take quit a bit of time. Don't panic.
    - Reboot will take quite a bit of time. Don't panic.
  3. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 6 additions and 1 deletion.
    7 changes: 6 additions & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -46,10 +46,15 @@ How to flash MIUI Fastboot ROM from Linux
    - If the above line is missing, add it to the top of the script

    - Run the script (I've chosen ``flash_all.sh``)
    - Make the script executable (I've chosen ``flash_all.sh``)
    .. code:: bash
    $ cd path/to/extracted/ROM/archive
    $ chmod a+x ./flash_all.sh
    - Run the script
    .. code:: bash
    $ ./flash_all.sh
    - You may need to run ``sudo ./flash_all.sh`` if you had to use ``sudo`` with ``fastboot``
  4. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 0 additions and 1 deletion.
    1 change: 0 additions & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -38,7 +38,6 @@ How to flash MIUI Fastboot ROM from Linux

    2. ``flash_all_except_data_storage.sh`` - Flash ROM without erasing user data


    - Whichever script you decide to use, make sure that the interpreter is
    mentioned at the top of the script like
    .. code:: bash
  5. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -37,6 +37,7 @@ How to flash MIUI Fastboot ROM from Linux
    1. ``flash_all.sh`` - Flash ROM and erase user data

    2. ``flash_all_except_data_storage.sh`` - Flash ROM without erasing user data


    - Whichever script you decide to use, make sure that the interpreter is
    mentioned at the top of the script like
  6. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -34,9 +34,9 @@ How to flash MIUI Fastboot ROM from Linux

    - There are two scripts for flashing the ROM:

    1. ``flash_all.sh`` - Flash ROM and erase user data
    1. ``flash_all.sh`` - Flash ROM and erase user data

    2. ``flash_all_except_data_storage.sh`` - Flash ROM without erasing user data
    2. ``flash_all_except_data_storage.sh`` - Flash ROM without erasing user data

    - Whichever script you decide to use, make sure that the interpreter is
    mentioned at the top of the script like
  7. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -35,6 +35,7 @@ How to flash MIUI Fastboot ROM from Linux
    - There are two scripts for flashing the ROM:

    1. ``flash_all.sh`` - Flash ROM and erase user data

    2. ``flash_all_except_data_storage.sh`` - Flash ROM without erasing user data

    - Whichever script you decide to use, make sure that the interpreter is
  8. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -14,7 +14,7 @@ How to flash MIUI Fastboot ROM from Linux
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Connect your device to your computer using a USB cable and enable *USB
    Debugging* in your phone's settings. Check if your device is detected.
    Debugging* in your device's settings. Check if your device is detected.
    .. code:: bash
    $ adb devices
  9. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -13,7 +13,7 @@ How to flash MIUI Fastboot ROM from Linux
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Connect your device to your computer using a USB cable. Enable *USB
    - Connect your device to your computer using a USB cable and enable *USB
    Debugging* in your phone's settings. Check if your device is detected.
    .. code:: bash
  10. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -13,7 +13,8 @@ How to flash MIUI Fastboot ROM from Linux
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Check if your device is detected
    - Connect your device to your computer using a USB cable. Enable *USB
    Debugging* in your phone's settings. Check if your device is detected.
    .. code:: bash
    $ adb devices
  11. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -5,7 +5,7 @@ How to flash MIUI Fastboot ROM from Linux
    site <http://en.miui.com/a-234.html>`_ and extract the downloaded archive

    - Download and extract the `Android SDK Platform Tools
    <https://developer.android.com/studio/releases/platform-tools.html>`
    <https://developer.android.com/studio/releases/platform-tools.html>`_

    - Make sure ``adb`` and ``fastboot`` (components of platform-tools) are in your
    path
  12. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 5 additions and 5 deletions.
    10 changes: 5 additions & 5 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -2,13 +2,13 @@ How to flash MIUI Fastboot ROM from Linux
    =========================================

    - Download the ROM suitable for your device from the `MIUI
    site <http://en.miui.com/a-234.html>`_
    site <http://en.miui.com/a-234.html>`_ and extract the downloaded archive

    - Extract the downloaded archive
    - Download and extract the `Android SDK Platform Tools
    <https://developer.android.com/studio/releases/platform-tools.html>`

    - Install the Android SDK

    - Make sure ``adb`` and ``fastboot`` are in your path
    - Make sure ``adb`` and ``fastboot`` (components of platform-tools) are in your
    path
    .. code:: bash
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
  13. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 5 additions and 1 deletion.
    6 changes: 5 additions & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -10,6 +10,7 @@ How to flash MIUI Fastboot ROM from Linux

    - Make sure ``adb`` and ``fastboot`` are in your path
    .. code:: bash
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Check if your device is detected
    @@ -18,10 +19,12 @@ How to flash MIUI Fastboot ROM from Linux
    $ adb devices
    - If device is listed, reboot to bootloader
    .. code:: bash
    $ adb reboot bootloader
    - Check if your device is detected by fastboot
    .. code:: bash
    $ fastboot devices
    @@ -35,15 +38,16 @@ How to flash MIUI Fastboot ROM from Linux

    - Whichever script you decide to use, make sure that the interpreter is
    mentioned at the top of the script like
    .. code:: bash
    #!/bin/sh
    - If the above line is missing, add it to the top of the script

    - Run the script (I've chosen ``flash_all.sh``)
    .. code:: bash
    $ cd path/to/extracted/ROM/archive

    $ ./flash_all.sh
    - You may need to run ``sudo ./flash_all.sh`` if you had to use ``sudo`` with ``fastboot``
  14. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 0 additions and 1 deletion.
    1 change: 0 additions & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -10,7 +10,6 @@ How to flash MIUI Fastboot ROM from Linux

    - Make sure ``adb`` and ``fastboot`` are in your path
    .. code:: bash
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Check if your device is detected
  15. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -9,12 +9,12 @@ How to flash MIUI Fastboot ROM from Linux
    - Install the Android SDK

    - Make sure ``adb`` and ``fastboot`` are in your path

    .. code:: bash
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Check if your device is detected
    .. code:: bash
    $ adb devices
  16. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -10,6 +10,8 @@ How to flash MIUI Fastboot ROM from Linux

    - Make sure ``adb`` and ``fastboot`` are in your path

    .. code:: bash
    $ export PATH=path/to/android/sdk/platform-tools:$PATH
    - Check if your device is detected
  17. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -4,7 +4,7 @@ How to flash MIUI Fastboot ROM from Linux
    - Download the ROM suitable for your device from the `MIUI
    site <http://en.miui.com/a-234.html>`_

    - Extract the download archive
    - Extract the downloaded archive

    - Install the Android SDK

  18. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 6 additions and 6 deletions.
    12 changes: 6 additions & 6 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -8,7 +8,7 @@ How to flash MIUI Fastboot ROM from Linux

    - Install the Android SDK

    - Make sure ``adb`` and `fastboot` are in your path
    - Make sure ``adb`` and ``fastboot`` are in your path

    $ export PATH=path/to/android/sdk/platform-tools:$PATH

    @@ -24,13 +24,13 @@ How to flash MIUI Fastboot ROM from Linux

    $ fastboot devices

    - You may need to use `sudo` before fastboot if you get a permission denied
    - You may need to use ``sudo`` before ``fastboot`` if you get a permission denied
    error

    - There are two scripts for flashing the ROM:

    1. `flash_all.sh` - Flash ROM and erase user data
    2. `flash_all_except_data_storage.sh` - Flash ROM without erasing user data
    1. ``flash_all.sh`` - Flash ROM and erase user data
    2. ``flash_all_except_data_storage.sh`` - Flash ROM without erasing user data

    - Whichever script you decide to use, make sure that the interpreter is
    mentioned at the top of the script like
    @@ -39,13 +39,13 @@ How to flash MIUI Fastboot ROM from Linux

    - If the above line is missing, add it to the top of the script

    - Run the script (I've chosen `flash_all.sh`)
    - Run the script (I've chosen ``flash_all.sh``)

    $ cd path/to/extracted/ROM/archive

    $ ./flash_all.sh

    - You may need to run `sudo ./flash_all.sh` if you had to use `sudo` with `fastboot`
    - You may need to run ``sudo ./flash_all.sh`` if you had to use ``sudo`` with ``fastboot``

    - Sit back and relax. The script needs no user interaction. After flashing the
    ROM, the scipt will reboot your device.
  19. @j-jith j-jith revised this gist Mar 1, 2017. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -8,7 +8,7 @@ How to flash MIUI Fastboot ROM from Linux

    - Install the Android SDK

    - Make sure `adb` and `fastboot` are in your path
    - Make sure ``adb`` and `fastboot` are in your path

    $ export PATH=path/to/android/sdk/platform-tools:$PATH

  20. @j-jith j-jith created this gist Mar 1, 2017.
    53 changes: 53 additions & 0 deletions miui-fastboot-howto.rst
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,53 @@
    How to flash MIUI Fastboot ROM from Linux
    =========================================

    - Download the ROM suitable for your device from the `MIUI
    site <http://en.miui.com/a-234.html>`_

    - Extract the download archive

    - Install the Android SDK

    - Make sure `adb` and `fastboot` are in your path

    $ export PATH=path/to/android/sdk/platform-tools:$PATH

    - Check if your device is detected

    $ adb devices

    - If device is listed, reboot to bootloader

    $ adb reboot bootloader

    - Check if your device is detected by fastboot

    $ fastboot devices

    - You may need to use `sudo` before fastboot if you get a permission denied
    error

    - There are two scripts for flashing the ROM:

    1. `flash_all.sh` - Flash ROM and erase user data
    2. `flash_all_except_data_storage.sh` - Flash ROM without erasing user data

    - Whichever script you decide to use, make sure that the interpreter is
    mentioned at the top of the script like

    #!/bin/sh

    - If the above line is missing, add it to the top of the script

    - Run the script (I've chosen `flash_all.sh`)

    $ cd path/to/extracted/ROM/archive

    $ ./flash_all.sh

    - You may need to run `sudo ./flash_all.sh` if you had to use `sudo` with `fastboot`

    - Sit back and relax. The script needs no user interaction. After flashing the
    ROM, the scipt will reboot your device.

    - Reboot will take quit a bit of time. Don't panic.