I’m pretty happy to announce the first release of our terminal plug-in for Eclipse!
This plug-in provides a fully-working, command-line terminal to Eclipse 3.7 or later (yes, even 4.2!) It works on Linux and MacOS only.
Why a terminal?
At Google we have several interactive command-line tools that we need to invoke from Eclipse. It resulted in poor user experience. The terminal opened in its own window. After issuing several commands, managing all those windows was messy. This terminal also does not allow us to copy/paste URLs.
This first release is mostly for users to give the terminal a try. For our next release, we expect to fix all major bugs and have the ability to issue commands from Eclipse.
Standing on the shoulder of giants
The terminal plug-in is based on two great Eclipse projects: Eclipse CDT and Eclipse Target Management. We forked the minimum necessary pieces to make the plug-in work. From Target Management we got the terminal emulator, and from CDT we got the pseudo-terminal (PTY) support.
Improvements
Once we had a minimal terminal working, we added some features to improve the user experience.
1. Quickly open a terminal from almost anywhere in Eclipse

A new terminal view can be opened in three different ways:
- Right-click any file or folder, and select the “Open Terminal Here” context menu (idea borrowed from the Windows XP Power Toy “Command Prompt Here”)
- On a terminal view, click the “New Terminal” button in the toolbar
- If there are no terminal views open, go to the menu “Window” > “Show View” > “Other” and find “Terminal” under the “General” category
2. Colors and font configuration

You can change the terminal’s background and foreground colors as well as the font. Go to the menu “Window” menu (or “Eclipse” menu in Mac OS) and navigate to the “Terminal” > “Colors and Font” preference page.
3. Hyperlinking

The terminal plug-in recognizes and provides hyperlinks for URLs using the HTTP(S) protocol. We’ll provide an extension point for custom hyperlink detectors.
4. Keyboard shortcuts
Shortcuts for copy/pasting text was one of the most requested features. On Linux you can use Ctrl+Shift+C and Ctrl+Shift+V while on MacOS you can use Command+C and Command+V, respectively.
5. Change terminal’s title
By default, the title of a terminal view is the last segment of the path of its working directory. You can change the title by pressing a button in the toolbar.
Project location
The terminal plug-in is hosted at Google Code, under the name ELT (Eclipse Local Terminal.)
Feedback is always welcome :)

My name is Alex Ruiz.



{ 49 comments… read them below or add one }
Looks like great, good job !
I used to use Path Tools plugin to link my eclipse to my terminal, so I installed this plugin :)
There is a way to set encoding ? I got some bad char with char like “é” but not in my terminal.
Thanks Nicolas! Encoding is hard-coded, unfortunately. We already have a bug report to have this configurable. Next release, I promise!
Looks interesting. I currently use the Target Management Terminal. It is not clear from this post why you chose to fork that project as opposed to contribute the features you wanted to that project.
Do we need more than one Terminal for Eclipse? Do you have any long term plans to try to get your code into that project?
Hi Mark,
For the record, the Target Management Terminal is great. It is a great piece of technology. The problem is that it provides more functionality than we needed, and it is missing some features.
The main reason for the fork is that we need to issue command-line commands in a way that doesn’t suck for the user. We need a quick way to say “hey terminal, execute this command, pronto”. TM’s terminal is very generic. It has this notion of connectors, which is a good idea but not useful to us. Setting it up to do what we need to do would require, to my understanding, some user interaction. We wanted to avoid this.
The things that TM’s terminal is missing are the user-friendly features, the ones I blogged about. I’d love to contribute them back to the project.
Another issue was connecting TM’s terminal with local bash. TM has a “Local Terminal” connector in incubation, but it has a dependency on CDT. Depending on CDT just for its PTY support is not my favorite idea. There we go, we forked CDT too.
Cheers!
Thanks for the info. Just to be clear, I think what you did looks cool. I just thought this blog post or the project website ought to include some information about why a fork was chosen as opposed to enhancing the projects that exist. I did not doubt you had reasons.
Mark
Thanks Mark. I’ll follow your suggestion. I’ll be adding an entry in the FAQ covering why we forked TM and CDT :)
Done! http://code.google.com/p/elt/wiki/FAQ
Thanks Mark for the idea :)
Looks like awesome work! It would be great to see this work end up at Linux Tools. You should ping their mailing list :)
Thanks Chris! I truly appreciate your kind comments :)
Good idea! I will ping the Linux Tools folks.
Cheers!
What about us enterprise developers stuck in Microsoft world at work. :(
The reason we don’t support Windows is that CDT’s PTY support doesn’t. I’m not a Windows developer (and I don’t want to be one.) Hopefully somebody will contribute Windows support in the future.
Cheers!
hi alex,
cool. I tried it on indigo just now — looks cool. I could even run vim from within it. I should next try emacs!
Great work.
any plans of windows support ?
BR,
~A
Thanks Anjan. I personally won’t be spending time working on Windows support. I don’t have enough Windows knowledge to get anything done. Patches welcome! :)
Super cool! Thanks Alex for this, makes my life easier.
Great! Thanks Lars! I’m glad to hear that!
Looking forward to trying this on Mac OSX! For those forced to use Windows, there is a plugin called Wicked Shell. Not perfect, takes a little setup, but seems to be the best option.
Great! let me know if you find any issues or bugs!
I wonder how many people care about Windows. I just file http://code.google.com/p/elt/issues/detail?id=18 …let’s see how many people star it.
You should list this on the Eclipse Marketplace (http://marketplace.eclipse.org/) to make it easier to discover and install.
Thanks Eric for the suggestion! I just did it. The post is under moderation.
Cheers!
Great!
Highlighting rules would be useful (for example for errors and warnings highlighting). Line numbers links would be great.
Well, a terminal is not really an editor. I don’t know how useful it would be to have line numbers though. But I’m open to suggestions :)
For highlighting, I think the output must have the appropriate ANSI code for colors.
Cheers!
Nice work. I noticed that the text output was somehow more fluid than the terminal from TM. Did you make improvements on that front too?
Thanks Marc!
I didn’t do anything particular to improve the output though. If it is better, it was not intentional :)
Very cool! Thanks, it makes my life easier, I’m always switching between terminal windows and Eclipse.
Thanks Kim! I’m glad to hear you found it useful!
This is great! I’m sure the Scala-IDE guys would love this kind of deep integration for the scala interpreter.
Thanks! I hope so too :)
Great job! very useful plugin.
Gracias Juan!
This is a great plugin. The only minor issue that I’ve found is that sometimes there is a small but noticeable lag between pressing a key and a terminal update, esp. when you hold some key such as backspace. Are there any plans to improve responsiveness?
Thanks, Victor. Please file a ticket at http://code.google.com/p/elt/issues/list . Also, provide as much detail as possible (your environment, etc.)
Cheers!
Yes, I also noticed it. when I make the view fullscreen the lag becomes huge. I will detail it soon by an issue. Anyway – this plugin is a begining of a beautiful frinedship! (and new way of working)
Great!! very useful plugin, i dont need open another terminal when i connect ADB over network (Android), thanks
Great work, Alex.
One question about it: how can I show more chars in a row, without any wrapping? Is it hardcoded 80 chars? Considering we all have widen screens nowadays…
Thank you!
Thanks Leo. The width is hard coded. We have a ticket filed. I hope to get this fixed soon.
Awesome, thanks Alex.
Great plugin!
One question though, is there a way for it to use my local .bash_profile on startup? I’m on OS X, and I’d love to have all of my aliases and configs loaded.
Thanks!
Actually, doing a:
ln -s ~/.bash_profile ~/.bashrc
seems to fix the issue.
Alternatively, running:
source ~/.bash_profile
each time seems to work too.
Great plugin! Thanks for the hard work.
The experiment I work with at CERN needs such a plugin for eclipse, but in a way that we can also control the environment in which the shell is spawned, not just the directory (e.g. automatically source some setup file/run some setup command, depending on where the terminal is opened, and automatically name the shell accordingly).
In your opinion, do you think such an extension will be easy for us to produce?
Thanks, Rob.
I have to implement something very similar for a use case we have at work. Implementing it should not be difficult. I think the plug-in has a good foundation and it would be a matter of just experimenting with the code.
In my case, I’ll be looking into it later in February (I’m in the middle of a big task that will take up the whole month.) I’ll let you know when I get something working, of if you do it first, please let me know :)
Cheers!
That is AWESOME
Looks good but unfortunately when in edit mode (vi) the width and height are limited. Width seems to be hard coded 80 chars (with wrapping) and height 21 lines. Is this hard coded or is there a way to change the settings?
Not at the moment, unfortunately. It will fix this issue on the next release.
Either way, it’s still an impressive and very useful plugin/tool. Looking forward to the next release.
Great plug-in!
Muchas gracias Alex!!
Awesome! This is just what I was looking for
First off, very cool plugin. Second, is there a way to issue eclipse Key shortcuts while the terminal is in focus? For example, I tried to issue Ctrl+Shift+F7 to jump back to the editor window, but the key presses appear to be intercepted by the terminal. Is there perhaps an escape sequence to issue key presses to eclipse (like in screen and tmux)?
Thanks!
Hi Alex,
Just what I need! Works great on my MBP.
Many thanks!
quote from Alex Ruiz:
The main reason for the fork is that we need to issue command-line commands in a way that doesn’t suck for the user. We need a quick way to say “hey terminal, execute this command, pronto”.
now THAT’s why I like it!
1 minor issue: availability of command line text editors… none of them (vim, nano, emacs) can be used within the terminal (doesn’t work in the other terminal plugin eighter…). Tmp solution:
alias emb=’gnome-terminal -x emacs -nw -q’ #emb as in emacs bash: types fast!
Thanks for the plugin.
{ 2 trackbacks }