Live data from Hacker News

What I Wish I Had Known About Developing C/C++ From Linux Before I Started

derwiki.tumblr.com

1–10 of 104 posts

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#2
This is a nice list! However, I really think that increasing speed of development with better tools is a cornerstone of being one of those elite programmers, and vim<<eclipse, at least for Java! I haven't done C/C++ for some time... but I expected similar IDEs exist. "The way our development environment is set up though, there was really no good way to use Eclipse because everything is done on a remote development box, and they won’t let us run Eclipse and forward over X (which is reasonable; Eclipse has a lot of overhead)" I think this is just a horrendous setup and unless there is some compelling reason (e.g. scientific computing on a cluster? even then...) that there should be a much cleaner separation between development boxes and production boxes and most of your code should be developed on a local box with some canned data for testing and then pushed out to production when that is done. This may require some effort, but the decrease in turnaround time for changes will be worth it in almost every scenario.

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#3
I use "screen" a lot, but I wish it had a better name. It helps if you search for "gnu-screen", but not much.

Here's a tip that has saved me once or twice. If you start a long-running process, but forgot to use screen or nohup, bash lets you 'disown -h' its jobspec.

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#4
post #2

This is a nice list! However, I really think that increasing speed of development with better tools is a cornerstone of being one of those elite programmers, and vim<<eclipse, at least for Java! I haven't done C/C++ for some time... but I expected similar IDEs exist. "The way our development environment is set up though, there was really no good way to use Eclipse because everything is done on a remote development bo…

my thoughts exactly. in my last job, i spent over two years writing linux server apps. but i developed all my code on a mac. the low-level posix apis are nearly identical between the two, so other than a few ifdefs, i could barely tell the difference.

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#5
post #2

This is a nice list! However, I really think that increasing speed of development with better tools is a cornerstone of being one of those elite programmers, and vim<<eclipse, at least for Java! I haven't done C/C++ for some time... but I expected similar IDEs exist. "The way our development environment is set up though, there was really no good way to use Eclipse because everything is done on a remote development bo…

It's a rather massive codebase, and our remote dev machines are a lot beefier than our laptops -- also 64-bit, whereas our laptops are 32-bit. I'm not saying it couldn't be done locally, but it might actually cause more headaches than it solves.

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#6
post #2

This is a nice list! However, I really think that increasing speed of development with better tools is a cornerstone of being one of those elite programmers, and vim<<eclipse, at least for Java! I haven't done C/C++ for some time... but I expected similar IDEs exist. "The way our development environment is set up though, there was really no good way to use Eclipse because everything is done on a remote development bo…

Eclipse is an Integrated Development Environment. That is, all of the development tools are integrated into the editor.

I don't develop using an IDE, but I still have access to the same kind of functionality. It's just not integrated into my editor.

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#9
When I started developing in C in Vim there are two things I've gotten used to that I can't live without now: ctags and auto-complete (they help with eachother).

Ctags is great, especially for navigating someone else's code. What does this function do? Just ctrl-] and suddenly I'm at its definition. Something in there I don't recognize, same thing. Ctrl-t to go back up the tag stack. Ive become so used to navigating my code this way I have trouble without it.

Completion is just the way that Vim will give you completion matches in insert mode if you hit ctrl-n or ctrl-p. With C it's very smart about it and will automatically search included files. It's great for not having to worry about exact spellings on things. If you really like this sort of stuff there are a few plugins that do Textmate-like snippets.

Re: What I Wish I Had Known About Developing C/C++ From Linux Before I Started

#10
post #9

When I started developing in C in Vim there are two things I've gotten used to that I can't live without now: ctags and auto-complete (they help with eachother). Ctags is great, especially for navigating someone else's code. What does this function do? Just ctrl-] and suddenly I'm at its definition. Something in there I don't recognize, same thing. Ctrl-t to go back up the tag stack. Ive become so used to navigating…

Of course, if you use an IDE, it can do all of this for you and much more, and more accurately than ctags.
Post reply on HN