提交 68cb8cc6 编写于 作者: sinat_25235033's avatar sinat_25235033

use bot_github_token

上级 b8326b92
......@@ -21,4 +21,3 @@ jobs:
- uses: ./
with:
bot_github_token: ${{ secrets.BOT_GITHUB_TOKEN }}
milliseconds: 1000
......@@ -2,10 +2,9 @@ name: 'issue translator'
description: 'The action for translating non-english issues content to english.'
author: 'tomsun28'
inputs:
milliseconds: # change this
bot_github_token:
required: true
description: 'input description here'
default: 'default value if applicable'
description: 'bot_github_token'
runs:
using: 'node12'
main: 'dist/index.js'
......@@ -6,7 +6,6 @@ import translate from '@k3rn31p4nic/google-translate-api'
async function run(): Promise<void> {
try {
core.info(JSON.stringify(github.context))
if (
github.context.eventName !== 'issue_comment' ||
github.context.payload.action ||
......@@ -19,7 +18,6 @@ async function run(): Promise<void> {
}
const issueCommentPayload = github.context
.payload as webhook.EventPayloads.WebhookPayloadIssueComment
core.info(JSON.stringify(issueCommentPayload))
const issue_id = issueCommentPayload.issue.id
const issue_origin_comment_body = issueCommentPayload.comment.body
core.info(issue_origin_comment_body)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册