Commits

Yuya Nishihara  committed c3ef4d2

run: print command error to stderr appropriately

Since 087924974d18, stderr isn't a black hole, so we can use ui.warn just
like Mercurial.

  • Participants
  • Parent commits a4497c0

Comments (0)

Files changed (1)

File tortoisehg/hgqt/run.py

         finally:
             ui.flush()
     except error.AmbiguousCommand, inst:
-        ui.status(_("thg: command '%s' is ambiguous:\n    %s\n") %
+        ui.warn(_("thg: command '%s' is ambiguous:\n    %s\n") %
                 (inst.args[0], " ".join(inst.args[1])))
     except error.UnknownCommand, inst:
-        ui.status(_("thg: unknown command '%s'\n") % inst.args[0])
+        ui.warn(_("thg: unknown command '%s'\n") % inst.args[0])
         help_(ui, 'shortlist')
     except error.CommandError, inst:
         if inst.args[0]:
-            ui.status(_("thg %s: %s\n") % (inst.args[0], inst.args[1]))
+            ui.warn(_("thg %s: %s\n") % (inst.args[0], inst.args[1]))
             help_(ui, inst.args[0])
         else:
-            ui.status(_("thg: %s\n") % inst.args[1])
+            ui.warn(_("thg: %s\n") % inst.args[1])
             help_(ui, 'shortlist')
     except error.RepoError, inst:
-        ui.status(_("abort: %s!\n") % inst)
+        ui.warn(_("abort: %s!\n") % inst)
 
     return -1