#!/bin/bash

set -e;
source "build/envsetup.sh";

### ASB
## Platform
#repopick -t U_asb_2024-05

#repopick -f 390159 # console root
#repopick -t radio-1.4-wrapper

repopick 391719 391717 # g12
repopick -p 391713 # aml/common
repopick 391739 # atv key

repopick -t 14-automotive

repopick -t tegra-xts-u

#repopick 381384 # sabrina 12

wait

### Kernels
## AMLogic
# amlogic-4.9-pie - ?
# amlogic-4.9 - ?
# amlogic-5.4 - TO-REBASE

## Exynos
# exynos9610 - TO-REBASE

## Pixels
# wahoo - TO-REBASE
# b4s4 - DONE
# msm-4.14 - DONE
# msm-5.10-gki - DONE

## QCOM
# aura - DONE
# cheryl - DONE
# moto-msm8998 - TO-REBASE
# moto-sdm632 - TO-REBASE
# nokia-sdm660 - TO-REBASE
# nubia-sm8150 - DONE
# m1s1 - DONE
# mata - DONE
# moto-sm7325 - TO-REBASE
# pro1 - DONE
# pro1x - DONE
# moto-sm8250 - DONE

### CLO

#wait

### Platform

#wait

### Personal

## build/make
#changes=(
repopick -f 369796 # Sorry bro: 6 -> 3
#)
#repopick -f -P build/make ${changes[@]}&

## frameworks/base
changes=(
369786 # Alter model name to avoid SafetyNet HW attestation enforcement
369787 # keystore: Block key attestation for SafetyNet
369788 # AttestationHooks: Set shipping level to 32 for devices >=33
369789 # Limit SafetyNet workarounds to unstable GMS process
369790 # gmscompat: Apply the SafetyNet workaround to Play Store aswell
#369791 # gmscompat: Use Nexus 6P fingerprint for CTS/Integrity
#369792 # gmscompat: Make CTS/Play Integrity pass again
#374392 # gmscompat: Use new info
)
repopick -f -P frameworks/base ${changes[@]}&

## vendor/lineage
changes=(
#369794 # lineage: Disable privapp permission enforcement (make it log)
369795 # adb insecure by default
)
repopick -f -P vendor/lineage ${changes[@]}&

### Devices

## aura
#repopick 358627 # aura: Build Lineage Health HAL # 20
#repopick 346036 # 1080P resolution & techpack cleanup - BROKEN 1/4 screen weirdness - talk to Jake?
## Shipped
## TODO: RGB LED, Screen resolution settings

## b4s4
## Shipped

## beast
repopick -f 382738 # gx: DNM: wip libhidlbase_shim
repopick -f 373489 # [DNM] [TMP] HACK: Disable log level from being set
## TODO: Fix systemcontrol shim, BT, UI Glitches, OMX, SE Linux

## berlin
## Shipped

## cheryl
## Shipped
## TOOD: Screen resolution settings

## deadpool
#repopick -f 373491 # [DNM] g12: Set SELinux status to Permissive | for devkit testing
repopick -f 373490 # UART Log level
#repopick -t zero2-bringup
## (deadpool/wade/dopinder/devkits): Ready to Ship, (sabrina) TODO: Fix 12 FW, Test L1
## HOLD: ATV MTG

## floral
## Shipped
## TODO: Fix Face Unlock

## foster/sif
#repopick -f 374761 # vendor: Drop TegraZone
#repopick -f 374760 # SELinux
## TODO: https://gitlab.incom.co/CM-Shield/android_device_nvidia_foster/-/issues/21

## h918/h872
## Shipped

## m1s1
## Shipped

## mata
## Shipped

## nash/messi/lake_n
## (nash/evert/beckham/payton/lake/messi) Shipped, (messi_vzw) TODO: Fix verity, (chef) TODO: Fix Wi-Fi

## nx
repopick -f 386569 # [DNM] q-4.9: drop minlts to p level for compat
## TODO: A literal ass ton

## ohm
repopick -f -p 389208 # ohm defconfig import and cleanup
## TOOO: Finish bringup

## PL2
## Shipped

## pro1
## Shipped

## pro1x
#repopick 347906 # pro1x: Wire up FM Radio
## Shipped

## pstar
## Shipped
## TODO: Fix black screen issue

## river
## Shipped

## sphynx
## TODO: Sensors, Camera support

## tangorpro
## Shipped
## TODO: SUW Integration for Dock Setup (?)

## TP1803
## Shipped
## TODO: Lights HAL (?)

## troika/kane
## Shipped

## wahoo
## Shipped

wait
