pms icon indicating copy to clipboard operation
pms copied to clipboard

Add command to run a console command

Open tremby opened this issue 6 years ago • 2 comments

I liked this feature in the C++ version. Any interest in having it in the new version, or not?

For example, I had ^W run a python script which grabbed and displayed the lyrics for the currently-playing song. I had ^T run Transcribe with the song under the cursor's path/filename as an argument.

It might be nice to allow placeholders for tags of the current or highlighted song.

tremby avatar Aug 07 '17 07:08 tremby

Yes, this would be a welcome feature. The exclamation mark ! would need to be added as an input token, and a corner case is needed in the command parser. Unsure about the implementation itself, but it should probably be added as a regular command?

Also, how do we handle the output showing on screen? For this, and other purposes such as debugging or status monitoring, maybe a drop-down (or pull-up) console window could be useful?

kimtore avatar Aug 08 '17 08:08 kimtore

I'd be for keeping it simple, rather than trying to display any output within the app.

Vim has :!{command} which runs the command and then shows a "press a key" prompt, or :silent !{cmd} which doesn't redraw the screen or prompt you. Both are useful in different situations.

tremby avatar Aug 08 '17 08:08 tremby