New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom tools support #165

Closed
warpkanal opened this Issue Oct 17, 2017 · 8 comments

Comments

Projects
None yet
2 participants
@warpkanal

warpkanal commented Oct 17, 2017

Currently using iTerm but with a different shell, so I would need to execute some other command when e.g. pressing F11.
But guess that's anyway on the roadmap :)

@yanex

This comment has been minimized.

Contributor

yanex commented Oct 17, 2017

What kind of tool support do you need?

@yanex yanex added the feature label Oct 17, 2017

@warpkanal

This comment has been minimized.

warpkanal commented Oct 17, 2017

The ability to execute an arbitrary command with some predefined "parameters" I get from marta, e.g. to launch "/myscripts/convert.sh %f" assuming that %f would fill in the currently selected file's absolute path. A predefined variable would include the select file(s), another one the current path (and other people would probably like the file's name without or with extension...). Finally I'd like to be able to map this to a keyboard shortcut :)

@yanex

This comment has been minimized.

Contributor

yanex commented Oct 17, 2017

Well, some other commands may want the current directory path instead of the file path, or even both pane directories, or whatever else.
So instead of hard-coding different substitution rules (like %f for the current file, %d for directory etc.), looks like a lightweight (non-Swift/Objc) plugin API will be a more general solution.

@warpkanal

This comment has been minimized.

warpkanal commented Oct 17, 2017

Guess a lightweight plugin API would be even something more generic.
I know from many other filemanagers the ability to simply execute arbitrary apps/scripts with these predefined parameters, but sure if a lightwheight API can achieve the same (without too much need of understanding marta internals) it'll be fine as well :)
On a side note: how do you invoke iTerm? (i'm using iTerm with fish shell and for some reason marta is able to invoke/bring iTerm to front, but the current directly does not change to the one currently open in marta when F11 was invoked.

@warpkanal

This comment has been minimized.

warpkanal commented Oct 17, 2017

And on another side note: I just realized that this has nothing to do with my shell but simply works on my mac but not on my macbook...

@warpkanal

This comment has been minimized.

warpkanal commented Oct 17, 2017

Just a short example of what I thought with tools support (as I'm not sure how a lightweight plugin API would look), so tools support would just be some section in the config.json like this:

"tools": [
  {"mytool1":"/myscripts/convert.sh %f"}
],
"keyBindings": {
  "mytool1": ["Cmd+m"]
}
@yanex

This comment has been minimized.

Contributor

yanex commented Dec 3, 2017

Looks like this should also fix this issue.

@warpkanal

This comment has been minimized.

warpkanal commented Dec 3, 2017

Yes

@yanex yanex added this to the 0.4.7 milestone Dec 17, 2017

@yanex yanex modified the milestones: 0.4.7, 0.5 Jan 1, 2018

@yanex yanex added the fixed label Jan 5, 2018

@yanex yanex closed this Jan 5, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment