Mad World #Save_GAZA: Free Palestine  

Search

tv-vibehack: Reversible Android TV Cleanup over ADB

tv-vibehack: Reversible Android TV Cleanup over ADB

tv-vibehack disables manufacturer telemetry and preloaded apps on Android TV or Google TV devices over Wi‑Fi, then installs a custom tvOS-style launcher. It uses pm disable-user to disable packages without uninstalling them, and a supplied restore script can re-enable them. The project is open source under the MIT licence; the Outfit typeface is SIL Open Font licensed.

What tv-vibehack's workflow covers

The project provides a prompt for Claude Code or a similar shell-enabled coding assistant, a set of Python ADB-over-TCP tools, a small Android launcher, and device-specific debloat lists. The documented workflow backs up the TV's package state and settings, disables unwanted packages, builds and installs the launcher, and makes it the default home screen.

Every operation uses standard Android tooling: the TV listens on port 5555 once you enable USB debugging in its developer options, and the assistant or shell scripts execute pm disable-user --user 0 commands over ADB.

The launcher (com.gathin.tvhome) is written in Java with AndroidX RecyclerView, compiles against Android API 34, targets API 29, requires at least API 26, and weighs about 1.6 MB. It provides a four-app dock, a grid of remaining apps, HDMI/AV/Live TV input controls, Wi‑Fi and Settings shortcuts, a clock and greeting, and an optional clock screensaver. It declares no video backgrounds, blur effects, network polling or background services.

The repository includes tools/disable.sh to apply a debloat list and tools/restore.sh to reverse it. The restore script re-enables every package in the same list, sets a stock home activity, and resets animation settings. You must keep the debloat list you applied: the restore script reads it to determine which packages to re-enable. Any package that was disabled before you ran disable.sh will be enabled after restore.sh.

Check platform scope and ADB prerequisites

The project's README states support for Android TV and Google TV devices from Xiaomi, Redmi, TCL, Hisense, Sony, OnePlus, Realme, Nvidia Shield and most others. Samsung Tizen, LG webOS and Amazon Fire TV are explicitly excluded: they run different operating systems or prevent third-party launchers from taking over the Home button.

The examples/ directory holds confirmed debloat lists for Xiaomi Mi TV 4A (Android TV 10), Xiaomi MiTV-AXSO0 (Android TV 9), TCL 55" 4K Google TV 2023 (Google TV 12), SANYO ATV R2 (Android TV 9), and OnePlus TV (Google TV 14). One reported firmware variant, TCL ak30a5 (China, Android TV 9, no Google Mobile Services), refuses any launcher APK that lacks the vendor's signing certificate and cannot use the project's custom launcher at all, though debloating still works on that device.

On the TV, open Settings → Device Preferences → About, press Build seven times, go back to Developer options, and turn on USB debugging. Some TVs also show a Network debugging or ADB debugging toggle; turn it on too. Keep the TV and computer on the same Wi‑Fi network. When you first connect, the TV displays an "Allow USB debugging?" prompt; approve it to authorize the computer's public key.

For manual use, the Python tools require Python 3, a virtual environment, and the dependencies adb-shell, rsa and cryptography, listed in tools/requirements.txt. The launcher build requires JDK 17 and Android SDK platform 34 with build-tools 34.0.0. On macOS, brew install openjdk@17 android-commandlinetools then sdkmanager "platforms;android-34" "build-tools;34.0.0" installs the prerequisites. On Windows, the PowerShell scripts use Android Studio's bundled JDK and SDK location if present.

Run the documented cleanup and launcher setup

To use the assistant workflow, paste the prompt from PROMPT.md into Claude Code or another assistant with shell access, fill in your TV model, and answer the checklist questions: which streaming apps you use, which four go in the dock, and whether to keep the voice assistant, Chromecast and firmware updates. The assistant discovers installed packages, proposes a debloat list, applies it, builds the launcher, installs it, and sets it as the default home screen. The project's README reports the workflow took one afternoon on a 1 GB Mi TV the first time, and about fifteen minutes with the repository as context.

For manual operation, first back up the TV's package state and settings to a local folder. Then compare your TV's exact model and firmware against the confirmed examples and inspect every package in the list before applying it. Disabling essential services can make the TV unusable; the project reports one Hisense test that entered Android Recovery after overly aggressive package disabling, and "Try again" plus restore.sh recovered it.

