Changes between Version 26 and Version 27 of DeveloperGuidelines/Git


Ignore:
Timestamp:
02/01/12 17:39:22 (13 years ago)
Author:
Fran Boon
Comment:

Move around to be easier for new devs in the common scenrio, now that we're past-Production

Legend:

Unmodified
Added
Removed
Modified
  • DeveloperGuidelines/Git

    v26 v27  
    11= Git =
    22[[TOC]]
    3 Sahana Eden has decided to move from !Bzr/LaunchPad to !Git/GitHub
    4 == Why? ==
    5 * The current repository is huge & bloated, taking too long to download.
    6 * Even simple changes take an age to Pull down to servers
    7 * Web2py no longer supports !Bzr/LaunchPad, so we want to be able to maintain a common tool to work with both repositories.
    8 * New developers are likely to be more familiar with !Git/GitHub
    9 == How? ==
    10 The preferred approach is to have a clean repository, in order to get the maximum benefit from the migration...although it is technically possible to [http://fearthecowboy.com/2011/04/29/converting-bazaar-repositories-to-git/ migrate the commit history]. Commit History will instead be maintained on the !LaunchPad site as an archive
    113=== Fork a fresh Branch ===
    124* Sign-up for an account on [https://github.com GitHub]
     
    2113}}}
    2214
    23 === Migrating existing Branches ===
    24 Merge branch with trunk using normal Bzr tools
    25 
    26 Assuming that you have already [https://github.com/flavour/eden/fork_select forked Eden Trunk], then you will need to create a new repository manually for additional branches, as you cannot [http://bitdrift.com/post/4534738938/fork-your-own-project-on-github fork your own project on GitHub]:
    27 * https://github.com/repositories/new
    28 {{{
    29 cd web2py/applications
    30 git clone git@github.com:flavour/eden.git <mybranch>2
    31 }}}
    32 * Move {{{.git}}} & {{{.gitignore}}} from <mybranch>2 to <mybranch>
    33 * Delete the rest of <mybranch>2
    34 * Edit {{{.git/config}}}:
    35 {{{
    36 [remote "origin"]
    37     fetch = +refs/heads/*:refs/remotes/origin/*
    38     url = git@github.com:<mygitusername>/<mybranch>.git
    39 }}}
    40 * Create the initial repo for this new branch
    41 {{{
    42 cd <mybranch>
    43 git add .
    44 git commit -am "Initial Git version of My branch"
    45 git push -u origin master
    46 git remote add upstream git://github.com/flavour/eden.git
    47 }}}
    4815=== Developer Workflow ===
    4916We suggest adopting the [http://blog.hasmanythrough.com/2008/12/18/agile-git-and-the-story-branch-pattern Story Branch] pattern, which allows squashing commits in order to keep the main Trunk as clean as possible
     
    163130* Community Book: http://book.git-scm.com
    164131* Tips & Tricks: http://gitready.com
     132
     133== Why? ==
     134Sahana Eden has decided to move from !Bzr/LaunchPad to !Git/GitHub
     135* The current repository is huge & bloated, taking too long to download.
     136* Even simple changes take an age to Pull down to servers
     137* Web2py no longer supports !Bzr/LaunchPad, so we want to be able to maintain a common tool to work with both repositories.
     138* New developers are likely to be more familiar with !Git/GitHub
     139== How? ==
     140The preferred approach is to have a clean repository, in order to get the maximum benefit from the migration...although it is technically possible to [http://fearthecowboy.com/2011/04/29/converting-bazaar-repositories-to-git/ migrate the commit history]. Commit History will instead be maintained on the !LaunchPad site as an archive
     141
     142=== Migrating existing Branches ===
     143Merge branch with trunk using normal Bzr tools
     144
     145Assuming that you have already [https://github.com/flavour/eden/fork_select forked Eden Trunk], then you will need to create a new repository manually for additional branches, as you cannot [http://bitdrift.com/post/4534738938/fork-your-own-project-on-github fork your own project on GitHub]:
     146* https://github.com/repositories/new
     147{{{
     148cd web2py/applications
     149git clone git@github.com:flavour/eden.git <mybranch>2
     150}}}
     151* Move {{{.git}}} & {{{.gitignore}}} from <mybranch>2 to <mybranch>
     152* Delete the rest of <mybranch>2
     153* Edit {{{.git/config}}}:
     154{{{
     155[remote "origin"]
     156    fetch = +refs/heads/*:refs/remotes/origin/*
     157    url = git@github.com:<mygitusername>/<mybranch>.git
     158}}}
     159* Create the initial repo for this new branch
     160{{{
     161cd <mybranch>
     162git add .
     163git commit -am "Initial Git version of My branch"
     164git push -u origin master
     165git remote add upstream git://github.com/flavour/eden.git
     166}}}