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

[change] Added doctoc and husky precommit hook to automate toc update #623 #624

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

codesankalp
Copy link
Member

@codesankalp codesankalp commented Oct 27, 2022

Changes:

  1. Added husky pre commit hook for running checks before commit.
  2. Added lint-staged in dev dependencies to run pre commit checks on updated code only.
  3. Added doctoc to automate table of content update for README.md

Closes #623

@codesankalp codesankalp added this to In progress in Roadmap via automation Oct 27, 2022
@codesankalp codesankalp self-assigned this Oct 27, 2022
@codesankalp codesankalp force-pushed the issues/623-update-toc branch 2 times, most recently from ed201d0 to cd6fdf1 Compare October 27, 2022 11:56
Copy link
Member

@nemesifier nemesifier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@codesankalp very cool!! 👍

How is the precommit supposed to work? Should it just work or do we need to do anything?
I tried committing a change to the doc with new headings but it didn't update it automatically, if it has to be installed we have to update the dev instructions in the README accordingly please.

@codesankalp
Copy link
Member Author

How is the precommit supposed to work? Should it just work or do we need to do anything? I tried committing a change to the doc with new headings but it didn't update it automatically, if it has to be installed we have to update the dev instructions in the README accordingly please.

So it automatically gets installed when user installs node modules, i.e., by running yarn or npm install. But I have added a separate command to install only hook in docs. Let me know if this command works for you.
I tried creating a separate heading and commiting it and the toc got updated automatically.

Copy link
Member

@nemesifier nemesifier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't get this to work, I wrote you a few DMs.

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

Successfully merging this pull request may close these issues.

[docs] Update README index with missing heading sections
2 participants