Hacker News new | ask | show | jobs
by yberreby 3744 days ago
Autocompletion: YouCompleteMe + racer + racerd

Source formatting: rust.vim + rustfmt

Automatic building: https://github.com/passcod/cargo-watch

Error display: tmux, terminator or iTerm2 split planes

Rust has pretty good tool support in vim and Atom, for example (can't speak for the rest). We don't have stellar IDE support yet, but it's on the to-do list: https://www.rust-lang.org/ides.html

Personally, I don't miss IDEs. I like the approach of small, single-purpose, composable command-line utilities more.

4 comments

As I said, I don't want to learn how to use 5+ tools. I want to be able to install one thing, have everything work out of the box, and learn how to use their uniform and standard way of doing things.
I acknowledge that learning lots of tools just to start using a new language is a bit much.

However, the reason why so many people in this thread persist in suggesting that these tools are worth learning is that turns out most of these tools plug-and-play with whatever new language you feel like learning 6 months or 2 years or more from now.

Vim is one of the more popular editors to use in conjunction with this plug-and-play philosophy; if you have a change of heart and want to take a dive into learning to use Vim as such, I'd recommend Vim as an IDE[1], which addresses a lot of the points you brought up in your list of things you wish an IDE had.

[1]: https://github.com/jez/vim-as-an-ide

The problem with composable tools is that some things are really hard to compose and separate out, and have to be integrated: syntax highlighting, autocompletion and interactive debuggers are really hard to treat as separate programs.

You probably noticed how useless racer is on the command line: type code in your text editor and then when you want a completion, you go to your CLI and type "racer myfile.rs row,column" and there are your completions! :) Jokes aside: it's clearly superior (and intended) as an integrated tool than as a command line tool.

I'd argue that a debugger can offer the same kind of power being an integrated debugger as the (admittedly silly) racer example.

> Error display: tmux, terminator or iTerm2 split planes

Split panes are a poor substitute for actual error display integration; highlighting the errors in the source-code viewer, combined with a cross-linked list of errors is far more useful.

The linter-rust plugin for Atom provides this, as does the RustyCode plugin for VSCode.
Do you use all of the autocompletion options you listed? Or is YCM with --racer-completer enough?
I don't see another autocompletion option than YCM with --racer-completer in my list, so yes and yes. I use all the tools I listed regularly.
You listed racer + racerd separately so I wasn't sure if you meant the --racer-completer option or a different approach. Thanks.