Merge pull request #17 from mkomarinski/usinggit

Usinggit
This commit is contained in:
Serge Victor 2016-01-29 09:24:49 +07:00
commit c8737ef2fd
5 changed files with 110 additions and 18 deletions

View File

@ -69,9 +69,8 @@
<!-- Appendix D. Transformations: Making HTML out of XML -->
<!ENTITY transformations SYSTEM "transformations.xml">
<!-- Appendix E. CVS -->
<!ENTITY cvs SYSTEM "cvs.xml">
<!ENTITY cvs-why SYSTEM "cvs-why.xml">
<!-- Appendix E. git -->
<!ENTITY git SYSTEM "git.xml">
<!-- Appendix F. Converting Documents to DocBook XML -->
<!ENTITY x2docbook SYSTEM "x2docbook.xml">
@ -495,8 +494,8 @@
<!-- Appendix: Editors, Validation and System Setup -->
&tools;
<!-- Appendix: CVS -->
&cvs;
<!-- Appendix: git -->
&git;
<!-- Appendix: Converting to DocBook XML 4.x
-->

View File

@ -222,7 +222,8 @@
not require any additional work. Be prepared to make at least one round
of changes for both the technical and language reviews. Ideally this
exchange will happen in the LDP's <ulink
url="http://cvs.tldp.org">CVS</ulink> to better track each of the
url="https://github.com/tLDP/LDP">git</ulink> repository to better
track each of the
changes that are made, and keep track of the most current version of
your document.
</para>
@ -257,16 +258,11 @@
<para>
As part of the review process a Review Coordinator will add your
document to the CVS (including any associated image files) and
document to github (including any associated image files) and
notify the submit mailing list that your document is ready for
publication.
</para>
<para>
If you do not already have a CVS account, please apply for one
when your document is submitted for publication. You can apply
for an account contacting LDP CVS master Sergiusz <ulink url="mailto:ser@gnu.org" />
</para>
<!--
<para> Once your LDP document has been carefully reviewed, you

View File

@ -227,15 +227,14 @@ your final document.
</para>
</section>
<section id="cvs-brief">
<title>Concurrent Versions System (CVS)</title>
&cvs-why;
<section id="git-brief">
<title>git</title>
<para>
For more information on how to use CVS to maintain your LDP
documents, please read <xref linkend="cvs" />.
For more information on how to use git to maintain your LDP
documents, please read <xref linkend="git" />.
</para>
</section> <!-- cvs -->
</section> <!-- git -->
<section id="ag-spellcheck">
<title>Spell Check</title>

View File

@ -0,0 +1,91 @@
<!--
<!DOCTYPE book PUBLIC '-//OASIS//DTD DocBook XML V4.2//EN'>
-->
<appendix id="git">
<title>git revision control</title>
<section id="git-intro">
<title>Introduction to git</title>
<para>
You can browse the LDP github repository via the web at <ulink
url="https://github.com/tLDP/">https://github.com/tLDP/</ulink>.
</para>
<para>
Using git offers many advantages over other version control systems,
but between git and github there's a few features that make it well
suited for a distributed and diverse set of contributors:
</para>
<itemizedlist>
<listitem><para>Each user can have their own independent and up-to-date copy of the repository and modify it.</para></listitem>
<listitem><para>Submitters do not need to have write access to the main repository to submit updates</para></listitem>
<listitem><para>Using github relieves TLDP staff of managing account requests</para></listitem>
<listitem><para>Ability to import changelogs from other VCS, so you can track changes going back about 16 years or more</para></listitem>
</itemizedlist>
<para>These advantages come a bit a bit of a price in terms of increased complexity. There's a lot to git, but we'll cover enough here to manage documents in LDP.</para>
<para>You can get an account on github by going to their <ulink
url="https://github.com/">website</ulink> and signing up for a free
account. For ease of use, you may want to use SSH keys to
authenticate with github otherwise you will be asked to enter your
password with each update.
</para>
</section>
<section id="git-setup">
<title>Setting up git on your local Linux system</title>
<para>Many different systems run git, but this document will focus on doing as many functions from the Linux command line as possible</para>
<para>You will need to make sure that <command>git</command> is installed on your system. It isn't always installed by default so you may need to add it using your package manager such as <command>yum</command> or <command>apt-get</command></para>
</section>
<section id="git-first">
<title>First time git setup</title>
<para>The first time you start using github you'll need to run some
commands</para>
<itemizedlist>
<listitem> <para>Clone the entire repository (about 400 MB) with: <command>git clone https://github.com/tLDP/LDP</command>
</para> </listitem>
<listitem> <para>Go to the <ulink url="https://github.com/tLDP/LDP">LDP repository</ulink> on github and click on <option>Fork</option>. This will create your own copy of TLDP in your space that you can write to.</para></listitem>
<listitem> <para>Lastly, link your local repository with your repository on github with <command>git remote add upstream git@github.com/<replaceable>MyGithubID</replaceable>/LDP.git</command></para></listitem>
</itemizedlist>
</section>
<section id="git-updates">
<title>Submitting changes to TLDP</title>
<para>Each time you make changes to TLDP you'll need to go through this
process. It'll make sure that your changes are submitted for review and
if approved, automatically added into TLDP</para>
<itemizedlist>
<listitem><para>Create a new branch using <command>git checkout -b <replaceable>MyNewBranch</replaceable></command></para></listitem>
<listitem><para>Start making your changes, either editing files, or creating new ones. You can use <command>git diff</command> to see changes between what you have locally and what the last checked in repository is.</para></listitem>
<listitem><para>If you added new files, you will need to use <command>git add <replaceable>filename</replaceable></command> to indicate that there are new files for git to manage.</para></listitem>
<listitem><para>Now you commit the changes locally using <command>git commit</command>. This creates a new revision and drops you into an editor to add a comment for the changes you've made. You can include the <command>-m</command> option and a string to do this at the command line.</para></listitem>
<listitem><para>Now you need to push your changes into your forked repository on github with <command>git push -u upstream <replaceable>MyNewBranch</replaceable></command></para></listitem>
<listitem><para>From the github website, you will need to create a push request using your branch.</para></listitem>
</itemizedlist>
<para>Once the push request is accepted, you can remove the branch using <command>git branch -D <replaceable>MyNewBranch</replaceable></command></para>
</section>
<!--
<section id="git-resources">
<title>git resources</title>
<para>If you're completely new to git, there are a few web pages
you may want to look at which can help you out: </para>
<itemizedlist>
<listitem>
<para> <ulink
url="http://cvshome.org/docs/blandy.html">http://cvshome.org/docs/blandy.html</ulink>
</para>
</listitem>
<listitem>
<para> <ulink
url="http://www.loria.fr/~molli/cvs/doc/cvs_toc.html">http://www.loria.fr/~molli/cvs/doc/cvs_toc.html</ulink></para>
</listitem>
</itemizedlist>
</section>
-->
</appendix>

View File

@ -186,6 +186,13 @@
</glossdef>
</glossentry>
<glossentry>
<glossterm>git</glossterm>
<glossdef>
<para>Git is a widely-used source code management system for software development. It is a distributed revision control system with an emphasis on speed, data integrity, and support for distributed, non-linear workflows. (Source: <ulink url="https://en.wikipedia.org/wiki/Git_(software)">Wikipedia</ulink>)</para>
</glossdef>
</glossentry>
<glossentry>
<glossterm>GNU Free Documentation License
(<acronym>GFDL</acronym>)</glossterm>