source: postlfs/editors/vim.xml@ 19023c19

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 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 19023c19 was f22f1ef3, checked in by Igor Živković <igor@…>, 10 years ago

applied Denis Mugnier's patch updating some incorrect URLs.

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

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