/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to doc/en/admin-guide/advanced.txt

  • Committer: Jelmer Vernooij
  • Date: 2020-08-22 22:46:24 UTC
  • mfrom: (7490.40.105 work)
  • mto: This revision was merged to the branch mainline in revision 7521.
  • Revision ID: jelmer@jelmer.uk-20200822224624-om4a4idsr7cn8jew
merge lp:brz/3.1.

Show diffs side-by-side

added added

removed removed

Lines of Context:
54
54
 
55
55
  $ cd /srv/bzr/projectx
56
56
  $ mv trunk trunk              # can simply rename on the filesystem
57
 
  $ bzr branch trunk texas-integration   # very fast in a shared repository
 
57
  $ brz branch trunk texas-integration   # very fast in a shared repository
58
58
 
59
59
In Australia, we need to set up the ``/srv/bzr/projectx`` directory and get a
60
60
copy of the current trunk as australia-integration::
61
61
 
62
62
  $ mkdir -p /srv/bzr
63
63
  $ cd /srv/bzr
64
 
  $ bzr init-shared-repo --no-trees projectx
 
64
  $ brz init-shared-repo --no-trees projectx
65
65
  $ cd projectx
66
 
  $ bzr branch bzr+ssh://server.example.com/srv/bzr/trunk
67
 
  $ bzr branch trunk australia-integration
 
66
  $ brz branch bzr+ssh://server.example.com/srv/bzr/trunk
 
67
  $ brz branch trunk australia-integration
68
68
 
69
69
Merging to master
70
70
~~~~~~~~~~~~~~~~~
79
79
  # Get a copy of the Australia branch in Texas.  After the initial branch
80
80
  # command, use pull to keep the branch up to date.  With a slow network,
81
81
  # this is the only slow part
82
 
  $ bzr branch bzr+ssh://autralia.example.com/srv/bzr/projectx/australia-integration \
 
82
  $ brz branch bzr+ssh://autralia.example.com/srv/bzr/projectx/australia-integration \
83
83
    bzr+ssh://server.example.com/srv/bzr/projectx/australia-integration
84
84
  
85
85
  # Check out the master branch locally for doing the merge
86
86
  $ cd ~/projectx
87
 
  $ bzr checkout bzr+ssh://server.example.com/srv/bzr/projectx/trunk
 
87
  $ brz checkout bzr+ssh://server.example.com/srv/bzr/projectx/trunk
88
88
  $ cd trunk
89
 
  $ bzr merge bzr+ssh://server.example.com/srv/bzr/projectx/texas-integration
 
89
  $ brz merge bzr+ssh://server.example.com/srv/bzr/projectx/texas-integration
90
90
  # Run the test suite and resolve any conflicts
91
 
  $ bzr commit -m "Merge Texas branch to master"
 
91
  $ brz commit -m "Merge Texas branch to master"
92
92
  
93
93
  # Now, merge from Australia using the local copy of that branch
94
 
  $ bzr merge bzr+ssh://server.example.com/srv/bzr/projectx/australia-integration
 
94
  $ brz merge bzr+ssh://server.example.com/srv/bzr/projectx/australia-integration
95
95
  # Run the test suite and resolve any conflicts between the two offices
96
 
  $ bzr commit -m "Merge Australia branch to master"
 
96
  $ brz commit -m "Merge Australia branch to master"
97
97
 
98
98
Note that Bazaar does not commit even cleanly applied merges by default.  This
99
99
is because although a merge may apply cleanly, the merged state still needs to
100
100
be checked before it is committed.  (Just because there are no text conflicts
101
101
does not mean that everything will work after a merge.)  An alternative that 
102
102
can pull when possible and merge otherwise is available with 
103
 
``bzr merge --pull``.
 
103
``brz merge --pull``.
104
104
 
105
105
Merging back to local trunks
106
106
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
108
108
Now the trunk branch is the most up-to-date version of the software and
109
109
both of the local trunks need to reincorporate the changes from the master.
110
110
If no new commits have been made to texas-integration, then that can happen using
111
 
``bzr pull``::
 
111
``brz pull``::
112
112
 
113
113
  $ cd ~/projectx
114
 
  $ bzr checkout bzr+ssh://server.example.com/srv/bzr/projectx/texas-integration
 
114
  $ brz checkout bzr+ssh://server.example.com/srv/bzr/projectx/texas-integration
115
115
  $ cd texas-integration
116
 
  $ bzr pull ../trunk  # Use trunk from the local disk
 
116
  $ brz pull ../trunk  # Use trunk from the local disk
117
117
                              # No need to commit
118
118
 
119
119
If new changes have happened on texas-integration since the integration with
120
120
trunk, then the above pull will produce an error suggesting to use
121
121
merge::
122
122
 
123
 
  $ bzr merge ../trunk
 
123
  $ brz merge ../trunk
124
124
  # Run test suite, resolve conflicts
125
 
  $ bzr commit -m "Merging Australian changes"
 
125
  $ brz commit -m "Merging Australian changes"
126
126
 
127
127
In Australia, they will need to update their local copy of trunk::
128
128
 
129
129
  $ cd /srv/bzr/projectx/trunk
130
 
  $ bzr pull     # parent location is used by default
 
130
  $ brz pull     # parent location is used by default
131
131
 
132
132
Then, they need to pull or merge the changes from trunk into the local trunk.
133
133
This should be done by a developer with a checkout of australia-integration so
134
134
that they can run the test suite::
135
135
 
136
136
  $ cd ~/projectx
137
 
  $ bzr co bzr+ssh://australia.example.com/srv/bzr/projectx/australia-integration
 
137
  $ brz co bzr+ssh://australia.example.com/srv/bzr/projectx/australia-integration
138
138
  $ cd australia-integration
139
 
  $ bzr merge bzr+ssh://australia.example.com/srv/bzr/projectx/trunk
 
139
  $ brz merge bzr+ssh://australia.example.com/srv/bzr/projectx/trunk
140
140
  # Run test suite and integrate Texan changes with only recent local
141
141
  # development
142
 
  $ bzr commit -m "Integrate work from Texas"
 
142
  $ brz commit -m "Integrate work from Texas"
143
143
 
144
144
 
145
145
Other Considerations