Commits

Yuya Nishihara committed 662f103

merge: run internal:merge (autoresolve) by default

It seems users are often overwhelmed by ResolveDialog for trivial merge.

Comments (0)

Files changed (8)

tortoisehg/hgqt/backout.py

         repo = self._repoagent.rawRepo()
         n = 'autoresolve'
         self.setField(n, repo.ui.configbool('tortoisehg', n,
-                                            qs.value(n).toBool()))
+                                            qs.value(n, True).toBool()))
         qs.endGroup()
 
     def _writeSettings(self):

tortoisehg/hgqt/graft.py

         qs.beginGroup('graft')
         self.autoresolvechk.setChecked(
             self.repo.ui.configbool('tortoisehg', 'autoresolve',
-                                    qs.value('autoresolve').toBool()))
+                                    qs.value('autoresolve', True).toBool()))
         qs.endGroup()
 
     def _writeSettings(self):

tortoisehg/hgqt/merge.py

         repo = self._repoagent.rawRepo()
         n = 'autoresolve'
         self.setField(n, repo.ui.configbool('tortoisehg', n,
-                                            qs.value(n).toBool()))
+                                            qs.value(n, True).toBool()))
         qs.endGroup()
 
     def _writeSettings(self):

tortoisehg/hgqt/rebase.py

         qs.beginGroup('rebase')
         self.autoresolvechk.setChecked(
             self.repo.ui.configbool('tortoisehg', 'autoresolve',
-                                    qs.value('autoresolve').toBool()))
+                                    qs.value('autoresolve', True).toBool()))
         qs.endGroup()
 
     def _writeSettings(self):

tortoisehg/hgqt/resolve.py

         self.rtreecmenu.popup(self.rtree.viewport().mapToGlobal(point))
 
     def utreeDoubleClicked(self):
-        if self.repo.ui.configbool('tortoisehg', 'autoresolve'):
+        if self.repo.ui.configbool('tortoisehg', 'autoresolve', True):
             self.merge()
         else:
             self.merge('internal:merge')

tortoisehg/hgqt/settings.py

           'with changes on both sides of the merge will report as conflicting, '
           'even if the edits are to different parts of the file. In either '
           'case, when conflicts occur, the user will be invited to review and '
-          'resolve changes manually. Default: False.')),
+          'resolve changes manually. Default: True.')),
     )),
 
 ({'name': 'log', 'label': _('Workbench'), 'icon': 'menulog'}, (

tortoisehg/hgqt/sync.py

         link = self.linkifyWithTarget(url or self.currentUrl())
 
         cmdline = ['pull', '--verbose']
-        uimerge = self.repo.ui.configbool('tortoisehg', 'autoresolve') \
+        uimerge = self.repo.ui.configbool('tortoisehg', 'autoresolve', True) \
             and 'ui.merge=internal:merge' or 'ui.merge=internal:fail'
         if self.cachedpp == 'rebase':
             cmdline += ['--rebase', '--config', uimerge]
         self.autoresolve_chk = QCheckBox(_('Automatically resolve merge '
                                            'conflicts where possible'))
         self.autoresolve_chk.setChecked(
-            repo.ui.configbool('tortoisehg', 'autoresolve', False))
+            repo.ui.configbool('tortoisehg', 'autoresolve', True))
         layout.addWidget(self.autoresolve_chk)
 
         cfglabel = QLabel(_('<a href="config">Launch settings tool...</a>'))

tortoisehg/hgqt/update.py

         self.merge_chk.setChecked(qs.value('merge').toBool())
         self.autoresolve_chk.setChecked(
             self.repo.ui.configbool('tortoisehg', 'autoresolve',
-                                    qs.value('autoresolve').toBool()))
+                                    qs.value('autoresolve', True).toBool()))
         self.verbose_chk.setChecked(qs.value('verbose').toBool())
 
         # expand options if a hidden one is checked