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

Overwrite existing table of contents in README #8

Open
kagarlickij opened this issue Jun 28, 2020 · 1 comment
Open

Overwrite existing table of contents in README #8

kagarlickij opened this issue Jun 28, 2020 · 1 comment

Comments

@kagarlickij
Copy link

I frequently update README.md and want to use markdown-toc for table of contents generation

However each time when I run markdown-toc -h 3 -t github README.md is fails with [WARNING]: README.md already has a Table of Contents, Ignoring...

I there a way to run markdown-toc in mode (force?) when it overwrites existing table of contents in the same file?

@alexander-lee
Copy link
Owner

Yeah this is an apparent fault :(, a solution here would be to create a function that tries to identify the start and end of a Table of Contents and overwrites it. Feel free to write up a PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants