Skip to content

Commit 529d92d

Browse files
authored
Merge pull request #164 from rwjblue/ensure-blank-line
2 parents 7fc2966 + c931f8b commit 529d92d

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

__tests__/bin-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@ describe('main binary', function () {
536536
await exec(['--no-install', '--no-label-updates', '--update']);
537537

538538
expect(fs.readFileSync('CHANGELOG.md', { encoding: 'utf8' })).toBe(
539-
'# Changelog\n## v1.2.0\n* Foo bar'
539+
'# Changelog\n\n## v1.2.0\n* Foo bar'
540540
);
541541
});
542542
});

bin/rwjblue-release-it-setup.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,9 @@ async function main() {
247247
let hasH1 = ast.children.find((it) => it.type === 'heading' && it.depth === 1);
248248

249249
if (!hasH1) {
250-
fs.writeFileSync('CHANGELOG.md', `# Changelog\n${changelogContent}`, { encoding: 'utf8' });
250+
fs.writeFileSync('CHANGELOG.md', `# Changelog\n\n${changelogContent}`, {
251+
encoding: 'utf8',
252+
});
251253
}
252254
}
253255

0 commit comments

Comments
 (0)