Skip to content

Commit b7c82fc

Browse files
committed
feat(push): Differ for force-pushes
1 parent 3db194d commit b7c82fc

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

events/push.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,11 @@ export function pushCreatedComponents(payload: PushEvent): APIMessageTopLevelCom
2121
return [
2222
{
2323
type: ComponentType.Container,
24+
accent_color: payload.forced ? 0xfc2a29 : 0x5865f2,
2425
components: [
2526
{
2627
type: ComponentType.TextDisplay,
27-
content: `[${payload.sender.name ?? payload.sender.login}](${payload.sender.html_url}) committed to [${payload.repository.name}:${branch}](${payload.repository.html_url}).\n${commitDescription}`,
28+
content: `[${payload.sender.name ?? payload.sender.login}](${payload.sender.html_url}) ${payload.forced ? "force-pushed" : "committed"} to [${payload.repository.name}:${branch}](${payload.repository.html_url}).\n${commitDescription}`,
2829
},
2930
{
3031
type: ComponentType.Separator,

0 commit comments

Comments
 (0)