mirror of
https://github.com/freeedcom/ai-codereviewer.git
synced 2024-11-23 04:29:03 +00:00
log more
This commit is contained in:
parent
a6762eb223
commit
97bdebd585
4
dist/index.js
vendored
4
dist/index.js
vendored
@ -200,10 +200,14 @@ function main() {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const prDetails = yield getPRDetails();
|
||||
let diff;
|
||||
console.log("Running the action...");
|
||||
console.log("Event name:", process.env.GITHUB_EVENT_NAME);
|
||||
if (process.env.GITHUB_EVENT_NAME === "pull_request") {
|
||||
console.log("Pull request event");
|
||||
diff = yield getDiff(prDetails.owner, prDetails.repo, prDetails.pull_number);
|
||||
}
|
||||
else if (process.env.GITHUB_EVENT_NAME === "push") {
|
||||
console.log("Push event");
|
||||
const pushEvent = JSON.parse((0, fs_1.readFileSync)(process.env.GITHUB_EVENT_PATH || "", "utf8"));
|
||||
console.log("Push event:");
|
||||
console.log(pushEvent);
|
||||
|
2
dist/index.js.map
vendored
2
dist/index.js.map
vendored
File diff suppressed because one or more lines are too long
@ -196,14 +196,17 @@ async function createReviewComment(
|
||||
async function main() {
|
||||
const prDetails = await getPRDetails();
|
||||
let diff: string | null;
|
||||
|
||||
console.log("Running the action...");
|
||||
console.log("Event name:", process.env.GITHUB_EVENT_NAME);
|
||||
if (process.env.GITHUB_EVENT_NAME === "pull_request") {
|
||||
console.log("Pull request event");
|
||||
diff = await getDiff(
|
||||
prDetails.owner,
|
||||
prDetails.repo,
|
||||
prDetails.pull_number
|
||||
);
|
||||
} else if (process.env.GITHUB_EVENT_NAME === "push") {
|
||||
console.log("Push event");
|
||||
const pushEvent = JSON.parse(
|
||||
readFileSync(process.env.GITHUB_EVENT_PATH || "", "utf8")
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user