~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/help_topics/en/hooks.txt

Add pre_change_branch_tip hook. (Andrew Bennetts)

Show diffs side-by-side

added added

removed removed

Lines of Context:
105
105
branch, and an empty branch receives new_revno of 0, new_revid of None.
106
106
 
107
107
 
 
108
pre_change_branch_tip (Branch)
 
109
-------------------------------
 
110
 
 
111
Run before a branch tip has been changed, while the branch is write-locked.
 
112
Note that push, pull, commit and uncommit all invoke this hook.
 
113
 
 
114
The hook signature is (params), where params is an object containing
 
115
the members
 
116
 
 
117
  branch
 
118
    The branch whose tip has been changed.
 
119
 
 
120
  old_revno
 
121
    The revision number (eg 10) of the branch before the change.
 
122
 
 
123
  old_revid
 
124
    The revision id (eg joe@foo.com-1234234-aoeua34) before the change.
 
125
 
 
126
  new_revno
 
127
    The revision number (eg 12) of the branch after the change.
 
128
 
 
129
  new_revid
 
130
    The revision id (eg joe@foo.com-5676566-boa234a) after the change.
 
131
 
 
132
The old_revno and new_revno members are integers, as the head
 
133
revision never has a dotted revision number.
 
134
 
 
135
 
108
136
post_change_branch_tip (Branch)
109
137
-------------------------------
110
138
 
130
158
    The revision id (eg joe@foo.com-5676566-boa234a) after the change.
131
159
 
132
160
The old_revno and new_revno members are integers, as the head
133
 
revision is never has a dotted revision number.
 
161
revision never has a dotted revision number.
134
162
 
135
163
 
136
164
set_rh (Branch)