Skip to content

Commit

Permalink
Fixed json path
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathanbokvad committed Sep 7, 2023
1 parent e69f84d commit c6388da
Showing 1 changed file with 24 additions and 24 deletions.
48 changes: 24 additions & 24 deletions src/Pentest/PentestService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,36 +14,36 @@ export class PentestService {
}
core.setOutput("pentestDate", pentestDate.date);

console.log("Pentest Date is set", pentestDate.date);

// const token = core.getInput('repo-token');
// console.log("Got the token");

const token = core.getInput('repo-token');
console.log("Got the token");
// const octokit = github.getOctokit(token);
// console.log("octoKit authenticated");

const octokit = github.getOctokit(token);
console.log("octoKit authenticated");
// const { owner, repo } = github.context.repo;
// console.log(`Owner: ${owner}`);
// console.log(`Repo: ${repo}`);

const { owner, repo } = github.context.repo;
console.log(`Owner: ${owner}`);
console.log(`Repo: ${repo}`);

console.log("Going to get branch protection");
await octokit.rest.projects.listCards({
owner: owner,
repo: repo,
column_id: 123456789,

}).then((response) => {
console.log("Got the cards");
const projectCards = response.data;
const customLabelCards = projectCards.filter((card) => {
return card.note?.includes(pentestDate.boardsTag);
});
// console.log("Going to get branch protection");
// await octokit.rest.projects.listCards({
// owner: owner,
// repo: repo,
// column_id: 123456789,

// }).then((response) => {
// console.log("Got the cards");
// const projectCards = response.data;
// const customLabelCards = projectCards.filter((card) => {
// return card.note?.includes(pentestDate.boardsTag);
// });


}).catch((error) => {
core.warning("Error getting cards!");
core.warning("Error: ", error.message);
});
// }).catch((error) => {
// core.warning("Error getting cards!");
// core.warning("Error: ", error.message);
// });
// owner: owner,
// repo: repo,
// branch: 'main',
Expand Down

0 comments on commit c6388da

Please sign in to comment.