Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F189027
NotifyBuildSystemCustomAction.php
No One
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Authored By
epriestley
Aug 11 2014, 9:24 PM
2014-08-11 21:24:10 (UTC+0)
Size
1 KB
Referenced Files
None
Subscribers
None
NotifyBuildSystemCustomAction.php
View Options
<?php
final
class
NotifyBuildSystemCustomAction
extends
HeraldCustomAction
{
public
function
appliesToAdapter
(
HeraldAdapter
$adapter
)
{
return
(
$adapter
instanceof
HeraldDifferentialRevisionAdapter
);
}
public
function
appliesToRuleType
(
$rule_type
)
{
return
(
$rule_type
==
HeraldRuleTypeConfig
::
RULE_TYPE_GLOBAL
);
}
public
function
getActionKey
()
{
return
'zeeg.build'
;
}
public
function
getActionName
()
{
return
pht
(
'Run Zeeg Build'
);
}
public
function
getActionType
()
{
return
HeraldAdapater
::
VALUE_NONE
;
}
public
function
applyEffect
(
HeraldAdapter
$adapter
,
$object
,
HeraldEffect
$effect
)
{
$revision
=
$object
;
// NOTE: This specific API might change slightly at some point.
$diff
=
$object
->
loadActiveDiff
();
// Implement a call here to your external build system.
$revision_id
=
$revision
->
getID
();
$diff_id
=
$diff
->
getID
();
phlog
(
"Build D{$revision_id} / diff {$diff_id}."
);
return
new
HeraldApplyTranscript
(
$effect
,
true
,
pht
(
'Ran plan.'
));
}
}
File Metadata
Details
Attached
Mime Type
text/plain; charset=utf-8
Storage Engine
amazon-s3
Storage Format
Raw Data
Storage Handle
phabricator/bh/2y/zvg3curk2jy5grmq
Default Alt Text
NotifyBuildSystemCustomAction.php (1 KB)
Attached To
Mode
P1228 NotifyBuildSystemCustomAction.php
Attached
Detach File
Event Timeline
Log In to Comment