vim.xml 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
  3. <!ENTITY % general-entities SYSTEM "../general.ent">
  4. %general-entities;
  5. ]>
  6. <sect1 id="ch-system-vim" xreflabel="Vim" role="wrap">
  7. <title>Vim-&vim-version;</title>
  8. <?dbhtml filename="vim.html"?>
  9. <indexterm zone="ch-system-vim"><primary sortas="a-Vim">Vim</primary></indexterm>
  10. <sect2 role="package"><title/>
  11. <segmentedlist>
  12. <segtitle>&buildtime;</segtitle>
  13. <segtitle>&diskspace;</segtitle>
  14. <seglistitem><seg>0.4 SBU</seg><seg>34 MB</seg></seglistitem>
  15. </segmentedlist>
  16. </sect2>
  17. <sect2 role="installation">
  18. <title>Installation of Vim</title>
  19. <para>Change the default locations of the configuration files:</para>
  20. <screen><userinput>echo '#define SYS_VIMRC_FILE "/etc/vimrc"' &gt;&gt; src/feature.h
  21. echo '#define SYS_GVIMRC_FILE "/etc/gvimrc"' &gt;&gt; src/feature.h</userinput></screen>
  22. <para>Now prepare Vim for compilation:</para>
  23. <screen><userinput>./configure --prefix=/usr --enable-multibyte</userinput></screen>
  24. <para>Compile the package:</para>
  25. <screen><userinput>make</userinput></screen>
  26. <para>To test the results, issue:
  27. <userinput>make test</userinput></para>
  28. <para>Now install the package:</para>
  29. <screen><userinput>make install</userinput></screen>
  30. <para>Create a symlink:</para>
  31. <screen><userinput>ln -s vim /usr/bin/vi</userinput></screen>
  32. </sect2>
  33. <sect2 id="conf-vim" role="configuration"><title>Configuring Vim</title>
  34. <para>Create a default vim configuration file by running
  35. the following:</para>
  36. <screen><userinput>cat &gt; /etc/vimrc &lt;&lt; "EOF"
  37. " Begin /etc/vimrc
  38. set nocompatible
  39. set backspace=2
  40. syntax on
  41. <!-- set fileencodings=ucs-bom,utf-8,<replaceable>[your-8-bit-charset]</replaceable> -->
  42. if (&amp;term == "iterm") || (&amp;term == "putty")
  43. set background=dark
  44. endif
  45. " End /etc/vimrc
  46. EOF</userinput></screen>
  47. <!-- XXX: the ascii-only files are considered to be in utf-8 - that's not what
  48. one expects . That's why fileencodings stuff is commented out for now
  49. The <parameter>set fileencodings=...</parameter> makes
  50. <command>vim</command> capable of automatically detecting the character
  51. set of the file being edited (replace
  52. "<replaceable>[your-8-bit-charset]</replaceable>"
  53. with the value appropriate for your country, e.g. iso-8859-15 in Italy).
  54. This line is useful because bleeding-edge distributions
  55. like Fedora Core use UTF-8, and conservative ones like Debian
  56. use traditional 8-bit encodings for text files. If you have not
  57. passed the <parameter>- -enable-multibyte</parameter> switch to the
  58. <command>./configure</command> command above, this line will not work. -->
  59. <para>Documentation for other available options can be obtained by running
  60. the following command:</para>
  61. <screen><userinput>vim -c ':options'</userinput></screen>
  62. </sect2>
  63. <sect2 id="contents-vim" role="content"><title>Contents of Vim</title>
  64. <para>See testing</para>
  65. </sect2>
  66. </sect1>