Article View: comp.editors
Article #1355Re: How to store tabstop in vi permanently??
From: Steve Hollasch
Date: Thu, 12 Nov 1992 00:01
Date: Thu, 12 Nov 1992 00:01
31 lines
1885 bytes
1885 bytes
"Ravi Parthasarathy <ravi@blore.b30.ingr.COM>" writes:
| How does one change the default tabstop in vi?
| presently, i am typing in :set tabstop=4 while edititng a file. I would like
| to set this value and vi should come up with this tabstop everytime it is
| ivoked.
I strongly recommend that you leave tabstops at the default 8 spaces,
since the convention for printers, tty devices, and just about everything
else in the world interprets a tab character as 8 spaces.
Instead, change the "shiftwidth" setting in vi to whatever indentation
level you want (I use 4). Then you use ^T and ^D in vi to indent and
unindent, respectively.
To do this, you can either include
setenv EXRC "set sw=4"
in your .login file (I'm assuming you use csh), or you can create a file
called .exrc in your home directory with the line
set sw=4
I recommend the .exrc file, because it's much easier to add macros and other
settings to this file. vi will use this file unless there's a .exrc file in
the current directory (so you can have other vi settings for a certain
directory).
______________________________________________________________________________
Steve Hollasch Kubota Pacific Computer, Inc.
hollasch@kpc.com Santa Clara, California
Technical Details
Message-ID:
<1992Nov12.000116.23736@kpc.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!ferkel.ucsb.edu!taco!rock!stanford.edu!ames!haven.umd.edu!darwin.sura.net!sgiblab!news.kpc.com!kpc!hollaschReferences:
<1992Nov11.200142.5189@b30.ingr.com>Show Full Headers
Complete Article Headers
Newsgroups: comp.editors Path: arc1-ca.pugleaf.net!sparky!uunet!ferkel.ucsb.edu!taco!rock!stanford.edu!ames!haven.umd.edu!darwin.sura.net!sgiblab!news.kpc.com!kpc!hollasch From: hollasch@kpc.com (Steve Hollasch) Subject: Re: How to store tabstop in vi permanently?? Message-ID: <1992Nov12.000116.23736@kpc.com> Summary: Don't mess with tabstop, set swiftwidth instead. Sender: usenet@kpc.com Organization: Kubota Pacific Computer, Inc. References: <1992Nov11.200142.5189@b30.ingr.com> Date: Thu, 12 Nov 1992 00:01:16 GMT Lines: 31