Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14041641
D15294.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D15294.id.diff
View Options
diff --git a/src/applications/diffusion/engine/DiffusionCommitHookEngine.php b/src/applications/diffusion/engine/DiffusionCommitHookEngine.php
--- a/src/applications/diffusion/engine/DiffusionCommitHookEngine.php
+++ b/src/applications/diffusion/engine/DiffusionCommitHookEngine.php
@@ -10,6 +10,7 @@
*/
final class DiffusionCommitHookEngine extends Phobject {
+ const ENV_REPOSITORY = 'PHABRICATOR_REPOSITORY';
const ENV_USER = 'PHABRICATOR_USER';
const ENV_REMOTE_ADDRESS = 'PHABRICATOR_REMOTE_ADDRESS';
const ENV_REMOTE_PROTOCOL = 'PHABRICATOR_REMOTE_PROTOCOL';
@@ -610,7 +611,7 @@
$console = PhutilConsole::getConsole();
$env = array(
- 'PHABRICATOR_REPOSITORY' => $this->getRepository()->getCallsign(),
+ self::ENV_REPOSITORY => $this->getRepository()->getPHID(),
self::ENV_USER => $this->getViewer()->getUsername(),
self::ENV_REMOTE_PROTOCOL => $this->getRemoteProtocol(),
self::ENV_REMOTE_ADDRESS => $this->getRemoteAddress(),
diff --git a/src/docs/user/userguide/diffusion_hooks.diviner b/src/docs/user/userguide/diffusion_hooks.diviner
--- a/src/docs/user/userguide/diffusion_hooks.diviner
+++ b/src/docs/user/userguide/diffusion_hooks.diviner
@@ -42,7 +42,7 @@
These additional variables will be available in the environment, in addition
to the variables the VCS normally provides:
- - `PHABRICATOR_REPOSITORY` The callsign of the repository the hook is
+ - `PHABRICATOR_REPOSITORY` The PHID of the repository the hook is
executing for.
- `PHABRICATOR_USER` The Phabricator username that the session is
authenticated under.
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 12, 8:12 PM (6 d, 4 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6738666
Default Alt Text
D15294.id.diff (1 KB)
Attached To
Mode
D15294: Pass repository PHID to custom hooks in PHABRICATOR_REPOSITORY instead of callsign
Attached
Detach File
Event Timeline
Log In to Comment