]> khamidou — GitHub mirrors - arcanist.git/commitdiff
Require defining workflows' synopses and help
authorvrana <jakubv@fb.com>
Fri, 19 Oct 2012 16:50:56 +0000 (09:50 -0700)
committervrana <jakubv@fb.com>
Fri, 19 Oct 2012 18:01:57 +0000 (11:01 -0700)
Test Plan: Deleted `getCommandSynopses()` from workflow, ran `arc help`.

Reviewers: epriestley, edward

Reviewed By: epriestley

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

src/workflow/ArcanistBaseWorkflow.php

index 46eff56b207574a8881694d14f60e6e9824ddbf3..2dc793e0516b31373e4bdaff0d11417deea7cbdb 100644 (file)
@@ -91,6 +91,20 @@ abstract class ArcanistBaseWorkflow {
    */
   abstract public function getWorkflowName();
 
+  /**
+   * Return console formatted string with all command synopses.
+   *
+   * @return string  6-space indented list of available command synopses.
+   */
+  abstract public function getCommandSynopses();
+
+  /**
+   * Return console formatted string with command help printed in `arc help`.
+   *
+   * @return string  10-space indented help to use the command.
+   */
+  abstract public function getCommandHelp();
+
 
 /* -(  Conduit  )------------------------------------------------------------ */
 
@@ -470,14 +484,6 @@ abstract class ArcanistBaseWorkflow {
     return $this->arcanistConfiguration;
   }
 
-  public function getCommandSynopses() {
-    return get_class($this).": Undocumented";
-  }
-
-  public function getCommandHelp() {
-    return get_class($this).": Undocumented";
-  }
-
   public function requiresWorkingCopy() {
     return false;
   }