Changes between Version 1 and Version 2 of GitCreateBundle


Ignore:
Timestamp:
Oct 15, 2013, 4:22:51 PM (11 years ago)
Author:
Piero Campalani
Comment:

fixes

Legend:

Unmodified
Added
Removed
Modified
  • GitCreateBundle

    v1 v2  
    55== Why git bundles ==
    66
    7 Currently, the repo is folded into different public branches, letting a contributor choose on which of these branch his new patch is meant to be applied (see [patchesRasdamanReleaseProcess#Branchingmodel here] for details].
     7Currently, the repo is folded into different public branches, letting a contributor choose on which of these branch his new patch is meant to be applied (see [RasdamanReleaseProcess#Branchingmodel here] for details).
    88
    99This wiki page is meant for developers who need to reflect a ''merge'' operations to the public repo: indeed a solution which provides both un-linearized history and submission to the [patchmanagaer patch manager] is to submit a ''bundle''.
     
    4343
    4444First of all, the status of the two branches to be merged '''must''' be the _exactly_ the same before starting to merge.
    45 In this case, we can imagine we want to merge `feature_X' into `master':
     45In this case, we can imagine we want to merge `feature_X` into `master`:
    4646
    4747{{{
     
    5656#!sh
    5757$ git fetch origin
    58 $ # already up-to-date? otherwise pull new changes on both branches
    59 $
     58$ # already up-to-date? otherwise pull new changes on both branches.
     59
    6060$ git branch
    6161  feature_X
     
    6565$ git merge feature_X --no-ff
    6666$ # In case of "Automatic merge failed; fix conflicts and then commit the result.", then see you later.
    67 $ # otherwise:
     67
     68$ # Check:
    6869$ git log --oneline -1 master
    69703f36d7f Merge branch 'feature_X' into master
     
    8081To publish this on the public repo you can create the bundle, but first (again) remember that:
    8182
    82   * local snapshot of two branches must ''exactly'' be synchronized with that of the public repo
    83   * consequently, the ''names'' of the merging branches must be the same (as developers tend to open branches for local development..)
     83  * local snapshot of two branches must ''exactly'' be synchronized with that of the public repo;
     84  * consequently, the ''names'' of the merging branches must be the same as well (developers tend to open new branches for local development...).
    8485
    85 If it is all fine, create the bundle:
     86If all is fine, create the bundle:
    8687
    8788   * Synopsis:
     
    152153$ cd ~/test_repo
    153154$ git init
     155
     156$ # push two branches to the test repo
    154157$ cd /home/rasdaman/rasdaman
    155 $ git remote add test_remote ~/test_repo/
    156 $ # push two branches to the test repo
     158$ git remote add test_remote ~/test_repo
    157159$ git push test_remote master
    158160$ git push test_remote feature_X
    159 $ # Now move to the test repo and apply the bundle (1-verify, 2-apply)
     161
     162$ # Now move to the test repo
    160163$ cd ~/test_repo
    161164$ git branch
    162165  feature_X
    163166* master
     167
    164168$ # check out on a branch you're not merging into:
    165169$ git checkout feature_x
     
    167171* feature_X
    168172  master
     173
     174# Apply the bundle: [verify &] apply
    169175$ git bundle verify /path/to/ticket:XYZ_MergingFeature_xOnMaster.bundle
    170176$ git fetch /path/to/ticket:XYZ_MergingFeature_xOnMaster.bundle master:master