From: Rando Christensen Date: 2002-11-21T22:27:25+09:00 Subject: Re: identing ruby in vim Wed, 20 Nov 2002 08:19:11 +0900: Gavin Sinclair ("Gavin Sinclair" ): > From: "Michael Brailsford" > Setting expandtab and foldmethod in a filetype plugin is indeed > appropriate, since it then applies to files of that type (in this > case, Ruby). However, I would use the *user's* ftplugin directory, > not the system one (small matter, I'm sure). i.e. > ~/.vim/ftplugin/ruby.vim Many VIM filetype plugins use vim variables to control whether folding takes place and how to fold for that language. unfortunately, the "official" ruby one distributed with VIM does not. It also seems to use a hardcoded two-spaces for indentation where the proper procedure would be to use tabs and let the user's tabstop/shiftwidth handle the rest. (If you do like indentation automatically done as spaces, that's easy to set up in vim independant of the filetype plugin, too) Maybe sometime soon i'll try to fix those parts of it and see if i can get it accepted to the vim tree. You can see perl/php examples with these lines in your ~/.vimrc: filetype plugin indent on set foldmethod=syntax let perl_fold = 1 " allow folding let php_folding = 1 " allow folding -- < There is a light that shines on the frontier > < And maybe someday, We're gonna be there. > < Rando Christensen / rando@babblica.net >