From 7769cdc1aa7685674029537e82121dc73b53e80f Mon Sep 17 00:00:00 2001 From: sivasadobe Date: Wed, 29 May 2024 14:35:35 +0530 Subject: [PATCH] Fix-format --- .github/workflows/src/helpers.js | 1 + .github/workflows/src/send-slack.js | 2 ++ 2 files changed, 3 insertions(+) diff --git a/.github/workflows/src/helpers.js b/.github/workflows/src/helpers.js index ad34091..8be4708 100644 --- a/.github/workflows/src/helpers.js +++ b/.github/workflows/src/helpers.js @@ -1,4 +1,5 @@ function convertMarkdownToSlackFormat(markdown) { + console.log(markdown); // Convert headings markdown = markdown.replace(/^(#+) (.*$)/gim, "*$2*"); // Convert bold text diff --git a/.github/workflows/src/send-slack.js b/.github/workflows/src/send-slack.js index 9b7b488..57a5778 100644 --- a/.github/workflows/src/send-slack.js +++ b/.github/workflows/src/send-slack.js @@ -3,6 +3,8 @@ const { convertMarkdownToSlackFormat } = require("./helpers"); const sendSlackMessage = async (event_pr, slack_webhook_url) => { const { number, html_url, title, body } = event_pr; + console.log({ number, html_url, title, body }); + const text = `:rocket: *Production Release*\n*Title:* ${title} | <${html_url}|#${number}>\n*PR Description:* ${convertMarkdownToSlackFormat( body )}`;