1.. _rfc-71: 2 3=========================== 4RFC 71: Migration to GitHub 5=========================== 6 7======== ========================== 8Author: Even Rouault 9Contact: even.rouault@spatialys.com 10Started: March 2018 11Status: Adopted, implemented 12======== ========================== 13 14Summary 15------- 16 17It is proposed that the GDAL source tree and ticket database moves from 18the OSGeo hosted Subversion repository/Trac database to GitHub. Full 19source code history will be preserved. To make the migration simpler, 20existing tickets will remain in OSGeo Trac and will not be migrated to 21GitHub. New tickets will have to be opened in GitHub. 22 23Motivations 24----------- 25 261. It is considered that most developers interested by GDAL development 27 are nowadays more used to git than Subversion, and the use of 28 Subversion as the main source control management makes contributions 29 less attractive. 302. The `https://github.com/OSGeo/gdal <https://github.com/OSGeo/gdal>`__ 31 mirror has existed since 2012 and has over time become the preferred 32 way for contributors without direct SVN access (or even those with 33 SVN access) to submit their contributions, in particular because of 34 the coupling with the continuous integratations services of Travis-CI 35 and !AppVeyor that enable maintainers to check that the contribution 36 doesn't introduce known regressions + the friendly way of commenting 37 a pull request. However the manual porting of !GitHub pull requests 38 to Trac is a bit painful for GDAL maintainers. 393. GitHub has become the de-facto hosting platform for a lot of 40 open-source projects. 41 42Details of the migration 43------------------------ 44 450. The existing GitHub git repository will be pushed to 46 `https://github.com/OSGeo/gdal_svn_mirror_backup <https://github.com/OSGeo/gdal_svn_mirror_backup>`__ 47 (eventually removed once we are confident further steps have not 48 messed things up) 491. As GitHub also uses the syntax "#1234" to link commit messages to its 50 issues that was also used in Trac, currently when following links in 51 !GitHub that point to a Trac ticket, one ends up to a non-existing or 52 unrelated !GitHub issue/pull request. So the commit messages of the 53 current !GitHub mirror will be rewritten by a "git filter-branch 54 --msg-filter 'python rewrite.py' -- --all" command to replace "#1234" 55 with 56 "`https://trac.osgeo.org/gdal/ticket/1234 <https://trac.osgeo.org/gdal/ticket/1234>`__" 572. The git 'trunk' branch will be renamed 'master' to follow git best 58 practices 593. The existing 'tag/x.y.z' branches will be replaced by proper git 60 tags. 614. This modified repository will be forced push to 62 `https://github.com/OSGeo/gdal <https://github.com/OSGeo/gdal>`__ 63 This will have the consequence of invalidating existing pull request 64 or forks of repository that will have to be rebased to the new one. 65 From that point, "svn commit" should be avoided and changes should go 66 to the git repository. 675. The cron job on the OSGeo server that refreshes the website from 68 sources will be modified to pull from !GitHub rather than SVN. 696. Ticket creation permissions will be removed in Trac. Modification or 70 closing of existing open tickets will still be possible. From that 71 point, if closing a Trac ticket, one will have manually to reference 72 the github commit. 737. The settings of the GDAL GitHub repository will be changed allow 74 tickets to be filed. Labels and Milestones will be populated with 75 relevant content 76 77Further actions required, in no particular order, and for which help 78from other GDAL developers/contributors would be welcome: 79 80- Most visible Trac wiki documentation will have to be revised to point 81 to GitHub 82- HOWTO-RELEASE will have to be revised. 83- Existing SVN committers still interested in the project will have to 84 request commit access to the GitHub repo. 85- Some support from OSGeo SAC will be needed to turn the GDAL SVN 86 repository to read-only (a complementary option would be to rename it 87 to gdal_historical so that people pulling from the old one are well 88 aware of the migration by having their scripts 'cleanly' error out) 89- Some guidelines on how we intend to use git/GitHub features will have 90 to be rewritten. 91 92Exit strategy 93------------- 94 95GitHub is a closed platform. In case it would close or would start askin 96to pay unreasonable fees, some backup strategy of the tickets would be 97needed. The solutions might be: 98 99- `https://github.com/josegonzalez/python-github-backup <https://github.com/josegonzalez/python-github-backup>`__ 100- GitLab has an import module from GitHub. Although some 101 experimentation has been done with those, this RFC does *not* cover 102 setting up those solutions as a regular backup system. 103 104Not covered by this RFC 105----------------------- 106 107- Migration of Trac wiki content to GitHub wiki is not in the scope of 108 this RFC. Can be done later 109 110Previous related discussions 111---------------------------- 112 113- `https://lists.osgeo.org/pipermail/gdal-dev/2018-March/048240.html <https://lists.osgeo.org/pipermail/gdal-dev/2018-March/048240.html>`__ 114- `https://lists.osgeo.org/pipermail/gdal-dev/2017-September/047060.html <https://lists.osgeo.org/pipermail/gdal-dev/2017-September/047060.html>`__ 115 116Voting history 117-------------- 118 119+1 from HowardB, JukkaR, KurtS and EvenR 120