Termux

Last updated
Termux
Original author(s) Fredrik Fornwall
Initial release30 May 2015;9 years ago (2015-05-30)
Stable release
0.118.1 [1]   OOjs UI icon edit-ltr-progressive.svg (16 June 2024;4 months ago (16 June 2024))
Repository https://github.com/termux/termux-app
Written in Java, C, C++
Operating system Android
Platform x86-64, ARM64, i686, ARMv7
Size 105 MB
Type Terminal Emulator, Command-line interface
License GPLv3 only
Website termux.dev   OOjs UI icon edit-ltr-progressive.svg

Termux is a free and open-source terminal emulator for Android which allows for running a Linux environment on an Android device. Termux installs a minimal base system automatically; additional packages are available using its package manager, based on Debian's. [2]

Contents

Most commands available in Linux are accessible in Termux, as well as built-in Bash commands. There are several other shells available, such as Zsh and tcsh. [3]

Overview

Packages are cross-compiled with Android NDK and have compatibility patches to get them working on Android. Since all files are installed in the application directory, rooting is not required. [4]

There are more than one thousand packages available, and users can submit requests for new ones. Alternatively, packages can be compiled from source, as Termux supports a variety of build tools including CMake, Meson, GNU Autotools, as well as compilers for C++, Rust, Go, Swift, and other programming languages. Termux can also install interpreters for languages like Ruby, Python, and JavaScript.

Terminal-based text editors such as Emacs and Vim can be installed. It is also possible to execute GUI applications in Termux by using a VNC server and installing a desktop environment (Xfce, LXQt, MATE) or window manager. [5]

Another popular use case for Termux is its ability to run containers of various Linux distributions which would normally use the chroot command without requiring root privileges by using PRoot. [6] This provides access to many more packages through the package manager of the distribution of choice than would directly be accessible in Termux, though popular application container formats such as Flatpak and Snap can't be used without root access as they require filesystem mounting permissions.

User interface

Termux's user interface is fairly simple, only displaying the extra keys row and the terminal output. Color scheme and font can be changed through Termux: Styling.

The extra-keys row can also be customized. Users can add more function keys and controls by editing ~/.termux/termux.properties.

Termux has mouse/touch support which can be used to interact with programs such as htop and other ncurses-based applications. Scrolling is done by swiping up or down in the terminal buffer.

Configuration

Users configure Termux by editing ~/.termux/termux.properties.

Add-ons

Termux also includes 7 add-ons:

Add-ons must be installed from the same source as the application so that the same User ID is used.

History

Termux was initially released in 2015. Support for requesting packages and features was added through GitHub issues in the app's repository. People can also contribute to the project by adding new features and packages.

In January 2020, the Termux development team ended support for devices running Android 5-6, making Android version 7 the minimum OS requirement.

Termux v0.101 was the last version to be updated in the Google Play Store. Since November 2020, Google Play has enforced apps targeting API level 29, which breaks the execution of binaries in private application directories. According to Google:

Untrusted apps that target Android 10 cannot invoke exec() on files within the app's home directory. This execution of files from the writable app home directory is a W^X violation. Apps should load only the binary code that's embedded within an app's APK file. [7]

The Termux development team suggests moving to F-Droid in order to continue getting updates, as F-Droid does not impose such restrictions. It is also possible to download APK files from the project's GitHub repository.

In May 2021, Bintray, which had been the primary host for the Termux packages, shut down its services. [8] Termux migrated to Hetzner, another hosting service. [9]

Installation

The installation process extracts the bootstrap archive from the APK file, sets correct permissions for the executable, and sets up directories like the home directory. The Play Store version of Termux isn't being updated anymore, users are encouraged to install Termux from F-Droid or GitHub in order to receive latest updates.

Package management and distribution

Packages in Termux are installed through the application's package manager (pkg) and use the .deb format. However, normal Debian packages cannot be installed as Termux is not FHS compliant. [10] Users can also build and submit packages.

Package availability

Termux has more than 1000 packages available as of 2021.

Package repositories

Termux has 3 repositories available. Repositories included in the default Termux bootstrap installation include:

