News for hackers. Stuff that matters.
Re:Vimcasts by nfnaaron on Tuesday March 30, 2010 @10:34AM (#1229225)
This is a good example of how to do a simple tutorial.

The tutorial video itself is well done.

Following the video is a concise recap of what was covered in the video.

At the end is a short, relevant list of "learn more" resources.

Well done.

Re:Vimcasts by tfh on Tuesday March 30, 2010 @08:56AM (#1228975)
The site is beautifully designed. Minimal, simple and effective. just like vim :)
Re:Vimcasts by erlanger on Tuesday March 30, 2010 @10:13AM (#1229169)
I'll pay vim many compliments, "minimal" is not one of them.
Re:Vimcasts by tfh on Tuesday March 30, 2010 @10:28AM (#1229209)
What i like about vim's UI is that it's very reduced to a minimum. New users have no idea how powerful it is.
Re:Vimcasts by nfnaaron on Tuesday March 30, 2010 @10:35AM (#1229228)
Come to the Dark Side. We have buffers.
Re:Vimcasts by sophacles on Tuesday March 30, 2010 @11:29AM (#1229360)
Wait, which dark side? (or possibly, what is the light side?) Both vim and emacs have buffers, including special ones...
Re:Vimcasts by 10ren on Tuesday March 30, 2010 @01:20PM (#1229655)
I use the arg list. I looked into buffers a while back, but they seemed overcomplex for what I need (same with windows). Checking the vim help just now, buffers and arglist seem (mostly) equivalent.

I'm curious: do you find there's specific advantages of buffers over the arglist? And, do you use buffers as well as, or instead of, the arglist?

The only problem I find is that if I start two vims in different xterms, sometimes I'll want to paste between them - so I need to use the system clipboard, instead of vim.

Re:Vimcasts by nfnaaron on Tuesday March 30, 2010 @01:46PM (#1229709)
Ah, my mistake. I meant registers, not buffers.

:help registers

As to your "I'm curious" question, I use both. Mostly arglist, and I resort to buffers when the arglist has gone squirrely (editing an additional file after starting with a number of files, e.g.).

For example, edit a small number of files (vi *).

:files will show you the list of files.

Repeating :n will take you through each file.

:e newfile to create a new file

:files will show you the list, with newfile at the end.

:rew to rewind the list

:n will get you to the last file on the original list, but not to newfile.

:bn will then get you to newfile.

Re:Vimcasts by 10ren on Thursday April 01, 2010 @12:15PM (#1234921)
I've had that problem, here's what I do:

:arge

will do the same as :e, but also add it to the arglist. You can prefix with a number to insert it at a particular position, especially :0arge and :99arge for first and last respectively. It only adds one at a time; several can be added with :arga (including recursive wildcards such as /*.java)

:argd %

will delete the current file (which % expands to) from the arglist.

BTW: I dislike pressing : and <CR> so instead of :n, my .vimrc has:

:map <C-n> <Esc>:n<CR> " next file, with control-n :map <C-p> <Esc>:N<CR> " prev file, with control-p

Re:Vimcasts by 10ren on Thursday April 01, 2010 @11:31PM (#1235951)
The recursive wildcard didn't come out right. It should be:

    **/*.java
And the mapping is:

    :map <C-n> <Esc>:n<CR>    " next file, with control-n
    :map <C-p> <Esc>:N<CR>    " prev file, with control-p
Re:Vimcasts by weaksauce on Wednesday March 31, 2010 @12:19AM (#1230913)
I just watched the video entitled "Working with Buffers" so I don't quite get your reference
Re:Vimcasts by nfnaaron on Friday April 02, 2010 @10:33AM (#1236514)
In the parent to my comment was this sentence: "New users have no idea how powerful it is."

That reminded me of this quote from Star Wars Episode VI: "You don't know the power of the Dark Side."

Which reminded me of the bumper sticker or T shirt: "Come to the Dark Side. We have cookies."

Which led to my comment: "Come to the Dark Side. We have buffers."

Buffers isn't important, except as something Vim has that can substitute for cookies.

Re:Vimcasts by cosmok on Tuesday March 30, 2010 @04:30PM (#1230082)
I would also recommend the Vim Tutorial Videos here: http://www.derekwyatt.org/vim/vim-tutorial-videos/
Re:Vimcasts by 25thhour on Tuesday March 30, 2010 @10:12AM (#1229167)
Great pacing and clearly communicated. Has helped me no end to get up to speed with Vim in my new job.
Re:Vimcasts by ZeroGravitas on Tuesday March 30, 2010 @07:01AM (#1228795)
If you're using Chrome right-click the video and open Video in New Tab or you'll get badly-resized, and pretty much unreadable text.

Looks much better in Firefox at the reduced size, but you'll probably still want to right-click and View Video to see it at its best.

Re:Vimcasts by nelstrom on Tuesday March 30, 2010 @08:43AM (#1228955)
Or you could subscribe to the podcast, and watch it offline: http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewPodcas...
Re:Vimcasts by brown9-2 on Tuesday March 30, 2010 @09:27AM (#1229050)
Thanks, I was just about to ask about the badly-resized video.

Also, thanks for revealing this "open Video in new tab" feature I've never seen before. Chrome is very pleasing in this manner.

Re:Vimcasts by oscardelben on Tuesday March 30, 2010 @07:36AM (#1228847)
It's ok for me in chrome (mac os x)
Re:Vimcasts by ZeroGravitas on Tuesday March 30, 2010 @07:54AM (#1228869)
Doesn't look like there's been any action in the bug tracking this issue:

http://code.google.com/p/chromium/issues/detail?id=19113

Are you running the very latest nightly code?

Re:Vimcasts by oscardelben on Tuesday March 30, 2010 @08:12AM (#1228902)
I'm not using nightly builds.
Re:Vimcasts by oscardelben on Tuesday March 30, 2010 @07:42AM (#1228852)
From the about page:

>Vimcasts is produced by Drew Neil (aka nelstrom), who came to Vim from TextMate. He made the switch when starting work at a company that uses Linux workstations. His choice of text editor was influenced by collegues.

Textmate is great, but this is something that concern me as well, as sooner or later I'll have to start over with a new editor. Hopefully I'll be able to learn something through these screencasts.

Re:Vimcasts by bittersweet on Wednesday March 31, 2010 @04:44AM (#1231240)
I, and as have a lot of others, went from TextMate to Vim. I was really looking into something fresh, and learning Vim has been a breath of fresh air.

I found it comparable to when I switched over from SVN to Git, it really made me revitalized my programming, I was looking forward to work with my new tools! I had that same feeling when picking up Vim, so I can wholeheartedly recommend!

Re:Vimcasts by chewbranca on Thursday April 01, 2010 @12:22PM (#1234939)
Glad to see a vimcasts site, more perspectives on vim are always welcome. I saw in the comments that you're using randiant cms, one thing you might want to check out is that the source code for railscasts.com is open source and is a pretty solid video cast site.
Re:Vimcasts by brianjherman on Tuesday March 30, 2010 @11:28PM (#1230845)
If you append all the vimrc together you get this: http://brianh.nfshost.com/vimrc.html
Re:Vimcasts by hubb on Tuesday March 30, 2010 @08:06AM (#1228890)
Re:Vimcasts by nelstrom on Tuesday March 30, 2010 @08:40AM (#1228951)
I gave the server a kick, so it should be back up now. Thanks for your patience.
Re:Vimcasts by thibaut_barrere on Tuesday March 30, 2010 @09:21AM (#1229031)
Hi Drew - I'm trying to find an email to contact you but cannot, I'll try here then: I'd like to add vimcasts to learnivore.com, is it possible ?
Re:Vimcasts by nelstrom on Tuesday March 30, 2010 @09:25AM (#1229045)
You'll get me with drew at the domain name. Sorry that's not more obvious.
Re:Vimcasts by thibaut_barrere on Tuesday March 30, 2010 @09:54AM (#1229120)
thanks! For the others, it will be added on learnivore end of week or sooner.
Re:Vimcasts by unignorant on Tuesday March 30, 2010 @08:00AM (#1228880)
Excellent! I tend to switch around between vim, emacs, and textmate -- this may give me the impetus to learn vim a bit more fully.
Re:Vimcasts by graywh on Tuesday March 30, 2010 @04:09PM (#1230025)
Personally, I've found some of the advice dubious or just plain wrong (e.g. trying to map control plus number key). But some of it looks terrific.
Re:Vimcasts by graywh on Wednesday March 31, 2010 @09:41AM (#1231733)
It's not nice to downvote a factual statement (that there is some advice that just doesn't work) without providing a counter-argument.

Seriously, vim doesn't handle maps for ctrl-1, ctrl-2, etc. or ctrl-shift-[, etc. because terminals don't have a way to represent them to running programs. (Technically, xterm has a mode, but no programs understand it.) And gui vim doesn't handle them (though, it could) because that would be too different from what terminal vim can do.

Re:Vimcasts by ldh on Tuesday March 30, 2010 @11:10AM (#1229310)
Awesome! I've been trying to immerse myself in Vim lately, so I'm excited to check these out.
Re:Vimcasts by rmoriz on Tuesday March 30, 2010 @07:54AM (#1228870)
awesome. please continue!
Re:Vimcasts by rmoriz on Tuesday March 30, 2010 @08:00AM (#1228878)
One note: please activate page caching. looks like your slicehost is quite busy atm.
Re:Vimcasts by nelstrom on Tuesday March 30, 2010 @08:55AM (#1228974)
Vimcasts.org runs on Radiant CMS, which has page caching enabled by default. My problem was too many app instances spinning up. I've limited the PassengerMaxPoolSize and PassengerMaxInstancesPerApp both to 2, which seems to have fixed it.

I appreciate this burst of traffic to help me get to the bottom of this.

Re:Vimcasts by sohooo on Tuesday March 30, 2010 @02:22PM (#1229788)
I wonder why you're running a clean site like vimcasts.org on a full-blown CMS. Imho this scenario longs for simpler solutions. Static site generators - in the Ruby universe: toto, nanoc, webby - come to mind.
Re:Vimcasts by rmoriz on Tuesday March 30, 2010 @03:38PM (#1229952)
Well, I guess your passenger/apache is not configured right to deliver the generated static files without using ruby or passenger besides your MaxInstances/PoolSize options.

I remember some issues with passengers and page caching (on nginx e.g.) which needed some tweaks.

Re:Vimcasts by rufo on Tuesday March 30, 2010 @05:45PM (#1230272)
Radiant uses Rack::Cache behind the scenes, so it still needs to be running.

I'm sure there's some reason it doesn't use Rails static caching, but even having used Radiant I'm not sure what it would be...

Re:Vimcasts by hello_moto on Tuesday March 30, 2010 @09:20AM (#1229029)
nelstrom, may I request for screencasts geared toward beginners? :D
Re:Vimcasts by nelstrom on Tuesday March 30, 2010 @09:23AM (#1229037)
Of course - and you're not the only one asking. The latest episode on modal editing ("the newbie killer") is a step back to basics. However, I don't intend to cover the material that you can find in the vimtutor.
Re:Vimcasts by hello_moto on Tuesday March 30, 2010 @09:53AM (#1229117)
Thanks!