Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.8, 0.8.1, and 0.8.2

thgconfig: change default alias for new path

Changeset dac5a99cfb20

Parent 8465307f7850

by Yuki KODAMA

Changes to one file · Browse files at dac5a99cfb20 Showing diff from parent 8465307f7850 Diff from another changeset...

 
551
552
553
554
 
 
 
 
 
555
556
557
 
551
552
553
 
554
555
556
557
558
559
560
561
@@ -551,7 +551,11 @@
  '''Add a new path to [paths], give default name, focus'''   i = self.pathdata.insert_before(None, None)   safepath = url.hidepassword(newpath) - self.pathdata.set_value(i, 0, 'new') + alias, num = 'new', 0 + while len([row for row in self.pathdata if row[0] == alias]) > 0: + num += 1 + alias = 'new_%d' % num + self.pathdata.set_value(i, 0, alias)   self.pathdata.set_value(i, 1, '%s' % hglib.toutf(safepath))   self.pathdata.set_value(i, 2, '%s' % hglib.toutf(newpath))   self.pathtree.get_selection().select_iter(i)