Related Research Articles

<span class="mw-page-title-main">Wine (software)</span> Windows compatibility software

Wine is a free and open-source compatibility layer to allow application software and computer games developed for Microsoft Windows to run on Unix-like operating systems. Developers can compile Windows applications against WineLib to help port them to Unix-like systems. Wine is predominantly written using black-box testing reverse-engineering, to avoid copyright issues. No code emulation or virtualization occurs. Wine is primarily developed for Linux and macOS.

<span class="mw-page-title-main">Package manager</span> Software tools for handling software packages

A package manager or package-management system is a collection of software tools that automates the process of installing, upgrading, configuring, and removing computer programs for a computer in a consistent manner.

<span class="mw-page-title-main">Portage (software)</span> Gentoo package management system

Portage is a package management system originally created for and used by Gentoo Linux and also by ChromeOS, Calculate, Sabayon, and Funtoo Linux among others. Portage is based on the concept of ports collections. Gentoo is sometimes referred to as a meta-distribution due to the extreme flexibility of Portage, which makes it operating-system-independent. The Gentoo/Alt project was concerned with using Portage to manage other operating systems, such as BSDs, macOS and Solaris. The most notable of these implementations is the Gentoo/FreeBSD project.

freedesktop.org (fd.o), formerly X Desktop Group (XDG), is a project to work on interoperability and shared base technology for free-software desktop environments for the X Window System (X11) and Wayland on Linux and other Unix-like operating systems. Although freedesktop.org produces specifications for interoperability, it is not a formal standards body.

chroot Operation that changes the apparent root directory in Unix-like systems

chroot is an operation on Unix and Unix-like operating systems that changes the apparent root directory for the current running process and its children. A program that is run in such a modified environment cannot name files outside the designated directory tree. The term "chroot" may refer to the chroot(2) system call or the chroot(8) wrapper program. The modified environment is called a chroot jail.

The Android Package with the file extension apk is the file format used by the Android operating system, and a number of other Android-based operating systems for distribution and installation of mobile apps, mobile games and middleware. A file using this format can be built from source code written in either Java or Kotlin.

<span class="mw-page-title-main">PicoLisp</span> Programming language, a dialect of the language Lisp

PicoLisp is a programming language, a dialect of the language Lisp. It runs on operating systems including Linux and others that are Portable Operating System Interface (POSIX) compliant. Its most prominent features are simplicity and minimalism. It is built on one internal data type: a cell. On the language level, a programmer can use three different data types being represented by cells and differentiated by bits at the end of the cell. It is free and open-source software released under an MIT License (X11).

<span class="mw-page-title-main">Homebrew (package manager)</span> macOS CLI package manager in Ruby

Homebrew is a free and open-source software package management system that simplifies the installation of software on Apple's operating system, macOS, as well as Linux. The name is intended to suggest the idea of building software on the Mac depending on the user's taste. Originally written by Max Howell, the package manager has gained popularity in the Ruby on Rails community and earned praise for its extensibility. Homebrew has been recommended for its ease of use as well as its integration into the command-line interface. Homebrew is a member of the Open Source Collective, and is run entirely by unpaid volunteers.

<span class="mw-page-title-main">Aptoide</span> Online marketplace for Android and iOS apps

Aptoide is an online marketplace for mobile applications which runs on the Android and iOS operating systems. In Aptoide, unlike the Android-default Play Store and iOS-default App Store, there is not a unique and centralized store; instead, each user manages their own store. The software package is published by Aptoide S.A., a for-profit company incorporated in 2011, and headquartered in Lisbon, Portugal.

mpv (media player) Free and open-source media player software

mpv is free and open-source media player software based on MPlayer, mplayer2 and FFmpeg. It runs on several operating systems, including Unix-like operating systems and Microsoft Windows, along with having an Android port called mpv-android. It is cross-platform, running on ARM, MIPS, PowerPC, RISC-V, s390x, x86/IA-32, x86-64, and some other by 3rd party.

<span class="mw-page-title-main">F-Droid</span> Repository for free and open source Android apps

F-Droid is a free and open source app store and software repository for Android, serving a similar function to the Google Play store. The main repository, hosted by the project, contains only free and open source apps. Applications can be browsed, downloaded and installed from the F-Droid website or client app without the need to register an account. "Anti-features" such as advertising, user tracking, or dependence on non-free software are flagged in app descriptions.

<span class="mw-page-title-main">Google App Runtime for Chrome</span> Compatibility layer and sandboxing technology

Android Runtime for Chrome (ARC) is a compatibility layer and sandboxing technology for running Android applications on desktop and laptop computers in an isolated environment. It allows applications to be safely run from a web browser, independent of user operating system, at near-native speeds.

<span class="mw-page-title-main">Windows Subsystem for Linux</span> Feature that provides for a Linux operating system within Windows

Windows Subsystem for Linux (WSL) is a feature of Microsoft Windows that allows for using a Linux environment without the need for a separate virtual machine or dual booting. WSL is installed by default in Windows 11. In Windows 10, it can be installed either by joining the Windows Insider program or manually via Microsoft Store or Winget.

<span class="mw-page-title-main">UserLAnd Technologies</span> Compatibility layer mobile app

UserLAnd Technologies is a free and open-source compatibility layer mobile app that allows Linux distributions, computer programs, computer games and numerical computing programs to run on mobile devices without requiring a root account. UserLAnd also provides a program library of popular free and open-source Linux-based programs to which additional programs and different versions of programs can be added.

There are many apps in Android that can run or emulate other operating systems, via utilizing hardware support for platform virtualization technologies, or via terminal emulation. Some of these apps support having more than one emulation/virtual file system for different OS profiles, thus the ability to have or run multiple OS's. Some even have support to run the emulation via a localhost SSH connection (letting remote ssh terminal apps on device access the OS emulation/VM, VNC, and XSDL. If more than one of these apps that support these protocols or technologies are available on the android device, via androids ability to do background tasking the main emulator/VM app on android can be used to launch multiple emulation/vm OS, which the other apps can connect to, thus multiple emulated/VM OS's can run at the same time. However, there are a few emulator or VM apps that require that the android device to be rooted for the app to work, and there are others that do not require such. Some remote terminal access apps also have the ability to access Android's internally implemented Toybox, via device loopback support. Some VM/emulator apps have a fixed set of OS's or applications that can be supported.

Android devices have the ability to run virtual machines or emulate other operating systems. It does this either via desktop virtualization, platform virtualization, or emulation via compatibility layer.

<span class="mw-page-title-main">Foliate (software)</span> E-book reading application for Linux

Foliate is a free and open-source program for reading e-books in Linux. In English, foliate is an adjective meaning to be shaped like a leaf, from the Latin foliatus, meaning leafy.

<span class="mw-page-title-main">Conversations (software)</span> Free software instant messaging client for the XMPP protocol

Conversations is a free software, instant messaging client application software for Android. It is largely based on recognized open standards such as the Extensible Messaging and Presence Protocol (XMPP) and Transport Layer Security (TLS).

References

  1. "Release 0.118.1". 16 June 2024. Retrieved 19 June 2024.
  2. Seth Kenlon (August 11, 2020). "Use a Linux terminal on your Android phone". opensource.com. Retrieved August 17, 2021.
  3. "ZSH - Termux Wiki". Termux. July 30, 2020. Retrieved August 17, 2021.
  4. "The Termux Wiki". Termux. July 30, 2021. Retrieved August 17, 2021.
  5. "Graphical Environment - Termux Wiki". Termux. July 30, 2021. Retrieved August 17, 2021.
  6. termux/proot-distro, Termux, 2024-11-03, retrieved 2024-11-03
  7. "Behavior changes: apps targeting API 29+". Android Developers. Retrieved 2021-12-01.
  8. "Into the Sunset: Bintray, JCenter, GoCenter, and ChartCenter". JFrog. 2021-02-03. Retrieved 2021-12-01.
  9. "Termux". Termux. Retrieved 1 June 2023.
  10. "Differences from Linux - Termux Wiki". termux.com. 30 July 2021. Retrieved 18 August 2021.