This forum uses cookies. Click X button to hide this message. What is stored? / Privacy
Total Commander Forum Index Total Commander
Forum - Public Discussion and Support
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Req: Add description support for Send shell command buttons

 
Post new topic   Reply to topic    Total Commander Forum Index -> Total Commander for Android Printable version
View previous topic :: View next topic  
Author Message
DrShark
Power Member
Power Member


Joined: 03 Nov 2006
Posts: 1111
Location: Kyiv, 68/262

PostPosted: Wed Feb 07, 2018 4:07 am    Post subject: Req: Add description support for Send shell command buttons Reply with quote

"Send shell command" button type supports 2 commands: sh and su.

Suggestion: if a word with a colon written besofore su or su, like here:
Code:
Description:sh
, show the "Description" word in a first line of modify button context menu instead (or before) the actual command.

Such way it's possible to add/change a description for some other types of the button, like "Launch app", but for "Send shell command" the description would be especially helpful because by default all such buttons have the same "command line" icon.
_________________
Android 4.3.1 no root, kernel 08.09.2016; Vista Home Premium SP2 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
Back to top
View user's profile Send private message
ghisler(Author)
Site Admin
Site Admin


Joined: 04 Feb 2003
Posts: 35767
Location: Switzerland

PostPosted: Thu Feb 08, 2018 4:19 am    Post subject: Reply with quote

Where would this description be shown? Currently when you long tap on such a button, TC shows both sh and the actual command.

Btw, you are free to choose any other icon for the button, e.g. from another app, or an image from your device.
_________________
Author of Total Commander
http://www.ghisler.com
Back to top
View user's profile Send private message Send e-mail Visit poster's website
DrShark
Power Member
Power Member


Joined: 03 Nov 2006
Posts: 1111
Location: Kyiv, 68/262

PostPosted: Thu Feb 08, 2018 6:02 am    Post subject: Re: Req: Add description support for Send shell command butt Reply with quote

ghisler(Author) wrote:
Where would this description be shown? Currently when you long tap on such a button, TC shows both sh and the actual command.
DrShark wrote:
... show the "Description" word in a first line of modify button context menu instead (or before) the actual command.
I had a hope I was clear... Real example:
Command:
Android commands::sh
Parameters:
*ls /system/bin

(there the colon before sh splits the description and the sh, all colons before are parts of description.)

So a long tap button context menu first line may be either:
Android commands:
(if we're replacing the sh *ls /system/bin with our description)
or
Android commands: sh *ls /system/bin
(if we're adding a description before sh+actual command)
_________________
Android 4.3.1 no root, kernel 08.09.2016; Vista Home Premium SP2 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
Back to top
View user's profile Send private message
DrShark
Power Member
Power Member


Joined: 03 Nov 2006
Posts: 1111
Location: Kyiv, 68/262

PostPosted: Wed Feb 14, 2018 12:56 pm    Post subject: Reply with quote

TC4A 2.81 beta 12 / history2.txt wrote:
2018-02-14 Added: Button bar: Support comment for shell commands to be shown on long tap: Comment:sh or Comment:su
Thanks, I tried it. With added comment, in long tap menu TC now shows it instead of sh/su+command.
However, for one of my buttons it adds ":sh" to the comment in long tap menu. The button:
Function type:
Send Shell command
Command:
md5:sh
Parameters:
*md5 "%N"
_________________
Android 4.3.1 no root, kernel 08.09.2016; Vista Home Premium SP2 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
Back to top
View user's profile Send private message
ghisler(Author)
Site Admin
Site Admin


Joined: 04 Feb 2003
Posts: 35767
Location: Switzerland

PostPosted: Thu Feb 15, 2018 4:21 am    Post subject: Reply with quote

It seems to happen when the comment is 5 or less characters. I will change it.
_________________
Author of Total Commander
http://www.ghisler.com
Back to top
View user's profile Send private message Send e-mail Visit poster's website
DrShark
Power Member
Power Member


Joined: 03 Nov 2006
Posts: 1111
Location: Kyiv, 68/262

PostPosted: Sun Mar 04, 2018 8:39 am    Post subject: Reply with quote

history2.txt wrote:
2018-02-16 Fixed: Button bar: When showing comment for shell commands, e.g. Comment:sh or Comment:su, the actual command was also shown if the comment was too short
I can confirm the fix in TC4A 2.90 beta 1.
_________________
Android 4.3.1 no root, kernel 08.09.2016; Vista Home Premium SP2 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Total Commander Forum Index -> Total Commander for Android All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Imprint/Impressum: This site is maintained by Ghisler Software GmbH
Privacy Policy | Datenschutzerklärung | Politique de Confidentialité

Using phpBB © phpBB Group