@@ -51,27 +56,35 @@ const makeOnPushEvent: ServiceMethodFactory<
: `${repoUrlPrefix}:${Env.PORT}/${repoUrlSuffix}`;
if (data.payload != null) {
- message.write(`Hey ${data.username}, welcome back 🖖.\n\n`);
- message.write(`📖 See the details of your push at:\n`);
+ message.write(toAscii(`Hey ${data.username}, welcome back 🖖.\n\n`));
+ message.write(toAscii(`📖 See the details of your push at:\n`));
if (data.payload.refType === "head") {
- message.write(`🔗 ${repoUrlBase}/show/${data.payload.commitId}\n`);
+ message.write(
+ toAscii(`🔗 ${repoUrlBase}/show/${data.payload.commitId}\n`),
+ );
if (data.payload.refName !== Const.PRIMARY_BRANCH_REF) {
message.write(`\n`);
// todo: if pr already exist, link to it instead of new pr page
message.write(
- `🚀 Quickly create a pull-request from this branch at:\n`,
+ toAscii(
+ `🚀 Quickly create a pull-request from this branch at:\n`,
+ ),
);
message.write(
- `🔗 ${repoUrlBase}/pulls/new?from_branch=${encodeURIComponent(
- data.payload.refName,
- )}\n`,
+ toAscii(
+ `🔗 ${repoUrlBase}/pulls/new?from_branch=${encodeURIComponent(
+ data.payload.refName,
+ )}\n`,
+ ),
);
}
} else if (data.payload.refType === "tag") {
message.write(
- `🏷 ${repoUrlBase}/tags/${encodeURIComponent(
- data.payload.refName,
- )}\n`,
+ toAscii(
+ `🏷 ${repoUrlBase}/tags/${encodeURIComponent(
+ data.payload.refName,
+ )}\n`,
+ ),
);
}
}
...