Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9, 1.9.1, and 1.9.2

update: add Update dialog

Changeset 518ef4cd6ed2

Parent f30522a116db

by Yuki KODAMA

Changes to 2 files · Browse files at 518ef4cd6ed2 Showing diff from parent f30522a116db Diff from another changeset...

 
309
310
311
 
 
 
 
 
312
313
314
 
523
524
525
 
 
 
 
 
526
527
528
 
309
310
311
312
313
314
315
316
317
318
319
 
528
529
530
531
532
533
534
535
536
537
538
@@ -309,6 +309,11 @@
  from tortoisehg.hgqt.shellconf import run   qtrun(run, ui, *pats, **opts)   +def update(ui, *pats, **opts): + """update/checkout tool""" + from tortoisehg.hgqt.update import run + qtrun(run, ui, *pats, **opts) +  ### help management, adapted from mercurial.commands.help_()  def help_(ui, name=None, with_version=False, **opts):   """show help for a command, extension, or list of commands @@ -523,6 +528,11 @@
   table = {   "^clone": (clone, [], _('thg clone SOURCE [DEST]')), + "^update|checkout|co": + (update, + [('C', 'clean', None, _('discard uncommitted changes (no backup)')), + ('r', 'rev', '', _('revision to update')),], + _('hgqt update [-C] [[-r] REV')),  }    if os.name == 'nt':
Change 1 of 1 Show Entire File tortoisehg/​hgqt/​update.py Stacked
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
@@ -0,0 +1,16 @@
+# update.py - Update dialog for TortoiseHg +# +# Copyright 2007 TK Soh <teekaysoh@gmail.com> +# Copyright 2007 Steve Borho <steve@borho.org> +# Copyright 2010 Yuki KODAMA <endflow.net@gmail.com> +# +# This software may be used and distributed according to the terms of the +# GNU General Public License version 2, incorporated herein by reference. + +from tortoisehg.hgqt import cmdui + +def run(ui, *pats, **opts): + args = ['update'] + if opts.get('rev'): + args += ['-r', opts.get('rev')] + return cmdui.Dialog(args)