private function renderBuildVariablesTable() { $viewer = $this->getRequest()->getUser(); $variables = HarbormasterBuild::getAvailableBuildVariables(); ksort($variables); $rows = array(); $rows[] = pht('The following variables can be used in most fields. To reference ' . 'a variable, use `${name}` in a field.'); $rows[] = pht('| Variable | Description |'); $rows[] = '|---|---|'; foreach ($variables as $name => $description) { $rows[] = '| `' . $name . '` | ' . $description . ' |'; } $rows = implode("\n", $rows); $form = id(new AphrontFormView())->setUser($viewer)->appendRemarkupInstructions($rows); return id(new PHUIObjectBoxView())->setHeaderText(pht('Build Variables'))->appendChild($form); }