add debug log
This commit is contained in:
Родитель
3c062e92f8
Коммит
4cbf9c23cc
10
src/main.ts
10
src/main.ts
|
@ -6,14 +6,20 @@ async function run() {
|
|||
try {
|
||||
let payload: IncomingWebhookSendArguments = {};
|
||||
const text = core.getInput('text');
|
||||
switch (core.getInput('type')) {
|
||||
const failedMention = core.getInput('failedMenthon');
|
||||
const _type = core.getInput('type');
|
||||
core.debug(`text: ${text}`);
|
||||
core.debug(`failedMention: ${failedMention}`);
|
||||
core.debug(`type: ${_type}`);
|
||||
|
||||
switch (_type) {
|
||||
case 'auto':
|
||||
throw new Error('not implement');
|
||||
case 'success':
|
||||
payload = successPayload(text);
|
||||
break;
|
||||
case 'failure':
|
||||
payload = failurePayload(text, core.getInput('failedMenthon'));
|
||||
payload = failurePayload(text, failedMention);
|
||||
break;
|
||||
default:
|
||||
payload = JSON.parse(core.getInput('payload'));
|
||||
|
|
Загрузка…
Ссылка в новой задаче