From 6c03c11aff712744ba5c927a5cc7b6cbf5391fee Mon Sep 17 00:00:00 2001 From: Peter Evans <18365890+peter-evans@users.noreply.github.com> Date: Fri, 26 Jul 2024 10:49:53 +0000 Subject: [PATCH] add debug lines --- dist/index.js | 2 ++ src/create-pull-request.ts | 2 ++ 2 files changed, 4 insertions(+) diff --git a/dist/index.js b/dist/index.js index e6ac360..b5f7a95 100644 --- a/dist/index.js +++ b/dist/index.js @@ -522,12 +522,14 @@ function createPullRequest(inputs) { core.debug(`Changed files: '${JSON.stringify(changedFiles)}'`); core.debug(`Deleted files: '${JSON.stringify(deletedFiles)}'`); for (const file of changedFiles) { + core.debug(`Reading contents of file: '${file}'`); fileChanges.additions.push({ path: file, contents: btoa(fs.readFileSync(file, 'utf8')) }); } for (const file of deletedFiles) { + core.debug(`Marking file as deleted: '${file}'`); fileChanges.deletions.push({ path: file }); diff --git a/src/create-pull-request.ts b/src/create-pull-request.ts index b476d75..1cad292 100644 --- a/src/create-pull-request.ts +++ b/src/create-pull-request.ts @@ -324,6 +324,7 @@ export async function createPullRequest(inputs: Inputs): Promise { core.debug(`Deleted files: '${JSON.stringify(deletedFiles)}'`) for (const file of changedFiles) { + core.debug(`Reading contents of file: '${file}'`) fileChanges.additions!.push({ path: file, contents: btoa(fs.readFileSync(file, 'utf8')) @@ -331,6 +332,7 @@ export async function createPullRequest(inputs: Inputs): Promise { } for (const file of deletedFiles) { + core.debug(`Marking file as deleted: '${file}'`) fileChanges.deletions!.push({ path: file })