Skip to content

Commit

Permalink
feat: add table of contents usage comments
Browse files Browse the repository at this point in the history
how to get started and producing the first table of contents
  • Loading branch information
BobyMCbobs committed Oct 15, 2023
1 parent 3b0f8c2 commit c1de36a
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -873,6 +873,24 @@ jobs:
uses: GeoNet/Actions/.github/workflows/reusable-presubmit-readme-toc.yml@main
```

**important** to note: a markdown file must contain the following

```text
<!-- generate TOC using `go run sigs.k8s.io/mdtoc@latest --inplace README.md` -->
<!-- toc -->
<!-- /toc -->
```

given a markdown file (e.g: `README.md`) and the contents above included
in the markdown file, the table of contents can be generated with the command
in that comment:

```shell
go run sigs.k8s.io/mdtoc@latest --inplace README.md
```

note: requires Go to be installed

### Presubmit GitHub Actions workflow validator

STATUS: stable
Expand Down

0 comments on commit c1de36a

Please sign in to comment.