source: postlfs/editors/vim.xml@ 40fe030

10.0 10.1 11.0 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 ken/refactor-virt krejzi/svn lazarus nosym perl-modules qt5new systemd-11177 systemd-13485 trunk upgradedb xry111/git-date xry111/git-date-for-trunk xry111/git-date-test
Last change on this file since 40fe030 was 40fe030, checked in by Bruce Dubbs <bdubbs@…>, 15 years ago

Update to vim 7.1

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@6767 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 11.7 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY vim-download-http "http://ftp.at.vim.org/pub/vim/unix/vim-&vim-version;.tar.bz2">
8 <!ENTITY vim-download-ftp "ftp://ftp.vim.org/pub/vim/unix/vim-&vim-version;.tar.bz2">
9 <!ENTITY vim-md5sum "44c6b4914f38d6f9aa959640b89da329">
10 <!ENTITY vim-size "6.6 MB">
11 <!ENTITY vim-buildsize "75 MB">
12 <!ENTITY vim-time "0.8 SBU">
13]>
14
15<sect1 id="vim" xreflabel="Vim-&vim-version;">
16 <?dbhtml filename="vim.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>Vim-&vim-version;</title>
24
25 <indexterm zone="vim">
26 <primary sortas="a-Vim">Vim</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to Vim</title>
31
32 <para>The <application>Vim</application> package, which is an
33 abbreviation for VI IMproved, contains a <command>vi</command>
34 clone with extra features as compared to the original
35 <command>vi</command>.</para>
36
37 <para>The default LFS instructions install <application>vim</application>
38 as a part of the base system. If you would prefer to link
39 <application>vim</application> against <application>X</application>,
40 you should recompile <application>vim</application> to enable GUI mode.
41 There is no need for special instructions since
42 <application>X</application> support is automatically detected.</para>
43
44 <bridgehead renderas="sect3">Package Information</bridgehead>
45 <itemizedlist spacing="compact">
46 <listitem>
47 <para>Download (HTTP): <ulink url="&vim-download-http;"/></para>
48 </listitem>
49 <listitem>
50 <para>Download (FTP): <ulink url="&vim-download-ftp;"/></para>
51 </listitem>
52 <listitem>
53 <para>Download MD5 sum: &vim-md5sum;</para>
54 </listitem>
55 <listitem>
56 <para>Download size: &vim-size;</para>
57 </listitem>
58 <listitem>
59 <para>Estimated disk space required: &vim-buildsize;</para>
60 </listitem>
61 <listitem>
62 <para>Estimated build time: &vim-time;</para>
63 </listitem>
64 </itemizedlist>
65
66 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
67 <itemizedlist spacing='compact'>
68 <listitem>
69 <para>Recommended Patch: <ulink
70 url="&patch-root;/vim-&vim-version;-mandir-1.patch"/></para>
71 </listitem>
72 <listitem>
73 <para>Translated Vim messages: <ulink
74 url="http://ftp.at.vim.org/pub/vim/extra/vim-&vim-version;-lang.tar.gz"/>
75 </para>
76 </listitem>
77 </itemizedlist>
78
79 <bridgehead renderas="sect3">Vim Dependencies</bridgehead>
80
81 <bridgehead renderas="sect4">Recommended</bridgehead>
82 <para role="recommended"><xref linkend="x-window-system"/></para>
83
84 <bridgehead renderas="sect4">Optional</bridgehead>
85 <para role="optional"><xref linkend="gtk2"/> OR
86 <xref linkend="lesstif"/> OR
87 <xref linkend="GTK"/>,
88 <xref linkend="python"/>,
89 <xref linkend="tcl"/>,
90 <xref linkend="ruby"/>, and
91 <xref linkend="gpm"/></para>
92
93 <para condition="html" role="usernotes">User Notes:
94 <ulink url="&blfs-wiki;/vim"/></para>
95
96 </sect2>
97
98 <sect2 role="installation">
99 <title>Installation of Vim</title>
100
101 <note>
102 <para>If you recompile <application>Vim</application> to link against
103 <application>X</application>, and your <application>X</application>
104 libraries are not on the root partition, you will no longer have an editor
105 for use in emergencies. You may choose to install an additional editor,
106 not link <application>Vim</application> against
107 <application>X</application>, or move the current <command>vim</command>
108 executable to the <filename class="directory">/bin</filename> directory
109 under a different name such as <filename>vi</filename>.</para>
110 </note>
111
112 <para>If desired, unpack the translated messages archive:</para>
113
114<screen><userinput>tar -xf ../vim-&vim-version;-lang.tar.gz --strip-components=1</userinput></screen>
115
116 <para>Install <application>Vim</application> by running the following
117 commands:</para>
118
119<screen><userinput>patch -Np1 -i ../vim-&vim-version;-mandir-1.patch &amp;&amp;
120echo '#define SYS_VIMRC_FILE "/etc/vimrc"' &gt;&gt; src/feature.h &amp;&amp;
121echo '#define SYS_GVIMRC_FILE "/etc/gvimrc"' &gt;&gt; src/feature.h &amp;&amp;
122./configure --prefix=/usr --with-features=huge &amp;&amp;
123make</userinput></screen>
124
125 <para>To test the results, issue: <command>make test</command>.
126 The <application>vim</application> test suite outputs a lot of binary
127 data to the screen, which can cause issues with the settings of the
128 current terminal. This can be resolved by redirecting the output to a
129 log file. Even if one of the tests fails to produce the file
130 <filename>test.out</filename> in <filename
131 class="directory">src/testdir</filename>, the remaining tests will still
132 be executed. If all goes well,the final message in the log file will be
133 <literal>ALL DONE</literal>. <emphasis>Note</emphasis>: Some color tests
134 expect to be executed under the <command>xterm</command> terminal
135 emulator.</para>
136
137 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
138
139<screen role="root"><userinput>make install</userinput></screen>
140
141 <para>By default, Vim's documentation is installed in <filename
142 class="directory">/usr/share/vim</filename>. The following symlink allows
143 the documentation to be accessed via <filename
144 class="directory">/usr/share/doc/vim-7.0</filename>, making it consistent
145 with the location of documentation for other packages:</para>
146
147<screen role="root"><userinput>ln -snfv ../vim/vim70/doc /usr/share/doc/vim-7.0</userinput></screen>
148
149 </sect2>
150
151 <sect2 role="commands">
152 <title>Command Explanations</title>
153
154 <para><command>patch &hellip;</command>: These patches are the same as LFS
155 and update the package with upstream patches and ensure the man pages
156 are placed in the proper locations.</para>
157
158 <para><parameter>--with-features=huge</parameter>: This switch enables all
159 the additional features available in <application>Vim</application>.</para>
160
161 <para><option>--enable-gui=no</option>: This will prevent compilation of the
162 GUI. <application>Vim</application> will still link against
163 <application>X</application> so that some nice eye-candy such as updating the
164 title bar of an <application>Xterm</application> window are available.</para>
165
166 <para><option>--without-x</option>: If you prefer not to link
167 <application>Vim</application> against <application>X</application>, use
168 this switch.</para>
169
170 <para><option>--enable-perlinterp</option>, <option>--enable-pythoninterp</option>,
171 <option>--enable-tclinterp</option>, <option>--enable-rubyinterp</option>:
172 These options include the Perl, Python, Tcl, or Ruby interpreters that allow
173 using other application code in <application>vim</application> scripts.</para>
174
175 </sect2>
176
177 <sect2 role="configuration">
178 <title>Configuring Vim</title>
179
180 <sect3 id='vim-config'>
181 <title>Config Files</title>
182
183 <para><filename>/etc/vimrc</filename> and
184 <filename>~/.vimrc</filename></para>
185
186 <indexterm zone="vim vim-config">
187 <primary sortas="e-etc-vimrc">/etc/vimrc</primary>
188 </indexterm>
189
190 <indexterm zone="vim vim-config">
191 <primary sortas="e-AA.vimrc">~/.vimrc</primary>
192 </indexterm>
193
194 </sect3>
195
196 <sect3 id='vim-init'>
197 <title>Configuration Information</title>
198
199 <para><application>Vim-7.0</application> introduced an
200 integrated spell checker that doesn't requires additional libraries to be
201 installed. To enable the spell checker you can set the following in
202 one of the configuration files: </para>
203
204<screen><literal>set spell
205spelllang=en,ru</literal></screen>
206
207 <para>By default, <application>Vim</application> only installs spell
208 files for the English language. If a spell file is not available for
209 your language, then <application>Vim</application> will call
210 <filename>$VIMRUNTIME/plugin/spellfile.vim</filename> and will try to
211 obtain the *.spl and optionally *.sug from the vim ftp server, using the
212 <filename>$VIMRUNTIME/plugin/netrw</filename> plugin.</para>
213
214 <para>Alternatively you can manually download the *.spl and *.sug files
215 from: <ulink url="ftp://ftp.vim.org/pub/vim/runtime/spell/"/> and save
216 them to <filename class="directory"> ~/.vim/spell </filename> or in
217 <filename class="directory">
218 /usr/share/vim/vim70/spell/</filename>.</para>
219
220 <para>For more information about the spell checker and some other
221 features in <application>Vim-&vim-version;</application> (such us
222 vimgrep, tab-pages, and omni-completion), issue the following command inside
223 <application>Vim</application>:</para>
224
225<screen><literal>:help version7</literal></screen>
226
227 <para>For additional information on setting up
228 <application>Vim</application> configuration files, see <xref
229 linkend="postlfs-config-vimrc"/> and <ulink
230 url='http://www.vi-improved.org/vimrc.php'/>. </para>
231
232 </sect3>
233
234 </sect2>
235
236 <sect2 role="content">
237 <title>Contents</title>
238
239 <para>A list of the reinstalled files, along with their short
240 descriptions can be found in the <ulink
241 url="&lfs-root;/chapter06/vim.html#contents-vim">LFS Vim Installation
242 Instrutions</ulink></para>
243
244 <segmentedlist>
245 <segtitle>Installed Programs</segtitle>
246 <segtitle>Installed Libraries</segtitle>
247 <segtitle>Installed Directory</segtitle>
248
249 <seglistitem>
250 <seg>gview, gvim, gvimdiff, rgview, and rgvim</seg>
251 <seg>None</seg>
252 <seg>/usr/share/vim</seg>
253 </seglistitem>
254 </segmentedlist>
255
256 <variablelist>
257 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
258 <?dbfo list-presentation="list"?>
259 <?dbhtml list-presentation="table"?>
260
261 <varlistentry id="gview">
262 <term><command>gview</command></term>
263 <listitem>
264 <para>starts <command>gvim</command> in read-only mode.</para>
265 <indexterm zone="vim gview">
266 <primary sortas="b-gview">gview</primary>
267 </indexterm>
268 </listitem>
269 </varlistentry>
270
271 <varlistentry id="gvim">
272 <term><command>gvim</command></term>
273 <listitem>
274 <para>is the editor that runs under <application>X</application>
275 and includes a GUI.</para>
276 <indexterm zone="vim gvim">
277 <primary sortas="b-gvim">gvim</primary>
278 </indexterm>
279 </listitem>
280 </varlistentry>
281
282 <varlistentry id="gvimdiff">
283 <term><command>gvimdiff</command></term>
284 <listitem>
285 <para>edits two or three versions of a file with
286 <command>gvim</command> and shows the differences.</para>
287 <indexterm zone="vim gvimdiff">
288 <primary sortas="b-gvimdiff">gvimdiff</primary>
289 </indexterm>
290 </listitem>
291 </varlistentry>
292
293 <varlistentry id="rgview">
294 <term><command>rgview</command></term>
295 <listitem>
296 <para>is a restricted version of <command>gview</command>.</para>
297 <indexterm zone="vim rgview">
298 <primary sortas="b-rgview">rgview</primary>
299 </indexterm>
300 </listitem>
301 </varlistentry>
302
303 <varlistentry id="rgvim">
304 <term><command>rgvim</command></term>
305 <listitem>
306 <para>is a restricted version of <command>gvim</command>. </para>
307 <indexterm zone="vim gvim">
308 <primary sortas="b-gvim">gvim</primary>
309 </indexterm>
310 </listitem>
311 </varlistentry>
312
313 </variablelist>
314
315 </sect2>
316
317</sect1>
Note: See TracBrowser for help on using the repository browser.