Revision 441:cbce1fd3b1b7 lib/redmine/scm/adapters/mercurial/.svn/text-base
| lib/redmine/scm/adapters/mercurial/.svn/text-base/redminehelper.py.svn-base | ||
|---|---|---|
| 120 | 120 |
ui.write('</manifest>\n')
|
| 121 | 121 |
|
| 122 | 122 |
def rhannotate(ui, repo, *pats, **opts): |
| 123 |
rev = urllib.unquote_plus(opts.pop('rev', None))
|
|
| 124 |
opts['rev'] = rev |
|
| 123 | 125 |
return commands.annotate(ui, repo, *map(urllib.unquote_plus, pats), **opts) |
| 124 | 126 |
|
| 125 | 127 |
def rhcat(ui, repo, file1, *pats, **opts): |
| 128 |
rev = urllib.unquote_plus(opts.pop('rev', None))
|
|
| 129 |
opts['rev'] = rev |
|
| 126 | 130 |
return commands.cat(ui, repo, urllib.unquote_plus(file1), *map(urllib.unquote_plus, pats), **opts) |
| 127 | 131 |
|
| 128 | 132 |
def rhdiff(ui, repo, *pats, **opts): |
| ... | ... | |
| 134 | 138 |
opts['nodates'] = True |
| 135 | 139 |
return commands.diff(ui, repo, *map(urllib.unquote_plus, pats), **opts) |
| 136 | 140 |
|
| 141 |
def rhlog(ui, repo, *pats, **opts): |
|
| 142 |
rev = opts.pop('rev')
|
|
| 143 |
bra0 = opts.pop('branch')
|
|
| 144 |
from_rev = urllib.unquote_plus(opts.pop('from', None))
|
|
| 145 |
to_rev = urllib.unquote_plus(opts.pop('to' , None))
|
|
| 146 |
bra = urllib.unquote_plus(opts.pop('rhbranch', None))
|
|
| 147 |
from_rev = from_rev.replace('"', '\\"')
|
|
| 148 |
to_rev = to_rev.replace('"', '\\"')
|
|
| 149 |
opts['rev'] = ['"%s":"%s"' % (from_rev, to_rev)] |
|
| 150 |
opts['branch'] = [bra] |
|
| 151 |
return commands.log(ui, repo, *map(urllib.unquote_plus, pats), **opts) |
|
| 152 |
|
|
| 137 | 153 |
def rhmanifest(ui, repo, path='', **opts): |
| 138 | 154 |
"""output the sub-manifest of the specified directory""" |
| 139 | 155 |
ui.write('<?xml version="1.0"?>\n')
|
| ... | ... | |
| 176 | 192 |
[('r', 'rev', [], 'revision'),
|
| 177 | 193 |
('c', 'change', '', 'change made by revision')],
|
| 178 | 194 |
'hg rhdiff ([-c REV] | [-r REV] ...) [FILE]...'), |
| 195 |
'rhlog': (rhlog, |
|
| 196 |
[ |
|
| 197 |
('r', 'rev', [], 'show the specified revision'),
|
|
| 198 |
('b', 'branch', [],
|
|
| 199 |
'show changesets within the given named branch', 'BRANCH'), |
|
| 200 |
('l', 'limit', '',
|
|
| 201 |
'limit number of changes displayed', 'NUM'), |
|
| 202 |
('d', 'date', '',
|
|
| 203 |
'show revisions matching date spec', 'DATE'), |
|
| 204 |
('u', 'user', [],
|
|
| 205 |
'revisions committed by user', 'USER'), |
|
| 206 |
('', 'from', '',
|
|
| 207 |
'', ''), |
|
| 208 |
('', 'to', '',
|
|
| 209 |
'', ''), |
|
| 210 |
('', 'rhbranch', '',
|
|
| 211 |
'', ''), |
|
| 212 |
('', 'template', '',
|
|
| 213 |
'display with template', 'TEMPLATE')], |
|
| 214 |
'hg rhlog [OPTION]... [FILE]'), |
|
| 179 | 215 |
'rhmanifest': (rhmanifest, |
| 180 | 216 |
[('r', 'rev', '', 'show the specified revision')],
|
| 181 | 217 |
'hg rhmanifest [-r REV] [PATH]'), |
Also available in: Unified diff