diff --git a/.github/workflows/diff-rendered-charts.yml b/.github/workflows/diff-rendered-charts.yml index 07c5e67..3b46708 100644 --- a/.github/workflows/diff-rendered-charts.yml +++ b/.github/workflows/diff-rendered-charts.yml @@ -127,7 +127,14 @@ jobs: script: | const fs = require('fs'); const comment_char_limit = 65536; // GitHub comment character limit - const diff = fs.readFileSync('diff.log', 'utf8'); + const diff_file = 'diff.log'; + + if (fs.existsSync(diff_file)) { + var diff = fs.readFileSync(diff_file, 'utf8'); + } else { + console.log(diff_file + " not found") + return + } function splitComment(comment, maxSize, sepEnd, sepStart, comStart) { // Adapted from Atlantis SplitComment function @@ -167,4 +174,4 @@ jobs: repo: context.repo.repo, body: comment }) - } \ No newline at end of file + }