Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 2.0.1, 2.0.2, and 2.0.3

stable run: fix repository verification path

Egads I need to take a break

1. The Workbench is in the nonrepo_commands list, so it bypassed the check
2. options is not passed to the dialog run function, cmdoptions is
3. There is no lui variable where the repository is created

Changeset 1bf63aeadb29

Parent 93f27f8bafc9

by Steve Borho

Changes to one file · Browse files at 1bf63aeadb29 Showing diff from parent 93f27f8bafc9 Diff from another changeset...

 
265
266
267
268
269
270
271
 
273
274
275
 
276
277
278
 
289
290
291
292
293
294
295
296
 
 
 
297
298
299
 
457
458
459
460
 
461
462
463
464
465
466
 
467
468
469
 
265
266
267
 
268
269
270
 
272
273
274
275
276
277
278
 
289
290
291
 
 
 
 
 
292
293
294
295
296
297
 
455
456
457
 
458
459
460
461
462
463
 
464
465
466
467
@@ -265,7 +265,6 @@
  path, bundle = s   cmdoptions['bundle'] = os.path.abspath(bundle)   path = ui.expandpath(path) - cmdoptions['repository'] = path   os.chdir(path)   if options['fork']:   cmdoptions['fork'] = True @@ -273,6 +272,7 @@
  cmdoptions['nofork'] = True   path = paths.find_root(os.getcwd())   if path: + cmdoptions['repository'] = path   try:   lui = ui.copy()   lui.readconfig(os.path.join(path, ".hg", "hgrc")) @@ -289,11 +289,9 @@
  if options['quiet']:   ui.quiet = True   - if cmd not in nonrepo_commands.split(): - if not path: - raise error.RepoError(_("There is no Mercurial repository here" - " (.hg not found)")) - options['root'] = path + if cmd not in nonrepo_commands.split() and not path: + error.RepoError(_("There is no Mercurial repository here" + " (.hg not found)"))     cmdoptions['mainapp'] = True   d = lambda: util.checksignature(func)(ui, *args, **cmdoptions) @@ -457,13 +455,13 @@
  qtlib.initfontcache(ui)   self._mainapp.setWindowIcon(qtlib.geticon('thg-logo'))   - if 'root' in opts: + if 'repository' in opts:   try:   # Ensure we can open the repository before opening any   # dialog windows. Since thgrepo instances are cached, this   # is not wasted.   from tortoisehg.hgqt import thgrepo - repo = thgrepo.repository(lui, opts['root']) + repo = thgrepo.repository(ui, opts['repository'])   except error.RepoError, e:   qtlib.WarningMsgBox(_('Repository Error'),   hglib.tounicode(str(e)))