npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@mmmbuto/gemini-cli-termux

v0.28.2-termux

Published

Android/Termux optimized fork of **Google Gemini CLI** (`google-gemini/gemini-cli`).

Readme

🤖 Gemini CLI – Termux Edition

Android/Termux optimized fork of Google Gemini CLI (google-gemini/gemini-cli).

  • ✅ Tracks upstream regularly
  • ✅ Minimal, Termux-focused patches
  • ✅ Tested release: v0.28.0-termux (tag: v0.28.0-termux)

npm downloads license ko-fi


What is this?

This repository packages a Termux-first build of Gemini CLI:

  • Upstream project: https://github.com/google-gemini/gemini-cli
  • Upstream docs: https://geminicli.com/docs/
  • This fork: https://github.com/DioNanos/gemini-cli-termux

If you are on macOS / Linux / Windows, you should install the upstream package:

npm install -g @google/gemini-cli

Why a Termux fork?

Gemini CLI is designed for desktop platforms. On Termux/Android, a few dependencies and environment assumptions can break or degrade UX.

This fork keeps the upstream experience intact while adding the smallest possible patch-set to make it reliable on Android:

  • Native ARM64 PTY support (no node-gyp build on device)
  • Termux-friendly clipboard detection
  • Mobile filesystem + environment guardrails
  • Context Memory integration (persistent memory in ~/.gemini/context_memory/)
  • TTS (Text-to-Speech) support via termux-tts-speak

Installation (Termux)

Prerequisites

pkg update && pkg upgrade -y
pkg install -y nodejs-lts

Optional but recommended for a better mobile experience:

pkg install -y termux-api

Install

npm install -g @mmmbuto/gemini-cli-termux@latest

gemini --version

Update

npm install -g @mmmbuto/gemini-cli-termux@latest

Upstream release channels

Upstream publishes latest, preview, and nightly builds. This fork is meant to track upstream stable while keeping Termux fixes.


Quick start

Interactive mode:

cd /path/to/your/project

gemini

Useful slash commands inside the session:

/help
/auth

Headless / CI usage:

gemini -p "Explain the project structure" \
  -o json

Authentication

Gemini CLI supports multiple authentication methods (Google login, Gemini API key, Vertex AI). Termux users can use the same options as upstream.

Interactive (recommended)

Start gemini, then run:

/auth

Follow the on-screen flow.

Note (Android): Google login uses a browser flow that redirects to a localhost URL the CLI listens on during setup. Use the browser on the same device.

Environment variables (headless / CI)

Gemini API key (Google AI Studio):

export GEMINI_API_KEY="YOUR_GEMINI_API_KEY"

Vertex AI (examples):

export GOOGLE_GENAI_USE_VERTEXAI=true
export GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"
export GOOGLE_CLOUD_LOCATION="us-central1"

# Option A: API key
export GOOGLE_API_KEY="YOUR_GOOGLE_API_KEY"

# Option B: Service account
# export GOOGLE_APPLICATION_CREDENTIALS="/absolute/path/to/keyfile.json"

Persisting without leaking secrets: create a .gemini/.env file (project-level) or ~/.gemini/.env (user-level).

Full docs:

  • https://google-gemini.github.io/gemini-cli/docs/get-started/authentication.html

Termux optimizations

This fork applies a minimal set of Termux-specific fixes:

  • Clipboard detection fixes for Android/Termux environments.
  • ARM64 PTY prebuild for responsive interactive UI on Android.
  • Termux-API tool discovery (when termux-api is installed).
  • Mobile-safe guards (avoids desktop-only assumptions for paths, keychains, etc.).
  • googleSearch tool fix - works without requiring additional NPM installs.

See docs/TERMUX.md for Termux-specific documentation.


Known differences vs upstream (v0.28.0-termux)

From the latest test reports:

Linux x86_64 (VPS1):

  • gemini extensions settings works, may appear as config in some versions
  • auth / logout are functional but may not appear in the top-level help output
  • A standalone PTY require-test may fail in some environments even when PTY works in the app
  • Context Memory: ✅ Functional - reads from ~/.gemini/context_memory/
  • TTS (Text-to-Speech): ✅ Functional - reads from settings, termux-tts-speak enabled by default
  • googleSearch tool: ✅ Fixed - works without external dependencies

Termux ARM64 (Android):

  • Context Memory: ⚠️ init ENOENT on empty path; files exist
  • Agent TOML: ❌ loader file not found (source older than test suite)
  • PTY: ✅ loaded correctly
  • Termux-API: ✅ detection & discovery OK

Full reports:


Documentation


Build from source (Termux)

git clone https://github.com/DioNanos/gemini-cli-termux.git
cd gemini-cli-termux
npm install
npm run build && npm run bundle
node bundle/gemini.js --version

Disclaimer

This is an independent community fork created to improve the Termux experience.

Gemini CLI is an upstream project by Google, licensed under Apache-2.0.


Support

If this project saved you time (or helped you run real work from your phone), you can support it here:

  • ☕ Ko-fi: https://ko-fi.com/dionanos