source: general/prog/git.xml@ bdfa4ab

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since bdfa4ab was bdfa4ab, checked in by Fernando de Oliveira <fernando@…>, 9 years ago

Update to git-2.4.1.

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

  • Property mode set to 100644
File size: 14.3 KB
RevLine 
[800f6b1]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
[a79f8e7]7 <!ENTITY git-root "https://www.kernel.org/pub/software/scm/git" >
8
[dba6b4e0]9 <!ENTITY git-download-http "&git-root;/git-&git-version;.tar.xz">
[0b42b27]10 <!ENTITY git-download-ftp "ftp://ftp.kernel.org/pub/software/scm/git/git-&git-version;.tar.xz">
[bdfa4ab]11 <!ENTITY git-md5sum "aed4a96723f600dfc879a2eb58e6e673">
[73d0a12]12 <!ENTITY git-size "3.6 MB">
13 <!ENTITY git-buildsize "326 MB (additional 14 MB for the downloaded docs)">
[bdfa4ab]14 <!ENTITY git-time "0.6 SBU (additional 4.1 SBU for tests, with -j8)">
[800f6b1]15]>
16
17<sect1 id="git" xreflabel="git-&git-version;">
18 <?dbhtml filename="git.html"?>
19
20 <sect1info>
21 <othername>$LastChangedBy$</othername>
22 <date>$Date$</date>
23 </sect1info>
24
25 <title>Git-&git-version;</title>
26
27 <indexterm zone="git">
[32696a4]28 <primary sortas="a-Git">Git</primary>
[800f6b1]29 </indexterm>
30
31 <sect2 role="package">
32 <title>Introduction to Git</title>
33
[32696a4]34 <para>
[9276b6ee]35
[32696a4]36 <application>Git</application> is a free and open source, distributed
37 version control system designed to handle everything from small to very
38 large projects with speed and efficiency. Every
39 <application>Git</application> clone is a full-fledged repository with
[bdf19997]40 complete history and full revision tracking capabilities, not dependent
41 on network access or a central server. Branching and merging are fast and
42 easy to do. <application>Git</application> is used for version control of
[9276b6ee]43 files, much like tools such as <xref linkend="mercurial"/>,
[32696a4]44 <application>Bazaar</application>, <xref linkend="subversion"/>,
45 <xref linkend="cvs"/>, <application>Perforce</application>, and
46 <application>Team Foundation Server</application>.
[9276b6ee]47
[32696a4]48 </para>
[800f6b1]49
[8f79d9f5]50 &lfs77_checked; &gcc5_checked;
[800f6b1]51
52 <bridgehead renderas="sect3">Package Information</bridgehead>
53 <itemizedlist spacing="compact">
54 <listitem>
[32696a4]55 <para>
56 Download (HTTP): <ulink url="&git-download-http;"/>
57 </para>
[800f6b1]58 </listitem>
59 <listitem>
[32696a4]60 <para>
61 Download (FTP): <ulink url="&git-download-ftp;"/>
62 </para>
[800f6b1]63 </listitem>
64 <listitem>
[32696a4]65 <para>
66 Download MD5 sum: &git-md5sum;
67 </para>
[800f6b1]68 </listitem>
69 <listitem>
[32696a4]70 <para>
71 Download size: &git-size;
72 </para>
[800f6b1]73 </listitem>
74 <listitem>
[32696a4]75 <para>
76 Estimated disk space required: &git-buildsize;
77 </para>
[800f6b1]78 </listitem>
79 <listitem>
[32696a4]80 <para>
81 Estimated build time: &git-time;
82 </para>
[800f6b1]83 </listitem>
84 </itemizedlist>
85
[435934c]86 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
87 <itemizedlist spacing="compact">
88 <listitem>
[32696a4]89 <para>
[a79f8e7]90 <ulink url="&git-root;/git-manpages-&git-version;.tar.xz">
[7053ca8]91 &git-root;/git-manpages-&git-version;.tar.xz</ulink>
[aaed964]92 (if you prefer the original, not needed if you've installed asciidoc
93 and xmlto and prefer to build them).
[32696a4]94 </para>
[435934c]95 </listitem>
96 <listitem>
[32696a4]97 <para>
[a79f8e7]98 <ulink url="&git-root;/git-htmldocs-&git-version;.tar.xz">
[7053ca8]99 &git-root;/git-htmldocs-&git-version;.tar.xz</ulink>
[aaed964]100 and other docs (if you prefer the original, not needed if you've
101 installed asciidoc and prefer to build them).
[32696a4]102 </para>
[435934c]103 </listitem>
104 </itemizedlist>
105
[800f6b1]106 <bridgehead renderas="sect3">Git Dependencies</bridgehead>
107
108 <bridgehead renderas="sect4">Recommended</bridgehead>
[1b2d41b]109 <para role="recommended">
[0d7900a]110 <xref linkend="curl"/> (needed to use <application>Git</application> over http,
[32696a4]111 https, ftp or ftps),
[56605b9]112 <xref linkend="openssl"/>, and
[32696a4]113 <xref linkend="python2"/>
[1b2d41b]114 </para>
[800f6b1]115
116 <bridgehead renderas="sect4">Optional</bridgehead>
[1b2d41b]117 <para role="optional">
[05ce77a]118 <xref linkend="pcre"/>,
119 <xref linkend="subversion"/> with Perl bindings (for <command>git svn</command>), and
[1b2d41b]120 <xref linkend="tk"/> (gitk, a simple <application>Git</application>
121 repository viewer, uses <application>Tk</application> at runtime)
122 </para>
123
124 <bridgehead renderas="sect4">Optional (to create the man pages and html docs)</bridgehead>
125 <para>
[fad8db2]126 <xref linkend="xmlto"/> and
[522641a]127 <ulink url="http://www.methods.co.nz/asciidoc/">AsciiDoc</ulink> or
128 <ulink url="http://asciidoctor.org/">AsciiDoctor</ulink>
[1b2d41b]129 </para>
[800f6b1]130
131 <para condition="html" role="usernotes">User Notes:
[32696a4]132 <ulink url="&blfs-wiki;/git"/>
133 </para>
[800f6b1]134 </sect2>
135
136 <sect2 role="installation">
137 <title>Installation of Git</title>
138
[32696a4]139 <para>
140 Install <application>Git</application> by running the following
141 commands:
142 </para>
[800f6b1]143
[bdf19997]144<screen><userinput>./configure --prefix=/usr --with-gitconfig=/etc/gitconfig &amp;&amp;
[800f6b1]145make</userinput></screen>
146
[6e08e9c0]147 <para>
148 You can build the man pages and/or html docs, or
149 use downloaded ones. If you choose to build them, use next two following
150 instructions.
151 </para>
152
[32696a4]153 <para>
154 If you have installed <ulink
155 url="http://www.methods.co.nz/asciidoc/">AsciiDoc</ulink> you can
156 create the html version of the man pages and other docs:
157 </para>
[800f6b1]158
[65fe9d8]159<screen><userinput>make html</userinput></screen>
[800f6b1]160
[32696a4]161 <para>
162 If you have installed <ulink
163 url="http://www.methods.co.nz/asciidoc/">AsciiDoc</ulink> and
164 <xref linkend="xmlto"/> you can create the man pages:
165 </para>
[435934c]166
[65fe9d8]167<screen><userinput>make man</userinput></screen>
[435934c]168
[32696a4]169 <para>
[bdf19997]170 The test suite can be run in parallel mode. To run the test suite, issue:
171 <command>make test</command>.
[32696a4]172 </para>
[800f6b1]173
[32696a4]174 <para>
175 Now, as the <systemitem class="username">root</systemitem>
176 user:
177 </para>
[800f6b1]178
179<screen role="root"><userinput>make install</userinput></screen>
180
[6e08e9c0]181<!-- ==== Method 1 for docs ====== -->
182 <bridgehead renderas="sect3">If you created the man pages and/or html docs</bridgehead>
183
[32696a4]184 <para>
[6e08e9c0]185 Install the man pages as
[32696a4]186 <systemitem class="username">root</systemitem> user:
187 </para>
[800f6b1]188
189<screen role="root"><userinput>make install-man</userinput></screen>
[435934c]190
[32696a4]191 <para>
[6e08e9c0]192 Install the html docs as
[32696a4]193 <systemitem class="username">root</systemitem> user:
194 </para>
[435934c]195
[6e08e9c0]196<screen role="root"><userinput>make htmldir=/usr/share/doc/git-&git-version; install-html</userinput></screen>
197
198<!-- ==== Method 2 for docs ====== -->
199 <bridgehead renderas="sect3">If you downloaded the man pages and/or html docs</bridgehead>
[435934c]200
[32696a4]201 <para>
[6e08e9c0]202 If you downloaded the man pages untar them as the
[32696a4]203 <systemitem class="username">root</systemitem> user:
204 </para>
[435934c]205
[64419b7]206<screen role="root"><userinput>tar -xf ../git-manpages-&git-version;.tar.xz \
207 -C /usr/share/man --no-same-owner --no-overwrite-dir</userinput></screen>
[435934c]208
[32696a4]209 <para>
210 If you downloaded the html docs untar them as the
211 <systemitem class="username">root</systemitem> user:
212 </para>
[435934c]213
[78a00a4e]214<screen role="root"><userinput>mkdir -vp /usr/share/doc/git-&git-version; &amp;&amp;
215tar -xf ../git-htmldocs-&git-version;.tar.xz \
216 -C /usr/share/doc/git-&git-version; --no-same-owner --no-overwrite-dir &amp;&amp;
[0524804]217
[78a00a4e]218find /usr/share/doc/git-&git-version; -type d -exec chmod 755 {} \; &amp;&amp;
219find /usr/share/doc/git-&git-version; -type f -exec chmod 644 {} \;</userinput></screen>
[c4ab33b5]220
[6e08e9c0]221<!-- ==== Reorganize docs ====== -->
222 <bridgehead renderas="sect3">Reorganize man pages and/or html docs (both methods)</bridgehead>
223
224 <para>
225 For both methods, reorganize the files, as
226 <systemitem class="username">root</systemitem> user:
227 </para>
228
[78a00a4e]229<screen role="root"><userinput>mkdir -vp /usr/share/doc/git-&git-version;/man-pages/{html,text} &amp;&amp;
230mv /usr/share/doc/git-&git-version;/{git*.txt,man-pages/text} &amp;&amp;
231mv /usr/share/doc/git-&git-version;/{git*.,index.,man-pages/}html &amp;&amp;
[64419b7]232
[78a00a4e]233mkdir -vp /usr/share/doc/git-&git-version;/technical/{html,text} &amp;&amp;
234mv /usr/share/doc/git-&git-version;/technical/{*.txt,text} &amp;&amp;
235mv /usr/share/doc/git-&git-version;/technical/{*.,}html &amp;&amp;
236
237mkdir -vp /usr/share/doc/git-&git-version;/howto/{html,text} &amp;&amp;
238mv /usr/share/doc/git-&git-version;/howto/{*.txt,text} &amp;&amp;
239mv /usr/share/doc/git-&git-version;/howto/{*.,}html</userinput></screen>
[32696a4]240
[800f6b1]241 </sect2>
242
243 <sect2 role="commands">
244 <title>Command Explanations</title>
245
[5e5a8d5]246 <para>
[35943a41]247 <parameter>--with-gitconfig=/etc/gitconfig</parameter>: This sets
[5e5a8d5]248 <filename>/etc/gitconfig</filename> as the file that stores
249 the default, system wide, <application>Git</application>
250 settings.
251 </para>
252
[32696a4]253 <para>
254 <option>--without-python</option>: Use this switch if
255 <application>Python</application> is not installed.
256 </para>
[435934c]257
[32696a4]258 <para>
259 <option>--with-libpcre</option>: Use this switch if
260 <application>PCRE</application> is installed.
261 </para>
[0524804]262
[32696a4]263 <para>
264 <command>tar -xf ../git-manpages-&git-version;.tar.gz -C
265 /usr/share/man --no-same-owner</command>: This untars
266 <filename>git-manpages-&git-version;.tar.gz</filename>. The
267 <option>-C</option> option makes tar change directory to
268 <filename class="directory">/usr/share/man</filename> before
269 it starts to decompress the docs. The <option>--no-same-owner</option>
270 option stops tar from preserving the user and group details of the
271 files. This is useful as that user or group may not exist on your
272 system; this could (potentially) be a security risk.
273 </para>
[0524804]274
[32696a4]275 <para>
276 <command>mv /usr/share/doc/git-&git-version; ...</command>: These
277 commands move some of the files into subfolders to make it easier to sort
278 through the docs and find what you're looking for.
279 </para>
[435934c]280
[c4ab33b5]281 <para>
282 <command>find ... chmod ...</command>: These commands correct the
283 permissions in the shipped documentation tar file.
284 </para>
285
[800f6b1]286 </sect2>
287
288 <sect2 role="configuration">
289 <title>Configuring Git</title>
290
291 <sect3 id="git-config">
292 <title>Config Files</title>
[32696a4]293 <para>
294 <filename>~/.gitconfig</filename> and
295 <filename>/etc/gitconfig</filename>
296 </para>
[800f6b1]297
298 <indexterm zone="git git-config">
299 <primary sortas="e-AA.gitconfig">~/.gitconfig</primary>
300 </indexterm>
301
302 <indexterm zone="git git-config">
303 <primary sortas="e-etc-gitconfig">/etc/gitconfig</primary>
304 </indexterm>
[32696a4]305
[800f6b1]306 </sect3>
307
308 </sect2>
309
310 <sect2 role="content">
311 <title>Contents</title>
312
313 <segmentedlist>
314 <segtitle>Installed Programs</segtitle>
[c3c56b2]315 <segtitle>Installed Libraries</segtitle>
[800f6b1]316 <segtitle>Installed Directories</segtitle>
317
318 <seglistitem>
[32696a4]319 <seg>
[a79f8e7]320 git, git-receive-pack and git-upload-archive (hardlinked to each other),
[e2268bbf]321 git-cvsserver, git-shell, git-upload-pack, and gitk
[32696a4]322 </seg>
323 <seg>
324 None
325 </seg>
326 <seg>
[8f79d9f5]327 /usr/lib/perl5/site_perl/&lt;5.x.y&gt;/{,&lt;arch-linux&gt;/auto/}Git,
[9276b6ee]328 /usr/libexec/git-core and
329 /usr/share/{git-core,git-gui,gitk,gitweb,doc/git-&git-version;}
[32696a4]330 </seg>
[800f6b1]331 </seglistitem>
332 </segmentedlist>
333
334 <variablelist>
335 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
336 <?dbfo list-presentation="list"?>
337 <?dbhtml list-presentation="table"?>
338
339 <varlistentry id="git-prog">
340 <term><command>git</command></term>
341 <listitem>
[32696a4]342 <para>
343 is the stupid content tracker.
344 </para>
[800f6b1]345 <indexterm zone="git git-prog">
346 <primary sortas="b-git">git</primary>
347 </indexterm>
348 </listitem>
349 </varlistentry>
350
351 <varlistentry id="git-cvsserver">
352 <term><command>git-cvsserver</command></term>
353 <listitem>
[32696a4]354 <para>
355 is a CVS server emulator for <application>Git</application>.
356 </para>
[800f6b1]357 <indexterm zone="git git-cvsserver">
358 <primary sortas="b-git-cvsserver">git-cvsserver</primary>
359 </indexterm>
360 </listitem>
361 </varlistentry>
362
363 <varlistentry id="gitk">
364 <term><command>gitk</command></term>
365 <listitem>
[32696a4]366 <para>
[a79f8e7]367 is a graphical <application>Git</application> repository browser
368 (needs <xref linkend="tk"/>).
[32696a4]369 </para>
[800f6b1]370 <indexterm zone="git gitk">
371 <primary sortas="b-gitk">gitk</primary>
372 </indexterm>
373 </listitem>
374 </varlistentry>
375
376 <varlistentry id="git-receive-pack">
377 <term><command>git-receive-pack</command></term>
378 <listitem>
[32696a4]379 <para>
380 is invoked by <command>git send-pack</command> and updates the
381 repository with the information fed from the remote end.
382 </para>
[800f6b1]383 <indexterm zone="git git-receive-pack">
384 <primary sortas="b-git-receive-pack">git-receive-pack</primary>
385 </indexterm>
386 </listitem>
387 </varlistentry>
388
389 <varlistentry id="git-shell">
390 <term><command>git-shell</command></term>
391 <listitem>
[32696a4]392 <para>
393 is a login shell for SSH accounts to provide restricted Git
394 access.
395 </para>
[800f6b1]396 <indexterm zone="git git-shell">
397 <primary sortas="b-git-shell">git-shell</primary>
398 </indexterm>
399 </listitem>
400 </varlistentry>
401
402 <varlistentry id="git-upload-archive">
403 <term><command>git-upload-archive</command></term>
404 <listitem>
[32696a4]405 <para>
406 is invoked by <command>git archive --remote</command> and sends
407 a generated archive to the other end over the git protocol.
408 </para>
[800f6b1]409 <indexterm zone="git git-upload-archive">
410 <primary sortas="b-git-upload-archive">git-upload-archive</primary>
411 </indexterm>
412 </listitem>
413 </varlistentry>
414
415 <varlistentry id="git-upload-pack">
416 <term><command>git-upload-pack</command></term>
417 <listitem>
[32696a4]418 <para>
419 is invoked by <command>git fetch-pack</command>, it discovers
420 what objects the other side is missing, and sends them after
421 packing.
422 </para>
[800f6b1]423 <indexterm zone="git git-upload-pack">
424 <primary sortas="b-git-upload-pack">git-upload-pack</primary>
425 </indexterm>
426 </listitem>
427 </varlistentry>
[32696a4]428
[800f6b1]429 </variablelist>
[32696a4]430
[800f6b1]431 </sect2>
[32696a4]432
[800f6b1]433</sect1>
Note: See TracBrowser for help on using the repository browser.