vim q
Baruch Siach
baruch at tkos.co.il
Thu Nov 11 05:05:30 IST 2010
Hi Shachar,
On Wed, Nov 10, 2010 at 10:41:36PM +0200, Shachar Shemesh wrote:
> On 10/11/10 10:17, Baruch Siach wrote:
> >Hi Erez,
> >
> >On Wed, Nov 10, 2010 at 10:08:32AM +0200, Erez D wrote:
> >>thank you all for the reply
> >>
> >>i decided to set ts,sw,et etc... in vimrc instead for security resons.
> >>although this implicate all types of files, i can ususally overcome it
> >>like pressing ^V-TAB in a makefile instead of a TAB
> >Or add the following to your .vimrc instead:
> >
> >au FileType make set noexpandtab
> THANK YOU!!!!
You're welcome.
> Now, I just need to see how to make vi disable tab expansion for C
> files if, and only if, I am editing the Linux kernel source code....
My solution is to put a local .vimrc at the Linux tree top level directory
with:
set noexpandtab
set ts=8
set shiftwidth=8
and set 'exrc' in my main .vimrc. To mitigate the security implications of
this change I also set 'secure'.
The limitation of this solution is that I must edit kernel files with the top
directory as my PWD.
baruch
> Either way, I edit makefiles at the same time I am editing
> C/C++/Java files, but when I'm editing kernel files, that's all I'm
> doing. As such, this is a much less urgent matter for me.
>
> Shachar
--
~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
More information about the Linux-il
mailing list