From a345e9e62d937b34696630ed990fad05ef97be54 Mon Sep 17 00:00:00 2001 From: Michael Naumov Date: Sun, 15 Sep 2024 12:07:31 -0600 Subject: [PATCH] Add trailing newline --- scripts/bump-version.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/bump-version.ts b/scripts/bump-version.ts index b42b903..b045808 100644 --- a/scripts/bump-version.ts +++ b/scripts/bump-version.ts @@ -43,8 +43,8 @@ package_json.version = newVersion; package_lock_json.version = newVersion; package_lock_json.packages['']['version'] = newVersion; -writeFileSync('package.json', JSON.stringify(package_json, null, 4).replace(/\n/g, '\r\n')); -writeFileSync('package-lock.json', JSON.stringify(package_lock_json, null, 4).replace(/\n/g, '\r\n')); +writeFileSync('package.json', JSON.stringify(package_json, null, 4) + '\n'); +writeFileSync('package-lock.json', JSON.stringify(package_lock_json, null, 4) + '\n'); try { spawnSync('git', ['add', 'CHANGELOG.md', 'package.json', 'package-lock.json']);