Live data from Hacker News

Vim is hard, I just want to click around

jeffkreeftmeijer.com

51–60 of 98 posts

Re: Vim is hard, I just want to click around

#51
I still click around in MacVim sometimes (mostly for navigating deep NERDtree hierarchies and for selecting text within a line).

It's all about what's going to be fastest and take the least amount of mental context switching. I didn't choose vim because it's so hard to move to the mouse occasionally, I chose it because some things are much faster/easier than in TextMate, and for some things the mouse is still faster.

Sure, from a purist point of view it's terrible, but I think vim mastery has diminishing returns at some point (granted, it's a pretty far point up the learning curve).

Re: Vim is hard, I just want to click around

#52
post #12

Earlier quoted context omitted.

> don't give up Yes. All the tutos I have read recently insist on using hjkl, which is a matter of taste, but do not emphasize what I believe is the most important (for terminal use): cut and paste. - Easy cut and paste in Vim is done with yy and p, avoid mouse and ctrl-c/v or any other trick that is not "inside" Vim. - Good trick are to first select a block with . - Don't forget P, which is pasting above current lin…

Also worth remembering is that every command that deletes really cuts . Which is to say, deletion commands like x and dd store the deleted content in the register that will be used when you hit p or P. This is important to know both because it can be very useful sometimes and because it can get in your way other times (e.g., if you're trying to repeat an action and keep replacing a line with another line, you'll have…

Or you can specify the register name. Don't limit yourself to the unnamed register.

Re: Vim is hard, I just want to click around

#53
post #2

I too wanted to click around the first month (+/-) after switching to vim, I think we all did. However, it seems like the author learned the basics of vim, but stopped before he learned about powerful navigation keys, visual mode etc. I think the moral is: if you feel you don't get the hang of vim/nerdtree etc., don't give up - keep going, there is a reason why so many people use it.

During my undergrad time (circa 2002), I spent around 6 months using nothing but Vim. I really wanted to "grok" it.

Even after learning a lot of the commands and the different modes, it never grew on me.

I think it is a shame as I touch-type and try to minimize the use of the mouse via shortcuts.

Re: Vim is hard, I just want to click around

#55

I've always been a little puzzled by people who use a file-drawer or file-list or similar addon with Vim, and I now I think I know why: I'm guessing most of these people have Vim open as their One Tool, much like another programmer might have Xcode or Visual Studio open as their One Tool, and they want to get everything done in it. At work, I usually have at least two windows open at all times: Vim full-screen on one…

Unfortunately, the remote features require a GUI version of vim. Personally, I prefer to run vim in a tab of my terminal.

Under Linux I always run vim in a terminal. Part of this is habit because I (in the past) often edit files on remote computers and I like the consistency.

On my mac I end up using MacVim mostly so that my Vim and Terminal apps can be considered separate apps for the purpose of things like spaces, and it just seemed to integrate a little better with the Mac infrastructure.

But in general I haven't found a reason to prefer a GUI version over a terminal version when a sufficiently capable terminal is available.

Re: Vim is hard, I just want to click around

#56
I'm working on a Gtk2 application that basically solves the same problem. It adds a sidebar with things like a file browser to a GVim editor. For getting a feel for a foreign codebase I find it much easier to use something like this than to switch between navigation/file view all the time.

I tried plugins like NERDTree, which are awesome in one way because they work everywhere vim works (like in the terminal). However, I didn't really like their feel in combination with GVim and tabs.

Re: Vim is hard, I just want to click around

#57
post #40

Earlier quoted context omitted.

One of the biggest shortcomings of vim is the lack of a good ido-mode style file-opener. People seem to rave about command-t, although getting it set up on Windows proved too annoying for me. FuzzyFinder is nice, but graphically it's a mess. Like everything else in vim, really.

This is the biggest meta-shortcoming of vim: the fact that it doesn't come with a built-in programming language. This forces extension authors to bring their own, with the expected consequences.

It has vimscript, but vimscript is at best emacs-lisp's inbred nephew who is just as old but huffs glue and has sex with chickens.

Re: Vim is hard, I just want to click around

#58
post #57

Earlier quoted context omitted.

This is the biggest meta-shortcoming of vim: the fact that it doesn't come with a built-in programming language. This forces extension authors to bring their own, with the expected consequences.

It has vimscript, but vimscript is at best emacs-lisp's inbred nephew who is just as old but huffs glue and has sex with chickens.

Actually, you can also use mzscheme, perl, python, ruby, and lua to script vim.

Re: Vim is hard, I just want to click around

#59
gVim is hard; I just want to type ctrl-v to enter blockwise Visual mode.

I normally use vim on the command line, but a lot of my coworkers use gVim on Windows. Whenever I try to help one of them out, I can't stand the fact that ctrl-v is remapped to paste by default. I recently found out how to make gVim sane again. In _vimrc, comment-out the following lines:

  behave mswin
  source $VIMRUNTIME/mswin.vim

Re: Vim is hard, I just want to click around

#60
Getting familiar with GNU screen and within vim, liberal use of :tabnew foo got me to prefer a terminal emulator for working and notes over eclipse / gedit / nautilus. (gt and gT move to different tabs and :tabm N moves the current tab to tab N btw). If from within vim you :mksession bar.vim, vim saves all your open tabs so you can :wqall and open the tabs again from the shell with vim -S bar.vim

Like seemingly everyone, I organize projects into project/doc, project/src, project/data, project/bin etc. For example, I have a start.vim each in project/doc and project/src.

Then I put lines in ~/.screenrc

  chdir /home/horseshoes/workin/myproject/doc
  screen -t myproject_doc vim -S start.vim
  chdir /home/horseshoes/workin/myproject/src
  screen -t myproject_src vim -S start.vim
  screen -t bash bash
When I start screen it automatically opens one window containing a vim sesh with all my most-looked-at documentation tabs (so I can refer to wth I was thinking and organize my mental pushdown stack a little), one window containing a sesh for the source files I currently work on, and a third window holds a shell so I can look for and alter other files or start sqlite3 or make or w/e.

The point is it fires up work for me so I just have to open a terminal and type screen and it's instantly ready compared to opening eclipse or visual studio and then navigating to the relevant related notes and documents, or cluttering up the place with a billion (or even 2 or 3) terminal emulators, since screen multiplexes them. I also like to have screen windows open with cmus (music) and a python interpreter (my calculator and preferred random 'what to make for dinner' decision maker).

I also prefer the command-line environment for programming and also most general use because of the kool tools it's full of you are no doubt very acquainted with (ls, locate, grep, less, ps, pipes et al).

Post reply on HN