{"data":{"slug":"ekalinin-github-markdown-toc","name":"github-markdown-toc","tagline":"Tool for generating Table of Contents for Markdown files","github_url":"https://github.com/ekalinin/github-markdown-toc","owner":"ekalinin","repo":"github-markdown-toc","owner_avatar_url":"https://avatars.githubusercontent.com/u/234891?v=4","primary_language":"Shell","stars":3294,"forks":2686,"topics":["github","markdown","shell","table-of-contents","toc"],"archived":false,"github_pushed_at":"2024-10-12T19:30:59+00:00","maintenance_label":"Dormant","url":"https://www.graphcanon.com/tools/ekalinin-github-markdown-toc","markdown_url":"https://www.graphcanon.com/tools/ekalinin-github-markdown-toc.md","api_url":"https://www.graphcanon.com/api/graphcanon/tools/ekalinin-github-markdown-toc","graph_url":"https://www.graphcanon.com/api/graphcanon/graph?tool=ekalinin-github-markdown-toc","description":"Easy TOC creation for GitHub README.md","homepage_url":null,"license":"MIT","open_issues":24,"watchers":36,"ai_summary":"Provides functionality to generate table of contents for README.md and GitHub wiki pages without installing additional software.","readme_excerpt":"gh-md-toc\n=========\n\n\n\n\ngh-md-toc — is for you if you **want to generate TOC** (Table Of Content) for a README.md or\na GitHub wiki page **without installing additional software**.\n\nIt's my try to fix a problem:\n\n  * [github/issues/215](https://github.com/isaacs/github/issues/215)\n\ngh-md-toc is able to process:\n\n  * stdin\n  * local files (markdown files in local file system)\n  * remote files (html files on github.com)\n\ngh-md-toc tested on Ubuntu, and macOS High Sierra (gh-md-toc release 0.4.9). If you want it on Windows, you\nbetter to use a golang based implementation:\n\n  * [github-markdown-toc.go](https://github.com/ekalinin/github-markdown-toc.go)\n\nIt's more solid, reliable and with ability of a parallel processing. And\nabsolutely without dependencies.\n\nTable of contents\n=================\n\n\n   * [Installation](#installation)\n   * [Usage](#usage)\n      * [STDIN](#stdin)\n      * [Local files](#local-files)\n      * [Remote files](#remote-files)\n      * [Multiple files](#multiple-files)\n      * [Combo](#combo)\n      * [Auto insert and update TOC](#auto-insert-and-update-toc)\n      * [GitHub token](#github-token)\n      * [TOC generation with Github Actions](#toc-generation-with-github-actions)\n   * [Tests](#tests)\n   * [Dependency](#dependency)\n   * [Docker](#docker)\n     * [Local](#local)\n     * [Public](#public)\n\n\n\nInstallation\n============\n\nLinux (manual installation)\n```bash\n$ wget https://raw.githubusercontent.com/ekalinin/github-markdown-toc/master/gh-md-toc\n$ chmod a+x gh-md-toc\n```\n\nMacOS (manual installation)\n```bash\n$ curl https://raw.githubusercontent.com/ekalinin/github-markdown-toc/master/gh-md-toc -o gh-md-toc\n$ chmod a+x gh-md-toc\n```\n\nLinux or MacOS (using [Basher](https://github.com/basherpm/basher))\n```bash\n$ basher install ekalinin/github-markdown-toc\n# `gh-md-toc` will automatically be available in the PATH\n```\n\nUsage\n=====\n\n\nSTDIN\n-----\n\nHere's an example of TOC creating for markdown from STDIN:\n\n```bash\n➥ cat ~/projects/Dockerfile.vim/README.md | ./gh-md-toc -\n  * [Dockerfile.vim](#dockerfilevim)\n  * [Screenshot](#screenshot)\n  * [Installation](#installation)\n        * [OR using Pathogen:](#or-using-pathogen)\n        * [OR using Vundle:](#or-using-vundle)\n  * [License](#license)\n```\n\nLocal files\n-----------\n\nHere's an example of TOC creating for a local README.md:\n\n```bash\n➥ ./gh-md-toc ~/projects/Dockerfile.vim/README.md\n\n\nTable of Contents\n=================\n\n  * [Dockerfile.vim](#dockerfilevim)\n  * [Screenshot](#screenshot)\n  * [Installation](#installation)\n        * [OR using Pathogen:](#or-using-pathogen)\n        * [OR using Vundle:](#or-using-vundle)\n  * [License](#license)\n```\n\nRemote files\n------------\n\nAnd here's an example, when you have a README.md like this:\n\n  * [README.md without TOC](https://github.com/ekalinin/envirius/blob/f939d3b6882bfb6ecb28ef7b6e62862f934ba945/README.md)\n\nAnd you want to generate TOC for it.\n\nThere is nothing easier:\n\n```bash\n➥ ./gh-md-toc https://github.com/ekalinin/envirius/blob/master/README.md\n\nTable of Contents\n=================\n\n  * [envirius](#envirius)\n    * [Idea](#idea)\n    * [Features](#features)\n  * [Installation](#installation)\n  * [Uninstallation](#uninstallation)\n  * [Available plugins](#available-plugins)\n  * [Usage](#usage)\n    * [Check available plugins](#check-available-plugins)\n    * [Check available versions for each plugin](#check-available-versions-for-each-plugin)\n    * [Create an environment](#create-an-environment)\n    * [Activate/deactivate environment](#activatedeactivate-environment)\n      * [Activating in a new shell](#activating-in-a-new-shell)\n      * [Activating in the same shell](#activating-in-the-same-shell)\n    * [Get list of environments](#get-list-of-environments)\n    * [Get current activated environment](#get-current-activated-environment)\n    * [Do something in environment without enabling it](#do-something-in-environment-without-enabling-it)\n    * [Get help](#get-help)\n    * [Get help for a command](#get-help-for-a-command)\n  * [How","github_created_at":"2014-09-02T15:33:16+00:00","created_at":"2026-07-11T23:08:00.418739+00:00","updated_at":"2026-08-01T18:00:20.211977+00:00","categories":[{"slug":"developer-tools","name":"Developer Tools","url":"https://www.graphcanon.com/categories/developer-tools","markdown_url":"https://www.graphcanon.com/categories/developer-tools.md","api_url":"https://www.graphcanon.com/api/graphcanon/categories/developer-tools"}],"tags":[{"slug":"github","name":"github"},{"slug":"markdown","name":"markdown"},{"slug":"shell","name":"shell"},{"slug":"table-of-contents","name":"table-of-contents"},{"slug":"toc","name":"toc"}],"trust":{"provenance":{"is_fork":false,"github_id":23584347,"owner_type":"User","methodology":"github_public_v1","parent_repo":null,"near_duplicate_slugs":[]},"computed_at":"2026-08-01T18:00:19.209Z","maintenance":{"label":"Dormant","score":18,"methodology":"github_public_v1","releases_90d":0,"days_since_push":657,"last_release_at":"2024-03-03T11:00:19Z"},"security_summary":{"status":"no_lockfile","scanner":null,"low_count":0,"high_count":0,"last_scan_at":"2026-07-11T23:08:07.373Z","medium_count":0,"scan_profile":"none","critical_count":0}},"capability_facts":{"scan":{"source":"repo_scan","observed_at":"2026-08-01T18:00:19.655Z"},"deploy":{"source":"dockerfile:Dockerfile","self_host":true,"observed_at":"2026-08-01T18:00:19.655Z","managed_saas":false},"languages":{"value":["shell"],"source":"github.language","observed_at":"2026-08-01T18:00:19.655Z"},"has_docker":{"value":true,"source":"dockerfile:Dockerfile","observed_at":"2026-08-01T18:00:19.655Z"},"license_spdx":{"value":"MIT","source":"github.license","observed_at":"2026-08-01T18:00:19.655Z"}},"decision_facts":{"hosting":null,"pricing":null,"requirements":null,"constraints":null,"when_to_use":["For users looking to generate a TOC from local or remote Markdown files, including README.md and wiki pages, in environments where installing software is either not allowed or unnecessary.","If you are working with Ubuntu or macOS and want to avoid dependencies that some other solutions might require."],"when_not_to_use":["In Windows environments since it relies on shell scripting, although a Go-based alternative exists for more reliable cross-platform use.","For projects requiring advanced features such as parallel processing, which are supported by competitors written in languages better suited for these tasks."],"source":"enrich:decision_facts","observed_at":"2026-07-14T21:07:10.457Z"},"constraint_facets":null,"decision_summary":[{"label":"Adopt for","value":"github-markdown-toc is a shell-based tool to create table of contents for Markdown files on GitHub without requiring additional software installation."}]}}