Set TV_HOST to the TV's IP address and run:

Terminal
python3 -m venv tools/venv
tools/venv/bin/pip install -r tools/requirements.txt
export TV_HOST=192.168.1.50

tools/venv/bin/python -I tools/tv.py --probe

The --probe command prints the TV's model, device codename, Android version, SDK level, build ID and manufacturer. Confirm these match the debloat list header before applying it:

Code
tools/disable.sh examples/xiaomi-mi-tv-4a/debloat.txt

disable.sh reads the debloat list, filters out comments and blank lines, generates pm disable-user --user 0 commands, and sends them to the TV in batch mode, one command per shell call. Chained pm commands in a single shell invocation may silently stop after the first, so the scripts use --batch to run each separately on the same connection.

To build and install the launcher, configure the dock order, hidden apps, Live TV package and column count in launcher/app/src/main/res/values/config.xml, then run:

.env
TV_HOST=192.168.1.50 launcher/build-and-install.sh

The script creates a Gradle debug build, transfers the APK to /data/local/tmp/tvhome.apk on the TV as base64 chunks (because large pushes through the Python ADB client can hang), installs it with pm install -r, assigns it as the default home activity with cmd package set-home-activity --user 0 com.gathin.tvhome/.MainActivity, and disables the stock launcher.

On Android 9, set-home-activity requires a full component name rather than a bare package name; the repository's PowerShell and bash scripts now pass the component. One Xiaomi Google TV firmware continued opening Google TV or Setup/Recovery after set-home-activity returned success, and required explicit device-owner approval to disable both the launcher and the setup/recovery package.

Check changes and use the restore script

The prompt instructs the assistant to verify each change by injecting remote key presses over ADB, taking a screenshot from the TV, and inspecting it before moving on. The repository does not document a method to verify that advertisements inside streaming apps or other services have been removed; it only confirms that manufacturer recommendation rows, analytics services, and preloaded apps are disabled at the package level.

To reverse the debloat, identify your TV's original launcher package and component. Run:

.env
TV_HOST=192.168.1.50 tools/restore.sh examples/xiaomi-mi-tv-4a/debloat.txt [stock.launcher.package]

The script generates pm enable commands for every package in the list, re-enables the stock launcher, sets it as the home activity, and resets the global animation scales to 1.0. You can also re-enable apps from the TV's own settings if the tools are unavailable. The restore script is not confirmed to restore Home on every device, and the repository does not document testing restoration after a firmware update.

The project's open issues report several device-specific caveats. A Xiaomi Mi Box lost USB speaker functionality while USB debugging was enabled, and switching debugging off brought it back. The repository advises inspecting debloat lists before applying them, disabling only a few packages at a time, and verifying Home, Wi‑Fi, HDMI-CEC, keyboard input, streaming apps, casting and firmware updates before proceeding further. The sources do not establish that the workflow succeeds on every Android TV or Google TV model and firmware, nor that it removes advertisements inside streaming apps or other services.

Frequently asked questions

Can I download a prebuilt launcher APK?

The repository does not publish prebuilt binaries. Build the launcher yourself with the one-line script above; it takes about a minute and you control what goes on your TV.

What happens if a firmware update lands after debloating?

Most lists disable the manufacturer's update service, so updates only arrive when you re-enable it on purpose.

How do I re-enable just one app without restoring everything?

Open the TV's Settings → Apps, find the disabled app, and select Enable. Or run tools/venv/bin/python -I tools/tv.py 'pm enable package.name' over ADB.

Verification status: Supported by official documentation only under the conditions below; not reproduced in a test environment by IGPROD. Checked 2026-10-18.

Conditions:

  • The assistant-led workflow requires a computer on the same Wi-Fi as the TV and a coding assistant with shell access.
  • Enable USB debugging on the TV, plus Network or ADB debugging if the TV offers it, and approve the computer's debugging prompt.
  • Building the launcher requires JDK 17 and Android SDK platform 34 with build-tools 34.0.0.
  • Use the same debloat list for restoration; the stock launcher package may need to be supplied explicitly.
  • The project excludes Samsung Tizen, LG webOS, and Amazon Fire TV.

Sources:

Fatima Ezzahra

Fatima Ezzahra

Fatima Ezzahra covers AI tools, open-source projects and technology news for IGPROD.

Your experience on this site will be improved by allowing cookies Cookie Policy