Skip to content

Commit

Permalink
Generate automatic command
Browse files Browse the repository at this point in the history
  • Loading branch information
caendesilva committed Dec 21, 2024
1 parent 5321cd0 commit 99e6cd6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/bin/pick.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,12 @@
if (preg_match('/^Merge pull request #(\d+).*\n(.*?)https:\/\/github\.com\/hydephp\/develop\/commit/', $commitMessage, $matches)) {
$prNumber = $matches[1];
$title = trim($matches[2]);
$body = "Merges pull request https://github.com/hydephp/develop/pull/$prNumber";

$printWhenDone = "\n\033[33mSuggested PR format: (Line 1: title, Line 2: description)\033[0m\n";
$printWhenDone .= "$title\nMerges pull request https://github.com/hydephp/develop/pull/$prNumber\n";
$printWhenDone = "\n\033[33mSuggested PR format: (Line 1: title, Line 2: description, Line 3: command)\033[0m\n";
$printWhenDone .= "$title\n$body\n";

$printWhenDone .= "\033[37mgh pr create --title \"$title\" --body \"$body\"\033[0m\n";
}
}

Expand Down

0 comments on commit 99e6cd6

Please sign in to comment.