Skip to content

Commit

Permalink
Activate sailor-v preview on lock route
Browse files Browse the repository at this point in the history
  • Loading branch information
williamdes committed Dec 8, 2019
1 parent dfbd97e commit 484964f
Showing 1 changed file with 15 additions and 10 deletions.
25 changes: 15 additions & 10 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,23 @@ const core = require('@actions/core')
const { GitHub, context } = require('@actions/github')

const main = async () => {
const token = core.getInput('github-token');
const lock_reason = core.getInput('lock-reason');
const number = core.getInput('number');
const token = core.getInput('github-token');
const lock_reason = core.getInput('lock-reason');
const number = core.getInput('number');

const octokit = new GitHub(token);
const octokit = new GitHub(token);

await octokit.issues.lock({
lock_reason: lock_reason,
...context.repo,
...context.owner,
issue_number: number,
})
await octokit.issues.lock({
lock_reason: lock_reason,
...context.repo,
...context.owner,
issue_number: number,
mediaType: {
previews: [
'sailor-v'
]
}
})
}

main().catch(err => core.setFailed(err.message))

0 comments on commit 484964f

Please sign in to comment.