AI coding & building lab for unrooted Android (Termux + proot + Grok Build).
- Termux from F-Droid or GitHub (not Play Store)
- Android 8+ (aarch64 recommended)
- No root required
- Stable internet
- SuperGrok / X Premium+ or
XAI_API_KEYfor Grok Build
- Linux, macOS, or WSL with
bash,curl, andtar - Same Grok auth as above for
--with-grok - No NetHunter rootfs / Magisk / Termux:X11 on desktop — coding tools only
# Termux — full lab
bash <(curl -fsSL https://raw.githubusercontent.com/FineComputer14451/GrokHunter/main/install.sh)
# Desktop (Linux/macOS/WSL) — overlay-only coding tools
bash <(curl -fsSL https://raw.githubusercontent.com/FineComputer14451/GrokHunter/main/install.sh) \
--overlay-only --with-grok --with-completionsOn a Termux TTY with no flags, that opens a numbered installer wizard. Default recipe is coding-only:
--nano --no-de --with-grok --with-completions
Toggle “desktop lab” in the wizard for --full --de xfce --browser chromium --with-x11. Confirm prints the exact argv, then runs the existing engine. Never prompts for an API key.
Skip the wizard:
bash install.sh --yes # coding-only default, no prompts
bash install.sh --full --de xfce --with-grok --with-x11 # flags = non-interactive
GROKHUNTER_INSTALL_TUI=0 bash install.sh # old termux-distro choose/askNon-TTY with no flags exits: pass --yes or explicit flags. Overlay-only is unchanged (still needs --with-*; no wizard).
bash <(curl -fsSL https://raw.githubusercontent.com/FineComputer14451/GrokHunter/main/install.sh) \
--full --de xfce --browser chromium --with-grok --with-x11Installs:
- Latest Kali NetHunter rootfs (rootless)
- XFCE desktop
- Chromium
- Grok Build CLI
- Termux:X11 helper (
nh-x11)
git clone https://github.com/FineComputer14451/GrokHunter.git
cd GrokHunter
bash install.sh --full --de xfce --with-grok --with-x11-f, --full Full installation (desktop-capable rootfs; pass --de/--browser to configure)
-m, --mini Mini (essential packages)
-n, --nano Nano (minimal)
--de <desktop> e17 | gnome | i3 | kde | lxde | mate | xfce
--browser <browser> chromium | firefox | both
--no-de Skip desktop environment
--with-grok Install Grok Build CLI (shared ensure script)
--no-grok Skip Grok Build
--with-x11 Install Termux:X11 + nh-x11
--no-x11 Skip Termux:X11
--with-aider Install Aider (venv + xAI helper)
--no-aider Skip Aider
--with-v9-models Deprecated no-op (V9 pickers removed; accepted for old scripts)
--no-v9-models Deprecated no-op (V9 pickers removed; accepted for old scripts)
--with-completions Copy completions + ~/.grok/profile.sh (does not edit .zshrc/.bashrc)
--no-completions Skip shell completions
--overlay-only Skip rootfs / termux-distro; only run optional overlays
--yes Coding-only default (nano, no DE, Grok + completions); no wizard
-h, --help Show help
When Kali is already installed, add optional pieces without running termux-distro:
bash install.sh --overlay-only --with-x11 --with-aider
bash install.sh --overlay-only --with-grok --with-completions
# or:
grokhunter install --overlay-only --with-grok --with-completionsRequires at least one --with-* flag. Does not install DE/browser or pull a new rootfs.
This is also the update path for an existing lab (avoids re-downloading Kali).
Helpers (nh-x11, aider-grok, grokhunter, …) are installed from repo bin/ into ~/.local/bin (and Termux PREFIX/bin when available). Ensure PATH includes ~/.local/bin (see ~/.grok/profile.sh). The one-liner extracts the full overlay to ~/GrokHunter (or ~/.cache/grokhunter/src if that directory is already occupied).
| Variable | Purpose |
|---|---|
GROKHUNTER_REFRESH=1 |
Bypass module + engine cache |
GROKHUNTER_INSTALL_TUI=0 |
Skip first-run wizard; use termux-distro choose/ask |
GROKHUNTER_DISTRO_ENGINE_URL |
Pin/fork of termux-distro.sh (default: jorexdeveloper/termux-distro main) |
GROKHUNTER_GROK_INSTALLER |
auto | official | termux-native |
GROKHUNTER_GROK_TERMUX_URL |
Override Termux-native installer URL (default: pinned commit, not main) |
GROKHUNTER_FORCE_GROK=1 |
Reinstall Grok even if present |
GROKHUNTER_MIN_GROK |
Min Grok Build version (default 1.0.5) |
GROKHUNTER_SKIP_PROFILE=1 |
Skip NetHunter config.toml profile merge |
NH_X11_SESSION |
Desktop start command for nh-x11 (e.g. startlxde) |
Engine resolution order: vendored ./termux-distro.sh next to install.sh → cached engine if its URL stamp matches the resolved URL (GROKHUNTER_DISTRO_ENGINE_URL or the jorexdeveloper default; a missing stamp is treated as default) → download into that cache (never CWD). Pinning a fork no longer requires GROKHUNTER_REFRESH=1. Unsetting a pin refetches the default instead of keeping a foreign cache.
Upstream credit: the install engine is jorexdeveloper/termux-distro (GPL-3.0), used for the termux-nethunter rootless model. Full attribution: CREDITS.md.
If you install Chromium, the desktop entry is patched with --no-sandbox. User namespaces are unavailable in proot, so Chromium will not start without it. Treat this as a security tradeoff: fine for casual browsing in a lab; do not use for banking or high-sensitivity sessions. Prefer Firefox ESR when possible.
# Enter Kali (rootless)
nethunter
# Pair programming
grok
# or headless
grokhunter -p "your task"
# Desktop (install Termux:X11 APK first)
nh-x11
# Health check
grokhunter doctorDownload from: https://github.com/termux/termux-x11/releases
# API key (recommended on mobile)
printf 'export XAI_API_KEY=%q\n' "xai-..." > ~/.grok/secrets.env
chmod 600 ~/.grok/secrets.envOr run grok once and complete browser login if available.
See EDITORS.md for Aider + Grok setup.
bash uninstall.sh
# or destructive Grok purge:
bash uninstall.sh --purge-grok