6 ms·
I Code With Things and Stuff
- burke 15y agoThis story parallels my own on a nearly-disturbing number of levels. Exactly the same experience. I never thought I'd switch from emacs, then I finally gave vim a good shot (switched for two weeks and made a very conscious effort to use it effectively), and was blown away by how much faster I could edit text.
- JoelMcCracken 15y agoHave you tried viper mode, etc?
- burke 15y agoI did. In fact, I used viper mode (vimpulse) for about three weeks before deciding it was worth a shot to just try vim proper. I haven't really looked back. Viper was alright, but there were far too many moving parts in that setup.
- JoelMcCracken 15y agoI see. I really didn't like viper mode (the little bit that I used it), but I occasionally do miss Vim. I could never leave Emacs at this point, though. Elisp is just too great.
- Marwy 15y ago"Moving parts" doesn't really say anything.
- JoelMcCracken 15y agoI think I see what he means. Viper is really... strange. When I originally moved from Vim to Emacs, I found Viper /harder/ than just learning regular ol' Emacs. I assume "Moving parts" refers to exactly the same problems that I had. I could explain more, but it would take time, because I need to figure out some examples instead of explaining my vague impressions of a few years ago. Point is, as an avid emacs user, I totally get where he is coming from.
- Rayne 15y agoIsn't vimpulse the successor to that and evil-mode the successor to vim-pulse? Seems like viper is way down on that list.
- JoelMcCracken 15y agoYeah. Not sure which one I used at all, though.
- Jach 15y agoFor Clojure specifically, the Rainbow Parens addon for vim is fantastic. Also I've found using GNU screen to split a terminal with one half vim and the other half a REPL to be Good Enough for a lot of purposes. I was also going to mention a few other useful Lispy things you can do with vim (like d% to delete an expression), but this page covers them pretty well: http://cybertiggyr.com/15-vim/ http://cybertiggyr.com/15-vim/
- Rayne 15y agoFantastic! Thanks for mentioning this. I'll come in handy.
- jayferd 15y agoDoes anyone know of a modal editor that has an actual scripting language (i.e. better than VimL) behind it? I'm not satisfied with: * tcl/ruby/python interfaces to Vim, because they're horrifically documented, and plugins using these are difficult to distribute * Re-implementations of a subset of Vim's mountain of hacks in a different language (see jsvim, et al)
- Rayne 15y agoYeah, it is unfortunate how terribly documented they are. Not sure what you mean by difficult to distribute though. You either load the file from VimL or you embed the code in VimL. You distribute it like any Vim plugin. The documentation for the interfaces serves as decent reference material. What is really lacking is a long tutorial on the subject that is in an easy to find place.
- jayferd 15y agoIt's the classic linking problem - if you write a plugin in $LANGUAGE, the end-user has to have a Vim compiled with $LANGUAGE support. My favorite example is Command-T. In order to link VimL to C, he had to write a Ruby extension and use the Ruby interface. Which is a total pain.
- Rayne 15y agoYeah, you've got me there.
- notJim 15y agoSublime Text 2 has both a Python API and a plugin that makes it act sort of like VIM. Frankly, the plugin is pretty bad if you're used to VIM, but there's active development on it (it's open source [1]), and it's apparently good enough for many people. If you want to try this out, there's also a plugin that gives you an Ex-Mode [2], which I gather is something VIM users might want (I'm frankly not sure what it is.) [1]: https://github.com/sublimehq/Vintage https://github.com/sublimehq/Vintage [2]: https://github.com/SublimeText/VintageEx https://github.com/SublimeText/VintageEx
- moonchrome 15y agoI like Vim but using Clojure forces you to deal with Java at some point - and having auto complete is crucial to me. VimClojure isn't really good in advanced functionality, eg. autocomplete is clunky and runing things in REPL can block VIM if your REPL command blocks. I couldn't even get emacs to work with Clojure and I don't like the CTR+* interface so I didn't spend much time on it. In the end IntellJ + La Clojure + Lein plugin + IdeaVim works perfect, you have a good REPL, autocomplete and debugging.
- Rayne 15y agohttps://github.com/ervandew/supertab https://github.com/ervandew/supertab seems nice for completing based on the current context. I seem to recall VimClojure having some kind of completion, but don't hold me to that. Also, like I said in the blog post, there is nothing wrong with your setup if you are productive and happy with it.
- snprbob86 15y agoRE: "the operating system’s Open File dialog." I'm a MacVim guy. When working on a project, I exclusively use FuzzyFinder_TextMate and the :edit command. Occasionally I still use cmd+o (primarily when I want to do a one-off file edit and know where the file is "visually" relative to my DropBox folder or something) Anyway: Here's a Mac tip! In the native file chooser dialog, simply type ~ or / and the "Go to folder" sub-dialog will slide down and you can type a path! It even has (very primitive) tab completion.
- Rayne 15y agoI didn't know about this. That'll definitely come in handy. Thanks. :)
- ceol 15y agoAlso, ST2 has a command line tool `subl` for opening files and projects. If you're on OS X, you can find this in `/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/`. All you need to do is symlink it to `~/bin/subl` and you're good to go. More information: http://www.sublimetext.com/docs/2/osx_command_line.html http://www.sublimetext.com/docs/2/osx_command_line.html
- djhworld 15y agoI would move from EMACS to Vim quite easily (I was a Vim user before I started learning Clojure) and I mirror the authors thoughts about just using SLIME as an in-editor REPL. The problem for me is the fact that the SLIME REPL offers pretty decent tab-completion Whereas lein-repl doesn't. That's the only thing that's sort of keeping me on the EMACS side of the fence
- Rayne 15y agoIn Leiningen 2, `lein repl` will be https://github.com/trptcolin/reply https://github.com/trptcolin/reply which has tab completion. May not be perfect yet (I haven't tried it personally) but I expect it to improve.