source: postlfs/editors/vim.xml@ fce275e

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 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 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since fce275e was 35dbf85, checked in by Randy McMurchy <randy@…>, 16 years ago

Fixed a typo in the Vim instructions

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

  • Property mode set to 100644
File size: 12.7 KB
RevLine 
[b5951ec]1<?xml version="1.0" encoding="ISO-8859-1"?>
[6732c094]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[b5951ec]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">
[40fe030]9 <!ENTITY vim-md5sum "44c6b4914f38d6f9aa959640b89da329">
10 <!ENTITY vim-size "6.6 MB">
11 <!ENTITY vim-buildsize "75 MB">
[e26dfbf7]12 <!ENTITY vim-time "0.8 SBU">
[b5951ec]13]>
14
[28badf4]15<sect1 id="vim" xreflabel="Vim-&vim-version;">
[0ec75653]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>
[3aa07d1]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
[0ec75653]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'>
[e26dfbf7]68 <listitem>
[0f39a2b]69 <para>Required Patch: <ulink
[e26dfbf7]70 url="&patch-root;/vim-&vim-version;-mandir-1.patch"/></para>
71 </listitem>
[0f39a2b]72 <listitem>
73 <para>Required Patch: <ulink
[6e11352]74 url="&patch-root;/vim-&vim-version;-fixes-6.patch"/></para>
[0f39a2b]75 </listitem>
[0ec75653]76 <listitem>
[3aa07d1]77 <para>Translated Vim messages: <ulink
[0ec75653]78 url="http://ftp.at.vim.org/pub/vim/extra/vim-&vim-version;-lang.tar.gz"/>
79 </para>
80 </listitem>
81 </itemizedlist>
82
[3493b1f]83 <bridgehead renderas="sect3">Vim Dependencies</bridgehead>
[0ec75653]84
85 <bridgehead renderas="sect4">Recommended</bridgehead>
[e77976f]86 <para role="recommended"><xref linkend="x-window-system"/></para>
[0ec75653]87
88 <bridgehead renderas="sect4">Optional</bridgehead>
[6ae4193]89 <para role="optional"><xref linkend="gtk2"/> or
90 <xref linkend="lesstif"/> or
[bbaa1db]91 <xref linkend="GTK"/>,
[3aa07d1]92 <xref linkend="python"/>,
93 <xref linkend="tcl"/>,
[6ae4193]94 <xref linkend="ruby"/>, and
95 <xref linkend="gpm"/></para>
96 <!-- mentioned below as a runtime dependency
[410e228b]97 <xref linkend="rsync"/> (to update the runtime files)
[6ae4193]98 -->
[0ec75653]99
[3597eb6]100 <para condition="html" role="usernotes">User Notes:
101 <ulink url="&blfs-wiki;/vim"/></para>
102
[0ec75653]103 </sect2>
104
105 <sect2 role="installation">
106 <title>Installation of Vim</title>
107
108 <note>
[3aa07d1]109 <para>If you recompile <application>Vim</application> to link against
[32d0e29]110 <application>X</application> and your <application>X</application>
[823b1a3]111 libraries are not on the root partition, you will no longer have an editor
[3aa07d1]112 for use in emergencies. You may choose to install an additional editor,
113 not link <application>Vim</application> against
[d612b9f]114 <application>X</application>, or move the current <command>vim</command>
[3aa07d1]115 executable to the <filename class="directory">/bin</filename> directory
[0ec75653]116 under a different name such as <filename>vi</filename>.</para>
117 </note>
118
119 <para>If desired, unpack the translated messages archive:</para>
120
[8ba8ab5]121<screen><userinput>tar -xf ../vim-&vim-version;-lang.tar.gz --strip-components=1</userinput></screen>
[d612b9f]122
[0ec75653]123 <para>Install <application>Vim</application> by running the following
124 commands:</para>
[b5951ec]125
[40fe030]126<screen><userinput>patch -Np1 -i ../vim-&vim-version;-mandir-1.patch &amp;&amp;
[35dbf85]127patch -Np1 -i ../vim-&vim-version;-fixes-6.patch &amp;&amp;
[e26dfbf7]128echo '#define SYS_VIMRC_FILE "/etc/vimrc"' &gt;&gt; src/feature.h &amp;&amp;
[b5951ec]129echo '#define SYS_GVIMRC_FILE "/etc/gvimrc"' &gt;&gt; src/feature.h &amp;&amp;
[8e8356d]130./configure --prefix=/usr --with-features=huge &amp;&amp;
[0ec75653]131make</userinput></screen>
132
[83d6546]133 <para>To test the results, issue: <command>make test</command>.
134 The <application>vim</application> test suite outputs a lot of binary
135 data to the screen, which can cause issues with the settings of the
136 current terminal. This can be resolved by redirecting the output to a
137 log file. Even if one of the tests fails to produce the file
138 <filename>test.out</filename> in <filename
139 class="directory">src/testdir</filename>, the remaining tests will still
140 be executed. If all goes well,the final message in the log file will be
141 <literal>ALL DONE</literal>. <emphasis>Note</emphasis>: Some color tests
142 expect to be executed under the <command>xterm</command> terminal
143 emulator.</para>
144
[0ec75653]145 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
146
147<screen role="root"><userinput>make install</userinput></screen>
148
[95799899]149 <para>By default, Vim's documentation is installed in <filename
150 class="directory">/usr/share/vim</filename>. The following symlink allows
151 the documentation to be accessed via <filename
[6e11352]152 class="directory">/usr/share/doc/vim-&vim-version;</filename>, making it
153 consistent with the location of documentation for other packages:</para>
[841a93f]154
[410e228b]155<!-- When updating, be sure to change the line below for the proper 'vimxx' unpacked
[841a93f]156 directory -->
157
158<screen role="root"><userinput>ln -snfv ../vim/vim71/doc /usr/share/doc/vim-&vim-version;</userinput></screen>
[95799899]159
[6ae4193]160 <para>If you wish to update the runtime files, issue the
161 following command (requires <xref linkend="rsync"/>):</para>
[fd7e0ed6]162
[32d0e29]163<screen><userinput>rsync -avzcP --delete --exclude="/dos/" --exclude="/spell/" \
164 ftp.nluug.nl::Vim/runtime/ ./runtime/</userinput></screen>
[6e11352]165
[32d0e29]166 <para>To install the runtime files and regenerate the
167 <filename>tags</filename> file, as the
168 <systemitem class="username">root</systemitem> user issue:</para>
[6e11352]169
[2202183]170<screen role="root"><userinput>make -C src installruntime &amp;&amp;
171vim -c ":helptags /usr/share/doc/vim-&vim-version;" -c ":q"</userinput></screen>
[6e11352]172
[0ec75653]173 </sect2>
174
175 <sect2 role="commands">
176 <title>Command Explanations</title>
177
[32d0e29]178 <para><command>patch &hellip;</command>: These patches are the same as the
[8ae8a12a]179 ones in the LFS build used to update the package with upstream patches
[32d0e29]180 and ensure the man pages are placed in the proper locations.</para>
[e26dfbf7]181
[3aa07d1]182 <para><parameter>--with-features=huge</parameter>: This switch enables all
[0ec75653]183 the additional features available in <application>Vim</application>.</para>
184
[88a2276]185 <para><option>--enable-gui=no</option>: This will prevent compilation of the
186 GUI. <application>Vim</application> will still link against
[6e11352]187 <application>X</application>, so that some features such as the client-server
188 model or the x11-selection (clipboard) are still available.</para>
[9f12e36]189
[4967eaf6]190 <para><option>--without-x</option>: If you prefer not to link
191 <application>Vim</application> against <application>X</application>, use
192 this switch.</para>
[0ec75653]193
[95799899]194 <para><option>--enable-perlinterp</option>, <option>--enable-pythoninterp</option>,
[864b24de]195 <option>--enable-tclinterp</option>, <option>--enable-rubyinterp</option>:
[f8c734f]196 These options include the Perl, Python, Tcl, or Ruby interpreters that allow
[864b24de]197 using other application code in <application>vim</application> scripts.</para>
198
[95799899]199 </sect2>
200
201 <sect2 role="configuration">
202 <title>Configuring Vim</title>
203
204 <sect3 id='vim-config'>
205 <title>Config Files</title>
206
207 <para><filename>/etc/vimrc</filename> and
208 <filename>~/.vimrc</filename></para>
209
210 <indexterm zone="vim vim-config">
211 <primary sortas="e-etc-vimrc">/etc/vimrc</primary>
212 </indexterm>
213
214 <indexterm zone="vim vim-config">
215 <primary sortas="e-AA.vimrc">~/.vimrc</primary>
216 </indexterm>
217
218 </sect3>
219
220 <sect3 id='vim-init'>
221 <title>Configuration Information</title>
222
[6e11352]223 <para><application>Vim</application> has an integrated spell checker
224 which you can enable it if you issue the following in a vim window:
225 </para>
[864b24de]226
[6e11352]227<screen><literal>:setlocal spell spelllang=ru</literal></screen>
[fd7e0ed6]228
[6e11352]229 <para>This setting will enable spell checking for the Russian
230 language for the current session.</para>
[864b24de]231
[95799899]232 <para>By default, <application>Vim</application> only installs spell
[6e11352]233 files for the English language. If a spell file is not available for
234 a language, then <application>Vim</application> will call the
235 <filename>$VIMRUNTIME/plugin/spellfile.vim</filename> plugin and will try
236 to obtain the *.spl and optionally *.sug from the vim ftp server,
237 by using the <filename>$VIMRUNTIME/plugin/netrwPlugin.vim</filename>
238 plugin.</para>
[864b24de]239
[95799899]240 <para>Alternatively you can manually download the *.spl and *.sug files
241 from: <ulink url="ftp://ftp.vim.org/pub/vim/runtime/spell/"/> and save
242 them to <filename class="directory"> ~/.vim/spell </filename> or in
[6e11352]243 <filename class="directory">/usr/share/vim/vim71/spell/</filename>.</para>
[864b24de]244
[6e11352]245 <para>To find out what's new in <application>Vim-&vim-version;</application>
246 issue the following command:</para>
[95799899]247
[6e11352]248<screen><literal>:help version-&vim-version;</literal></screen>
[95799899]249
250 <para>For additional information on setting up
251 <application>Vim</application> configuration files, see <xref
252 linkend="postlfs-config-vimrc"/> and <ulink
[6e11352]253 url='http://www.vi-improved.org/vimrc.php'/>.</para>
[95799899]254
255 </sect3>
256
[0ec75653]257 </sect2>
258
259 <sect2 role="content">
260 <title>Contents</title>
261
[3aa07d1]262 <para>A list of the reinstalled files, along with their short
[95799899]263 descriptions can be found in the <ulink
[864b24de]264 url="&lfs-root;/chapter06/vim.html#contents-vim">LFS Vim Installation
[98078a6]265 Instructions</ulink></para>
[0ec75653]266
267 <segmentedlist>
268 <segtitle>Installed Programs</segtitle>
269 <segtitle>Installed Libraries</segtitle>
270 <segtitle>Installed Directory</segtitle>
271
272 <seglistitem>
273 <seg>gview, gvim, gvimdiff, rgview, and rgvim</seg>
274 <seg>None</seg>
275 <seg>/usr/share/vim</seg>
276 </seglistitem>
277 </segmentedlist>
278
279 <variablelist>
280 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
281 <?dbfo list-presentation="list"?>
282 <?dbhtml list-presentation="table"?>
283
284 <varlistentry id="gview">
285 <term><command>gview</command></term>
286 <listitem>
287 <para>starts <command>gvim</command> in read-only mode.</para>
288 <indexterm zone="vim gview">
289 <primary sortas="b-gview">gview</primary>
290 </indexterm>
291 </listitem>
292 </varlistentry>
293
294 <varlistentry id="gvim">
295 <term><command>gvim</command></term>
296 <listitem>
[d612b9f]297 <para>is the editor that runs under <application>X</application>
[13679edb]298 and includes a GUI.</para>
[0ec75653]299 <indexterm zone="vim gvim">
300 <primary sortas="b-gvim">gvim</primary>
301 </indexterm>
302 </listitem>
303 </varlistentry>
304
305 <varlistentry id="gvimdiff">
306 <term><command>gvimdiff</command></term>
307 <listitem>
308 <para>edits two or three versions of a file with
[13679edb]309 <command>gvim</command> and shows the differences.</para>
[0ec75653]310 <indexterm zone="vim gvimdiff">
311 <primary sortas="b-gvimdiff">gvimdiff</primary>
312 </indexterm>
313 </listitem>
314 </varlistentry>
315
316 <varlistentry id="rgview">
317 <term><command>rgview</command></term>
318 <listitem>
319 <para>is a restricted version of <command>gview</command>.</para>
320 <indexterm zone="vim rgview">
321 <primary sortas="b-rgview">rgview</primary>
322 </indexterm>
323 </listitem>
324 </varlistentry>
325
326 <varlistentry id="rgvim">
327 <term><command>rgvim</command></term>
328 <listitem>
329 <para>is a restricted version of <command>gvim</command>. </para>
330 <indexterm zone="vim gvim">
331 <primary sortas="b-gvim">gvim</primary>
332 </indexterm>
333 </listitem>
334 </varlistentry>
335
336 </variablelist>
337
338 </sect2>
[f45b1953]339
340</sect1>
Note: See TracBrowser for help on using the repository browser.