Index: src/__phutil_library_map__.php =================================================================== --- src/__phutil_library_map__.php +++ src/__phutil_library_map__.php @@ -157,6 +157,7 @@ 'ArcanistUsageException' => 'exception/ArcanistUsageException.php', 'ArcanistUserAbortException' => 'exception/usage/ArcanistUserAbortException.php', 'ArcanistWhichWorkflow' => 'workflow/ArcanistWhichWorkflow.php', + 'ArcanistWhoamiWorkflow' => 'workflow/ArcanistWhoamiWorkflow.php', 'ArcanistWorkingCopyIdentity' => 'workingcopyidentity/ArcanistWorkingCopyIdentity.php', 'ArcanistXHPASTLintNamingHook' => 'lint/linter/xhpast/ArcanistXHPASTLintNamingHook.php', 'ArcanistXHPASTLintNamingHookTestCase' => 'lint/linter/xhpast/__tests__/ArcanistXHPASTLintNamingHookTestCase.php', @@ -303,6 +304,7 @@ 'ArcanistUsageException' => 'Exception', 'ArcanistUserAbortException' => 'ArcanistUsageException', 'ArcanistWhichWorkflow' => 'ArcanistBaseWorkflow', + 'ArcanistWhoamiWorkflow' => 'ArcanistBaseWorkflow', 'ArcanistXHPASTLintNamingHookTestCase' => 'ArcanistTestCase', 'ArcanistXHPASTLintTestSwitchHook' => 'ArcanistXHPASTLintSwitchHook', 'ArcanistXHPASTLinter' => 'ArcanistBaseXHPASTLinter', Index: src/workflow/ArcanistWhoamiWorkflow.php =================================================================== --- /dev/null +++ src/workflow/ArcanistWhoamiWorkflow.php @@ -0,0 +1,54 @@ +getConduit(); + $user_info = $conduit->callMethodSynchronous( + 'user.whoami', + array()); + echo phutil_console_format( + "Logged in as **%s** (**%s**)\n", + $user_info['userName'], + $user_info['realName']); + } + +}