Ticket #2007 (new enhancement)

Opened 14 years ago

Last modified 12 years ago

key binding to insert the name of the current file prefixed by ./ if it's executable

Reported by: csaba.juhos Owned by:
Priority: trivial Milestone: Future Releases
Component: mc-core Version: master
Keywords: key binding control ctrl alt enter executable Cc:
Blocked By: Blocking:
Branch state: no branch Votes for changeset:

Description

Running an executable in the current directory without parameters is easy. You just select it in one of the panels, then you hit enter.
Running it with parameters is more cumbersome. At best you can:

  1. type ./
  2. select the executable in one of the panels
  3. insert its name by hitting alt-enter or control-enter
  4. complete the command line with the parameters
  5. and execute it by hitting enter

It would be nice to have a key binding which inserts ./%f for executables.
You could bind it to either alt-enter or control-enter, they both insert a plain %f. I would go with control-enter, as it's a bit harder to type.

A common use case of this enhancement would be running a script with file arguments, when the script and the files are all in the same directory. For example:

$ ./apply-style.sh extract.xsl db.xml

The entire command line can be constructed from three simple insertions. No "manual" typing.

Csabi

Change History

comment:1 Changed 12 years ago by andrew_b

  • Version set to master
  • Branch state set to no branch
  • Milestone set to Future Releases
Note: See TracTickets for help on using tickets.