Co-authored-by: Parker Brown <17183625+parkerbxyz@users.noreply.github.com> Co-authored-by: Gregor Martynus <gr2m@users.noreply.github.com>
This commit is contained in:
20
lib/post.js
Normal file
20
lib/post.js
Normal file
@@ -0,0 +1,20 @@
|
||||
// @ts-check
|
||||
|
||||
import core from "@actions/core";
|
||||
import { request } from "@octokit/request";
|
||||
|
||||
/**
|
||||
* @param {core} core
|
||||
* @param {request} request
|
||||
*/
|
||||
export async function post(core, request) {
|
||||
const token = core.getState("token");
|
||||
|
||||
await request("DELETE /installation/token", {
|
||||
headers: {
|
||||
authorization: `token ${token}`,
|
||||
},
|
||||
});
|
||||
|
||||
core.info("Token revoked");
|
||||
}
|
||||
Reference in New Issue
Block a user