Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies/devDependencies to latest #157

Merged
merged 4 commits into from Oct 15, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions index.js
Expand Up @@ -8,7 +8,7 @@ import { Plugin } from 'release-it';
import { format } from 'release-it/lib/util.js';
import tmp from 'tmp';
import execa from 'execa';
import parse from 'mdast-util-from-markdown';
import { fromMarkdown } from 'mdast-util-from-markdown';

const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
Expand Down Expand Up @@ -187,7 +187,7 @@ export default class LernaChangelogGeneratorPlugin extends Plugin {
}

_findInsertOffset(oldContent) {
let ast = parse(oldContent);
let ast = fromMarkdown(oldContent);
let firstH2 = ast.children.find((it) => it.type === 'heading' && it.depth === 2);
return firstH2 ? firstH2.position.start.offset : 0;
}
Expand Down