Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Lenovo Tab M10 HD 2nd Gen wifi to Installer #249

Closed
wants to merge 12 commits into from
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ jobs:

- name: npm install
run: npm install
- name: npm install -g ts-node
run: npm install -g ts-node
- name: npm run lint
run: npm run lint
- name: npm run build
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ jobs:

- name: npm install
run: npm install
- name: npm install -g ts-node
run: npm install -g ts-node
- name: npm run build
run: npm run build

Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
"name": "ubports-installer-configs",
"version": "2.0.0",
"description": "Configuration files for the UBports Installer.",
"type": "module",
"files": [
"lib/",
"LICENSE",
Expand Down
4 changes: 3 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@
"compilerOptions": {
/* Basic Options */
"target": "es2015",
"module": "es2022",
"module": "CommonJS",
"lib": ["DOM", "es2022", "es2021"],
"outDir": "./lib",
"allowJs": false,
"declaration": true,
"sourceMap": true,
"importHelpers": true,
"downlevelIteration": true,
"esModuleInterop": true,
"moduleResolution": "Node",

/* Strict Type-Checking Options */
"strict": true,
Expand Down
187 changes: 187 additions & 0 deletions v2/devices/amar_row_wifi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,187 @@
name: "Lenovo Tab M10 HD 2nd Gen Wifi"
codename: "amar_row_wifi"
formfactor: "tablet"
aliases: [amar_row_wifi, X306F]
doppelgangers: []
user_actions:
confirm_model:
title: "Confirm your model"
description: "Please check that your device is a Lenovo Tab M10 HD Wifi (X306F)."
confirm_os:
title: "Confirm OS version"
description: "Your device must be running the Android 11 stock firmware before installing Ubuntu Touch. You can flash the device using spflash tools"
link: "https://github.com/rubencarneiro/amar_row_wifi/releases/download/1.0/Firmware.tar.xz"
unlock_phone:
title: "Unlock the bootloader"
description: "Before installing Ubuntu Touch you must unlock the bootloader of your phone manually. Follow the steps in the linked page if you haven't already."
link: "https://unlocktechy.com/lenovo-tab-m10-hd-gen-2-unlock-bootloader"
bootloader:
title: "Reboot to Bootloader"
description: "With the device powered off, press and hold the VOLUME DOWN + POWER until you see the fastboot on screen and plug the device into your PC via USB."
image: "phone_power_down"
button: true
bootloader_from_fastbootd:
title: "Reboot to Bootloader"
description: 'With the device still at the fastbootd screen, use the volume buttons to select "Reboot to bootloader".'
image: "phone_power_down"
button: true
recovery:
title: "Reboot to Recovery"
description: 'With the device still at the "FastBoot Mode", use the Volume buttons to switch to "Recovery Mode" and push the power button to confirm your selection.'
image: "phone_power_up"
button: true
fastbootd:
title: "Reboot to fastbootd mode"
description: 'With the device still at the "FastBoot Mode", use the Volume buttons to switch to "Recovery Mode" and push the power button to confirm your selection. Then select "Fastboot mode" from the list.'
image: "phone_power_up"
button: true
unlock:
- "confirm_model"
- "confirm_os"
- "unlock_phone"
operating_systems:
- name: "Ubuntu Touch"
options:
- var: "channel"
name: "Channel"
tooltip: "The release channel"
link: "https://docs.ubports.com/en/latest/about/process/release-schedule.html"
type: "select"
remote_values:
systemimage:channels:
- var: "wipe"
name: "Wipe Userdata"
tooltip: "Wipe personal data. This is necessary for first time installations."
type: "checkbox"
- var: "partition"
name: "Partitioning"
tooltip: "Changes partition sizes as required. Only necessary for first time installations."
type: "checkbox"
value: true
- var: "bootstrap"
name: "Bootstrap"
tooltip: "Flash system partitions using fastboot"
type: "checkbox"
value: true
prerequisites: []
steps:
### Ensure we always start in bootloader mode
- actions:
- adb:reboot:
to_state: "bootloader"
fallback:
- core:user_action:
action: "bootloader"
### Ensure the bootloader has been unlocked already
- actions:
- fastboot:wait:
- actions:
- fastboot:assert_var:
variable: "unlocked"
value: "yes"
fallback:
- core:user_action:
action: "unlock_phone"
### Flash important partitions (if requested)
- actions:
- core:download:
group: "firmware"
files:
- url: "https://github.com/rubencarneiro/amar_row_wifi/releases/download/1.0/boot.img"
checksum:
sum: "d2410a0a730ceeeef19d30773dabe118c818af006c3c52e960b3aeee87cfa9c5"
algorithm: "sha256"
- url: "https://github.com/rubencarneiro/amar_row_wifi/releases/download/1.0/recovery.img"
checksum:
sum: "11145535baecb111b9a4e07c67a39c407366e7a7b261b795b02b70a09e27c0bd"
algorithm: "sha256"
- url: "https://github.com/rubencarneiro/amar_row_wifi/releases/download/1.0/dtbo.img"
checksum:
sum: "41bef15140c81d701ea0ff0bf9e0cd293c2419d12606d930496ae551c1e8e716"
algorithm: "sha256"
- url: "https://github.com/rubencarneiro/amar_row_wifi/releases/download/1.0/vbmeta.img"
checksum:
sum: "debc86fc6832bbc8f76cbeca2319a8768c03c19ac8d67dca61bf414b52ba2fb9"
algorithm: "sha256"
condition:
var: "bootstrap"
value: true
- actions:
- fastboot:flash:
partitions:
- partition: "boot"
file: "boot.img"
group: "firmware"
- partition: "recovery"
file: "recovery.img"
group: "firmware"
- partition: "dtbo"
file: "dtbo.img"
group: "firmware"
- partition: "vbmeta"
file: "vbmeta.img"
group: "firmware"
flags:
- "--disable-verity"
- "--disable-verification"
condition:
var: "bootstrap"
value: true
### Set up logical partitions (if requested)
- actions:
- fastboot:reboot_fastboot:
fallback:
- core:user_action:
action: "fastbootd"
condition:
var: "partition"
value: true
- actions:
# Remove all unused logical partitions
- fastboot:delete_logical_partition:
partition: "product"
# Increase space for system_a for UT installation
- fastboot:resize_logical_partition:
partition: "system"
size: 3978565472
condition:
var: "partition"
value: true
- actions:
- fastboot:reboot_bootloader:
fallback:
- core:user_action:
action: "bootloader_from_fastbootd"
condition:
var: "partition"
value: true
### Wipe userdata (if requested)
- actions:
- fastboot:erase:
partition: "userdata"
condition:
var: "wipe"
value: true
- actions:
- fastboot:format:
partition: "userdata"
type: "ext4"
condition:
var: "wipe"
value: true
### Systemimage installation steps
- actions:
- fastboot:reboot_recovery:
fallback:
- core:user_action:
action: "recovery"
- actions:
- systemimage:install:
verify_recovery: true
- actions:
- adb:reboot:
to_state: "recovery"
fallback:
- core:user_action:
action: "recovery"
slideshow: []
Loading
Loading