From 2bccc07ffa592b25ddd6f8283a17a3d0db896933 Mon Sep 17 00:00:00 2001 From: snek Date: Tue, 30 May 2023 10:10:58 -0700 Subject: [PATCH] Meta: fix newline in snapshot warning (#3082) --- scripts/insert_snapshot_warning.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/insert_snapshot_warning.js b/scripts/insert_snapshot_warning.js index b6e7aedf17..e2d02e6bfc 100644 --- a/scripts/insert_snapshot_warning.js +++ b/scripts/insert_snapshot_warning.js @@ -5,7 +5,7 @@ const path = require('path'); const { JSDOM } = require('jsdom'); const { execSync } = require('child_process'); -const COMMIT = String(execSync('git rev-parse --verify HEAD')); +const COMMIT = String(execSync('git rev-parse --verify HEAD')).trim(); const WARNING_HTML = fs.readFileSync(path.join(__dirname, 'snapshot_warning.html'), 'utf8') .replace(/{COMMIT}/g, COMMIT);