]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Adding confirmation message to 'arc todo' with information about the task created
authorIzzy Fraimow <ifraimow@ubermind.com>
Thu, 19 Jul 2012 22:12:12 +0000 (15:12 -0700)
committerIzzy Fraimow <ifraimow@ubermind.com>
Thu, 19 Jul 2012 22:12:12 +0000 (15:12 -0700)
Summary: 'arc todo' now logs a message with the task title and URI when run.

Test Plan: Run 'arc todo test' and see that it logs a message with the form 'Created task <task number>: '<task title' at <task URI>

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, Korvin
Differential Revision: https://secure.phabricator.com/D3016

src/workflow/ArcanistTodoWorkflow.php

index a600c373bc8d3a94fa1067bf729883aeeae029a8..6ce8bd2aaa78521c213f97d784f19838ee07158b 100644 (file)
@@ -90,9 +90,15 @@ EOTEXT
       $args['ccPHIDs'] = $phids;
     }
 
-    $conduit->callMethodSynchronous(
+    $result = $conduit->callMethodSynchronous(
       'maniphest.createtask',
       $args);
+
+    echo phutil_console_format(
+      "Created task T%s: '<fg:green>**%s**</fg>' at <fg:blue>**%s**</fg>\n",
+      $result['id'],
+      $result['title'],
+      $result['uri']);
   }
 
 }