termux-tools
Turn your phone into a persistent dev server
Shell / JS / TS / Python · MIT Licensed · ARM64
# Core Features
Tmux Multi-Instance Manager
Separate tmux instances per project on boot. Fuzzy-search switching, auto-go flags, Claude Code-compatible workflow.
tm clev — fuzzy-switch to cleverkeys tmgo un — send 'go' without switching tmbs — list all sessions tmbr — restart all instances ADB Wireless Automation
Auto-detect and connect ADB over WiFi. Reverse port scanning, cron-based monitoring every 5 min, instant reconnect from cache.
adb-wireless-connect.sh — auto-connect crontab -e — schedule reconnect adb devices — verify connection Tasker Crash Recovery
Auto-restarts Termux on crash or OOM. Restores all tmux sessions, health check every 10 min, zero manual intervention.
auto-setup-tasker.sh — one-command setup check-termux-health.sh — manual health check restore-tabs.sh — restore UI tabs # Quick Start
Up and running in under 5 minutes. Requires Termux:Boot and Termux:API from F-Droid.
1. Install & Configure
# Install required packages
pkg install tmux termux-api
# Install Termux:Boot and Termux:API from F-Droid
# (required for boot persistence and notifications)
# Clone the repo
git clone https://github.com/tribixbite/termux-tools ~/git/termux-tools
cd ~/git/termux-tools
# Copy configuration templates
cp examples/startup.sh.example ~/.termux/boot/startup.sh
mkdir -p ~/.config/termux-boot
cp examples/repos.conf.example ~/.config/termux-boot/repos.conf
cp examples/bash_aliases.example ~/.bash_aliases
chmod +x ~/.termux/boot/startup.sh
# Reload shell to get aliases
source ~/.bashrc2. Configure Your Projects
# ~/.config/termux-boot/repos.conf
# Format: REPOS["path"]="auto_go:enabled"
declare -A REPOS
REPOS["$HOME/git/swype/cleverkeys"]="1:1" # auto-go + enabled
REPOS["$HOME/git/termux-tools"]="0:1" # enabled, no auto-go
REPOS["$HOME/git/my-project"]="0:1" # add your projects3. Reboot
Reboot your device. Termux:Boot will run startup.sh,
creating a tmux session for each enabled repo. Use tm <search> to switch between them.
# Command Reference
| tm <search> | Fuzzy-search switch to session/window |
| tmgo <search> | Send 'go' to session without switching |
| tmb0-5 | Jump to window 0–5 |
| tn / tp | Next / previous window |
| tl | Last (most recent) window |
| tw | Interactive window picker |
No more Ctrl+b — all commands are direct shell aliases
# How It Works
┌──────────────────────────────────────────────────────┐
│ Device Boot │
│ │ │
│ ▼ │
│ Termux:Boot ──▶ startup.sh │
│ │ │
│ ├── termux-wake-lock │
│ ├── ADB wireless connect + phantom fix │
│ ├── Read repos.conf │
│ │ │
│ ▼ │
│ For each repo: │
│ ├── tmux new-session -s name │
│ ├── start claude code │
│ └── auto_go=1 ? send 'go' │
│ │
│ Tasker monitors health every 10 min: │
│ └── unhealthy? ──▶ relaunch + restore │
└──────────────────────────────────────────────────────┘ XDG-Compliant Paths
Config in ~/.config/termux-boot/
Logs in ~/.local/share/termux-boot/logs/
Separate Instances
Each project gets its own tmux session.
No shared state, no crosstalk.
# Repo Structure
# Requirements
● required ○ optional (for bridge/extension features)