Re: Tools for C/C++

Kaleb Pederson <[email protected]> Tue, 21 Sep 2010 07:32:49 -0700
Newsgroups gmane.comp.programming.refactoring
Message-ID <[email protected]>
On Tuesday, September 21, 2010 06:47:41 am you wrote:
>   Hi Mike,
> 
> Yes, it does.  I'm using it right now to set up for a Code Smells & 
> Refactoring demo later today.
> 
> My issue is that not a single developer at this client uses Eclipse.  
> Have you ever tried to tell 200+ developers to change their code editor? :)

I'm a Vim user with a penchant for refactoring :) ... and sadly, the two don't mix very well. Here are a few options:

1) Eclim (http://eclim.org/) basically takes Eclipse, makes it headless, and then uses Vim to access its functionality.  The features look fairly impressive, but I've never tried it myself. It looks, however, like it makes you learn new keystrokes.

2) vimplugin (http://sourceforge.net/projects/vimplugin/) is a nice way to embed gvim into Eclipse. However, the last titme I tried I couldn't find any way to do refactoring. There's only UI-level integration but no sharing of knowledge so the refactoring engine doesn't know where the cursor is nor is there a way to call out to the refactoring functionality.

3) vwrapper (http://vrapper.sourceforge.net/home/) provides vim-like editing in Eclipse. I just found this today and don't know anything about it although it seems well-liked in SO (http://stackoverflow.com/questions/1766067/what-is-the-most-useable-vi-vim-plugin-for-eclipse).

4) Standard Eclipse, with an external editor - It's easy to configure Eclipse to use an external editor (typically gvim) that can be used to edit files.  Then you spend most of the time in Vim but do refactorings in Eclipse.  This is how I typically use it. A couple of things I don't like about it -- Eclipse remembers the last editor, so I would have to tell vim to use the system editor, do the refactoring, and then remember to Eclipse to use vim again, or it would popup in the system editor next time. I suppose that's not more than slightly annoying.

Here's the script that I use to start gvim as an external editor:

#!/bin/sh
gvim --servername eclipse --remote-silent "$@"

An alternative:

5) SlickEdit - SlickEdit provides more refactorings than are available in Eclipse and provides vim-like functionality.  SlickEdit had no problem understanding my basic vim commands, but anytime I started doing something fairly complex (say, a mid-level vim user), it failed.  There were also vim keystrokes that SlickEdit had remapped (and documented accordingly) that wouldn't work. Note however that my experience is now two years old, so perhaps the newer version does better.  I made an extensive list of complaints and bug reports in my trial use at that time -- if they have been addressed in newer versions, it may be much better. However, it's commercial and will cost some money.

-- 
Kaleb Pederson

Blog - http://kalebpederson.com
Twitter - http://twitter.com/kalebpederson


> Thanks!
> 
> Dave...
> > I think Eclipse for Linux/C++ must have refactoring tools, no?
> >
> > On Tue, Sep 21, 2010 at 9:08 AM, Dave Rooney<[email protected]>  wrote:
> >
> >>
> >> Hi folks,
> >>
> >> I have a client who is doing C/C++ development in Linux, and is in
> >> desperate need of automated refactoring tools. Precisely none of the
> >> developers are using Eclipse but rather flavours of Emacs or VIM.
> >>
> >> I've been able to find a few open source plugins for VIM, and one
> >> commercial tool for Emacs (XRefactory), but not much else.
> >>
> >> I would appreciate any suggestions for tools, and any stories about your
> >> hands-on use with them.
> >>
> >> Thanks!
> >> --
> >> Dave Rooney
> >> Westboro Systems
> >> Web: http://www.WestboroSystems.com
> >> Blog: http://practicalagility.blogspot.com
> >> Twitter: daverooneyca
> 
> 
> 
> ------------------------------------
> 
> Yahoo! Groups Links
> 
> 
> 
> 


------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/refactoring/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/refactoring/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/