diff --git a/www/pr.php b/www/pr.php index 747b78b..0ef909c 100644 --- a/www/pr.php +++ b/www/pr.php @@ -45,16 +45,24 @@ if($decoded['secret'] != $secret_key['pr']) { file_put_contents("log.txt", print_r($decoded, true)); -$subject = "Pull request: " . $decoded['pull_request']['title'] . " by " . $decoded['pull_request']['user']['login']; +$subject = $decoded['repository']['full_name'] + . " - PR #" + . $decoded['pull_request']['number'] + . " (" + . $decoded['pull_request']['title'] + . ") by " + . $decoded['pull_request']['user']['login']; + $message = $decoded['sender']['login'] . " has " . ($decoded['pull_request']['merged'] ? "merged" : $decoded['action']) . " pull request #" . $decoded['pull_request']['number'] - . " for " . + . " (" . $decoded['pull_request']['title'] . ") for " . $decoded['repository']['full_name'] . ".\n" . - $decoded['pull_request']['html_url']; + $decoded['pull_request']['html_url'] + . "\n\n\nSent to you by https://git.chaospott.de/Chaospott/gitea_webhooks"; foreach($recipients['pr'] as $recp) {