PDA

View Full Version : Emacs as a Complete C++ IDE?



Majorix
September 24th, 2012, 01:09 PM
The school year has started, and for our OOP classes, the instructor told us to find ourselves an editor for the Linux environment.

I used to do it on gedit past years, but now I wanted something more advanced.

I immediately thought of emacs. I haven't used it before, but hear good things about it. However the question is, will I have any difficulties compiling multiple C++ source/header files, running and debugging them? If not, where can I learn how to use emacs?

Thanks.

CptPicard
September 24th, 2012, 02:00 PM
No, you won't have problems. Emacs can be customized to do pretty much anything you want, and it can be rather close to an IDE without actually being one.

That said, there is quite a bit of learning curve involved. If you're learning the typical C++ toolchain as well, I'd recommend just using it as an editor to begin with and learn to use all the other tools on the command line; hack up your Emacs installation to operate the tools once you know yourself how they work.

cortman
September 24th, 2012, 02:03 PM
I use emacs for all my text related operations. Programming for me doesn't go any deeper than scripting, but it works quite well for me with that. Here's (http://deep.syminet.com/emacside.html) a link that may or may not be of some help.

zombifier25
September 24th, 2012, 02:05 PM
Emacs is a extremely powerful multipurpose command line text editor (GUI version is available). This is a good tutorial for programming (writing, compiling, debugging, etc.) in Emacs (http://www.cs.bu.edu/teaching/tool/emacs/programming/).

It's recommended that you take the built-in Emacs tutorial first to familiar yourself.

Majorix
September 24th, 2012, 02:30 PM
Thanks for the replies guys!

@zombifier25:
I also discovered that page while google'ing. Seems very helpful!

Now I am doing the tutorial that came with emacs itself. Hopefully it will be all good now :)

1clue
September 24th, 2012, 03:18 PM
Speaking as a Vim guy, both Vim and Emacs are extremely capable editors for C and C++. I'm not trying to start anything here, just saying that a good share of Open Source was written using those editors. There are tons of tools out there that interact with them, and a whole lot of enthusiastic and capable users to get help from.

Also, I might point out that you should continue learning your editor until you have exhausted your ability to learn. People tend to learn enough to get by, and then they stop. Wherever they stop, that seems to be about as far as they ever get. With Vim, I got this same advice well over a decade ago, and I learned way more than I thought I would ever use back then, and that turned out to be considerably less than I wish I had learned right now. It's hard going back to the tutorial, and there's a certain benefit to learning as much as you can before you get comfortable.