editable menus

Bug #213317 reported by Martin Bruns
4
Affects Status Importance Assigned to Milestone
Terminator
Fix Released
Wishlist
Chris Jones

Bug Description

Hi,

it would be very nice to have to possibility to extend the menu in terminator (or the dnd-tab branch) to have menus like ssh to that host1 or ssh host2 or any other configurable command.

This was possible in multi-gnome-terminal but multi-gnome-terminal is nolonger maintained.

Kind Regads
Martin

Tags: withlist
Revision history for this message
Chris Jones (cmsj) wrote :

I like the idea. A GUI for configuring it might be hard, but it would be better to at least be able to edit a config file.

Changed in terminator:
importance: Undecided → Wishlist
status: New → Confirmed
Revision history for this message
Jordan Callicoat (monkeesage) wrote :

This should be relatively easy to implement. Just add a new section (e.g., "[actions]") to the config file. If that section exists, create a submenu in the right-click menu, and populate it with the values from that section (e.g., "SSH1 = ssh host1.org"). When an action is activated, feed the active term the command associated with the action. The only drawback would be that action names must be valid config item names (e.g., no spaces). It would also be relatively easy to add UI for this in the profile editor.

An alternate approach would be to use a separate config file (e.g., ~/.config/terminator/actions), that allows for arbitrary action names (simply split lines on "="?), without all the bells and whistles of the config class.

I'll try to play with this in the next few days.

Revision history for this message
Martin Bruns (martin-konahina) wrote : Re: [Bug 213317] Re: editable menus

Hi Jordan,

thanks for the reply.

I'm not sure whether you mean that I should just add the actions
sections empty or with ssh1=ssh host1.org. I'm not sure where you want
me to create the submenu.

I tried with version 0.12.

Also when ever I start terminator I miss the title bars on the terms. Is
that a known bug?

Kind Regards
Martin

Jordan Callicoat schrieb:
> This should be relatively easy to implement. Just add a new section
> (e.g., "[actions]") to the config file. If that section exists, create a
> submenu in the right-click menu, and populate it with the values from
> that section (e.g., "SSH1 = ssh host1.org"). When an action is
> activated, feed the active term the command associated with the action.
> The only drawback would be that action names must be valid config item
> names (e.g., no spaces). It would also be relatively easy to add UI for
> this in the profile editor.
>
> An alternate approach would be to use a separate config file (e.g.,
> ~/.config/terminator/actions), that allows for arbitrary action names
> (simply split lines on "="?), without all the bells and whistles of the
> config class.
>
> I'll try to play with this in the next few days.
>
>

Revision history for this message
Jordan Callicoat (monkeesage) wrote :

Martin,

I was only thinking of how this could be implemented. I didn't mean for you to do anything. I was just thinking that a good place for external tools like this would be in a submenu (right-click menu is already huge), and thinking about how to keep track of them. I'll attach a patch to the bug report if I get some time to play with this.

Regards,
Jordan

Revision history for this message
Chris Jones (cmsj) wrote :

If we do add this kind of thing, it should *definitely* go in a sub-menu!

Revision history for this message
Jordan Callicoat (monkeesage) wrote :

After thinking about the problem, it seems to me it is best handled by shell aliases. They have the advantage of working in every terminal emulator, and most of us already have quite a collection (I currently have 24 aliases in ~/.alias). I can't see how it would be much of a time or effort saver to right-click, select sub-menu, click "SSH1", compared to just typing "ssh1". Maybe some shell that doesn't support aliases is a corner-case, but I think the vast majority of users are using a sh-compatible shell that supports aliases.

Revision history for this message
Chris Jones (cmsj) wrote :

trunk now supports plugins and one of the things it allows plugins to hook into is the context menu. There is already a plugin written by chantra which allows the creation of custom commands, and although this plugin will be disabled by default, it will ship in the next release of Terminator (0.90).

Changed in terminator:
assignee: nobody → Chris Jones (cmsj)
status: Confirmed → Fix Committed
Chris Jones (cmsj)
Changed in terminator:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.