1
0
mirror of https://github.com/danog/termux-api.git synced 2024-11-30 04:19:20 +01:00
Go to file
2020-02-07 14:19:10 +02:00
.github CI: switch to Github Actions 2020-02-07 14:19:10 +02:00
app Add ability to have commas as characters within items 2020-01-26 16:57:44 +01:00
gradle/wrapper Update gradle version 2019-08-13 22:18:21 +02:00
.gitignore Remove .idea from version control 2019-01-25 02:45:26 +01:00
build.gradle Update gradle version 2019-08-13 22:18:21 +02:00
gradle.properties Fix fingerprint APIs on android 9 and switch to android X (#283) 2019-09-24 18:45:28 +03:00
gradlew Update gradle version 2019-08-13 22:18:21 +02:00
gradlew.bat Update gradle version 2019-08-13 22:18:21 +02:00
README.md CI: switch to Github Actions 2020-02-07 14:19:10 +02:00
settings.gradle Initial push 2015-07-26 02:23:21 +02:00

Termux API

Build status Join the chat at https://gitter.im/termux/termux

This is an app exposing Android API to command line usage and scripts or programs.

When developing or packaging, note that this app needs to be signed with the same key as the main Termux app for permissions to work (only the main Termux app are allowed to call the API methods in this app).

Installation

Termux:API application can be obtained from:

Additionally we offer development builds for those who want to try out latest features ready to be included in future versions. Such build can be obtained directly from Cirrus CI artifacts.

Signature keys of all offered builds are different. Before you switch the installation source, you will have to uninstall the Termux application and all currently installed plugins.

License

Released under the GPLv3 license.

How API calls are made through the termux-api helper binary

The termux-api client binary in the termux-api package generates two linux anonymous namespace sockets, and passes their address to the TermuxApiReceiver broadcast receiver as in:

/system/bin/am broadcast ${BROADCAST_RECEIVER} --es socket_input ${INPUT_SOCKET} --es socket_output ${OUTPUT_SOCKET}

The two sockets are used to forward stdin from termux-api to the relevant API class and output from the API class to the stdout of termux-api.

Client scripts

Client scripts which processes command line arguments before calling the termux-api helper binary are available in the termux-api package.

Ideas

  • Wifi network search and connect.
  • Add extra permissions to the app to (un)install apps, stop processes etc.