Edgewall Software

Changes between Version 10 and Version 11 of TracTeam/Repositories


Ignore:
Timestamp:
Apr 7, 2015, 5:14:29 PM (5 years ago)
Author:
Ryan J Ollos
Comment:

Added syntax highlighting.

Legend:

Unmodified
Added
Removed
Modified
  • TracTeam/Repositories

    v10 v11  
    2828
    2929First you need to clone your repository (let's call the local repository `$user` as well):
    30 {{{
     30{{{#!sh
    3131$ git clone http://svn.edgewall.org/git/trac/devs/$user $user
    3232$ cd $user
     
    3434
    3535After the clone, you'll see the following branches:
    36 {{{
     36{{{#!sh
    3737$ git branch --all
    3838* trunk
     
    4444
    4545Speaking of which, we need to make it easy to retrieve the changes coming from upstream. For that, we add a remote that we will call `mirror`:
    46 {{{
     46{{{#!sh
    4747$ git remote add mirror http://svn.edgewall.org/git/trac/mirror
    4848$ git fetch mirror
     
    5151
    5252If you'd like to get tags from the mirror, do like this:
    53 {{{
     53{{{#!sh
    5454$ git fetch mirror 'refs/remotes/tags/*:refs/tags/*'
    5555}}}
    5656
    5757We also would like to fetch from this remote instead of the origin for the local  branch `trunk`, so we need to replace `origin` by `mirror`:
    58 {{{
     58{{{#!sh
    5959$ git branch --set-upstream-to=mirror/trunk trunk
    6060Branch trunk set up to track remote branch trunk from mirror.
     
    6262
    6363If you'd like to get a `0.12-stable` branch for tracking `mirror/0.12-stable`, simply do:
    64 {{{
     64{{{#!sh
    6565$ git branch 0.12-stable mirror/0.12-stable
    6666Branch 0.12-stable set up to track remote branch 0.12-stable from mirror.
     
    6868
    6969Once this is done, for either of these, getting the changes from svn is a simple matter of going back to the branch in question and doing a pull, e.g.
    70 {{{
     70{{{#!sh
    7171$ git checkout trunk
    7272$ git pull --ff-only
     
    7676
    7777For example:
    78 {{{
     78{{{#!sh
    7979$ git checkout -b ticketXYZ/short-summary trunk
    8080}}}
    8181
    8282Whenever you want to publish such a topic branch, you push it to your repository. The push URL must use `https`, so be sure to do this once:
    83 {{{
     83{{{#!sh
    8484$ git remote set-url origin --push https://$user@svn.edgewall.org/git/trac/devs/$user
    8585}}}
     
    8787
    8888Note that you can add the repositories from other developers in as  many remotes as needed, e.g.
    89 {{{
     89{{{#!sh
    9090$ git remote add cboos http://svn.edgewall.org/git/trac/devs/cboos
    9191$ git remote add jomae http://svn.edgewall.org/git/trac/devs/jomae