Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.6, 0.7, and 0.7.1

commit: don't assume username will be configured as requested

Changeset 5786c91a4010

Parent bedd10202c24

by TK Soh

Changes to one file · Browse files at 5786c91a4010 Showing diff from parent bedd10202c24 Diff from another changeset...

Change 1 of 2 Show Entire File hggtk/​commit.py Stacked
 
313
314
315
316
 
 
 
 
 
 
 
 
317
318
319
 
322
323
324
 
325
326
327
 
313
314
315
 
316
317
318
319
320
321
322
323
324
325
326
 
329
330
331
332
333
334
335
@@ -313,7 +313,14 @@
    def _hg_commit(self, files):   if not self.repo.ui.config('ui', 'username'): - Prompt('Username not configured', 'Please enter a username', self).run() + Prompt('Commit: Invalid username', + 'Your username has not been configured.\n\n' + 'Please configure your username and try again', + self).run() + + # bring up the config dialog for user to enter their username. + # But since we can't be sure they will do it right, we will + # have them to retry, to re-trigger the checking mechanism.   from thgconfig import ConfigDialog   dlg = ConfigDialog(self.repo.root, False)   dlg.show_all() @@ -322,6 +329,7 @@
  dlg.hide()   self.repo = hg.repository(ui.ui(), self.repo.root)   self.ui = self.repo.ui + return     # call the threaded CmdDialog to do the commit, so the the large commit   # won't get locked up by potential large commit. CmdDialog will also