| 1 |
(This file was generated by makeinfo and splitinfo.gawk.) |
| 2 |
(Released under the old-style GNU documentation license; |
| 3 |
see sources or other output files for full text.) |
| 4 |
|
| 5 |
9 Continuous integration |
| 6 |
************************ |
| 7 |
|
| 8 |
The TeX Live sources are subjected to continuous integration testing on |
| 9 |
Travis-CI (<https://travis-ci.org/TeX-Live/texlive-source>) via a |
| 10 |
git-svn mirror of the sources that is pushed to Github |
| 11 |
(<https://github.com/TeX-Live/texlive-source>). The git-svn mirror is |
| 12 |
updated (currently) at 30 minute intervals, and only the last commit |
| 13 |
pushed is tested on Travis-CI. |
| 14 |
|
| 15 |
9.1 Transfer from Subversion to Github |
| 16 |
====================================== |
| 17 |
|
| 18 |
The git-svn program (<https://git-scm.com/docs/git-svn>) is used to |
| 19 |
check out the subtree 'Build/source' of the canonical Subversion |
| 20 |
repository. The author index file used is not maintained in either Git |
| 21 |
or Subversion but can be provided on request. |
| 22 |
|
| 23 |
The initial checkout was done by invoking |
| 24 |
git svn --authors-file usermap clone \ |
| 25 |
svn://[email protected]/texlive/trunk/Build/source |
| 26 |
|
| 27 |
where the 'usermap' file maps Subversion user names to name and emails |
| 28 |
of the authors. Anonymous checkout is also possible: |
| 29 |
git svn --authors-file usermap clone \ |
| 30 |
svn://tug.org/texlive/trunk/Build/source |
| 31 |
|
| 32 |
In the following, we will use _admin_ to refer to a user who has |
| 33 |
read/write access to the TeX Live subversion repository, and is also an |
| 34 |
administrator of the ''TeX-Live'' team at Github. The above initial |
| 35 |
checkout has been carried out by _admin_ on the server 'texlive.info'. |
| 36 |
|
| 37 |
On Github, a new git repository named 'texlive-source' was created by |
| 38 |
_admin_ within the 'TeX-Live' "organization" |
| 39 |
(<https://github.com/TeX-Live>). The remote was added to the checkout |
| 40 |
with 'git remote add origin [email protected]:TeX-Live/texlive-source.git'. |
| 41 |
|
| 42 |
To automate the update on Github, a new ssh key was generated and |
| 43 |
added to the 'texlive-source' repository on Github as deployment key. |
| 44 |
Thus, pushes using this key can only go to the 'texlive-source' |
| 45 |
repository and not anywhere else. |
| 46 |
|
| 47 |
The usage of 'git-svn' requires a strict discipline to keep a linear |
| 48 |
history in the master branch. Since we are aiming at a pure mirror |
| 49 |
facility on Github, we have decided to further restrict the 'master' |
| 50 |
branch of the 'texlive-source' repository on Github to changes by |
| 51 |
_admin_. |
| 52 |
|
| 53 |
This setup allows other developers to branch off 'master' and push |
| 54 |
their branches to the Github repository, but all updates need to come |
| 55 |
from the local 'master' (not the one on Github) to Subversion, back to |
| 56 |
'master' on 'texlive.info', and from there to Github. |
| 57 |
|
| 58 |
9.2 Automatic update of the Git mirror |
| 59 |
====================================== |
| 60 |
|
| 61 |
_admin_ has installed a cron job on 'texlive.info' running every 30 |
| 62 |
minute which essentially runs 'git svn rebase' and 'git push' in the |
| 63 |
'master' branch of the checkout. The first command fetches the changes |
| 64 |
from the Subversion repository and updates the 'master' branch with |
| 65 |
them, and the second pushes changes (if any) to Github. |
| 66 |
|
| 67 |
9.3 CI testing on Travis-CI |
| 68 |
=========================== |
| 69 |
|
| 70 |
The 'source' tree of TeX Live contains a top-level file '.travis.yml' |
| 71 |
which controls the automatic testing on Travis-CI. _admin_ has |
| 72 |
registered with Travis-CI and allowed access to the Github's 'TeX-Live' |
| 73 |
organization's 'texlive-source' repository. The default settings are to |
| 74 |
build the last commit of each push. No further action is necessary on |
| 75 |
Travis-CI. |
| 76 |
|
| 77 |
If changes have been pushed via the cron job above, Travis-CI will |
| 78 |
automatically checkout the last pushed commit and try building it. |
| 79 |
|
| 80 |
9.4 Releases on Github |
| 81 |
====================== |
| 82 |
|
| 83 |
Given a git checkout of 'texlive-source': |
| 84 |
|
| 85 |
git pull |
| 86 |
git tag build-svnNNNN |
| 87 |
git push --tags |
| 88 |
|
| 89 |
and the result will appear at |
| 90 |
<https://github.com/TeX-Live/texlive-source/releases>. Releases can |
| 91 |
also be made manually from that web page (see 'tl-update-bindir' for |
| 92 |
hints). |
| 93 |
|