Quantcast
Channel: Total Commander
Viewing all articles
Browse latest Browse all 3935

Total Commander for Android • Re: Termux integration with custom button feature

$
0
0
Sorry, I'm not familiar with Termux. What are you trying to achieve?
Termux is a linux-like debian-based terminal emulator (sort of) environment that is built on top of android, as an apk with ported packages to work with the Android architecture. It is very well supported and I and many others actively develop on it. It has access to common shared storage areas as well its own separate storage partition and even other app caches if the device is rooted.

With termux, the custom button features in Total Commander could call a script to run within termux (python Ruby shell etc) and all of the logic could be handled within termux and update the shared storage space. This is not limited to file and folder operations, as network tasks can be completed as well. The added functionality would be almost limitless.

If you want to provide streamlined integration you could import these libraries and constants. However, I believe it's only the com.termux.permissions.RUN_COMMAND that is really blocking execution.

Shared libraries:
https://github.com/termux/termux-app/tree/master/termux-shared

Constants for shared library
https://github.com/termux/termux-app/blob/master/termux-shared/src/main/java/com/termux/shared/termux/TermuxConstants.java

You could aslo hand over control to menu-based Termux shell scripts for more fine tuned pre-determined operations or even gui menus in pretty much any language that there is a stable termux package for. The focus could be based on the currently navigated folder or really anything that you pass as a parameter. You wouldn't need to develop plugins to perform network tasks (like upload to a network storage space of your choice); you could handle all of that in Termux and just add a button to manage running your routines.

By integrating with Termux, Total Commander could provide a seamless way for users to perform complex tasks with just a few clicks.

To further illustrate, imagine a user who wants to upload a file to a network storage space. They could click a custom button in Total Commander, which would then trigger a script to run in Termux. The script could use the Termux API to upload the file, and then return control to Total Commander.

The beauty of this approach is that it's highly customizable. Users could write their own scripts in a variety of languages, and tailor the integration to meet their specific needs. They could also use the Termux API to perform a wide range of tasks, from simple file operations to complex network tasks.

To make this integration possible, you could import the Termux shared libraries and constants, which are available on GitHub. This would provide a streamlined way for Total Commander to communicate with Termux and trigger scripts.

I believe that this integration could be a game-changer for Total Commander, and I'd be happy to help make it happen. Let me know if you're interested in discussing this further!

Statistics: Posted by Tcrocks — 2024-11-22, 16:35 UTC



Viewing all articles
Browse latest Browse all 3935