Skip to content

Commit

Permalink
templates: boot_stack, but dd
Browse files Browse the repository at this point in the history
To go alongside recovery_install_dd, for the few unfortunate devices
out there that don't have a fastboot at all.

Change-Id: Ibfee4559c4c732b0e59ea0c052583dd8394e7df6
  • Loading branch information
lifehackerhansol committed Aug 2, 2024
1 parent d53676b commit 6bbe3c5
Showing 1 changed file with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
## Flashing additional partitions

{% include alerts/warning.html content="This platform requires additional partitions to be flashed for recovery to work properly, the process to do so is described below." %}

1. Download the following files from [here](https://download.lineageos.org/devices/{{ device.codename }}).
{%- for partition in device.before_recovery_install.partitions %}
* {{ partition }}.img
{%- endfor %}
2. Place the files on the root of `/sdcard`:
* Using adb:
```
{%- for partition in device.before_recovery_install.partitions %}
adb -d push {{ partition }}.img /sdcard/{{ partition }}.img
{%- endfor %}
```
* You can use any method you are comfortable with. `adb` is universal across all devices, and works both in Android and recovery mode, providing USB debugging is enabled.
3. Now, open an `adb -d shell` from a command prompt (on Windows) or terminal (on Linux or macOS) window. In that shell, type the following commands:
{%- if device.is_ab_device %}
```
su
{%- for partition in device.before_recovery_install.partitions %}
dd if=/sdcard/{{ partition }}.img of={{ partition }}_a
dd if=/sdcard/{{ partition }}.img of={{ partition }}_b
{%- endfor %}
```
{%- else %}
```
su
{%- for partition in device.before_recovery_install.partitions %}
dd if=/sdcard/{{ partition }}.img of={{ partition }}
{%- endfor %}
```
{%- endif %}

0 comments on commit 6bbe3c5

Please sign in to comment.