adriantanasa / github-wiki-sidebar Goto Github PK
View Code? Open in Web Editor NEWGithub Wiki sidebar menu builder with multi-level, ordering and exclusion list support
License: MIT License
Github Wiki sidebar menu builder with multi-level, ordering and exclusion list support
License: MIT License
As a github-wiki-sidebar user I want to be able to exclude pages from the generated menu so I can remove irrelevant content from the main menu of my wiki.
Proposed implementation:
One common usage could be to remove the Home.md page from the menu
Command fails. No debug output.
options file:
{
"menu": {
"item": "{{#levelRepeat}} {{/levelRepeat}}* [{{{title}}}]({{{link}}})\n",
"category": "{{#levelRepeat}} {{/levelRepeat}}* {{#link}}[{{{title}}}]({{{link}}}){{/link}}{{^link}}{{{title}}}{{/link}}\n{{{subitems}}}",
"category-1": "{{{subitems}}}\n"
},
"rules": {
"exclude": [],
"order": [
"Home.md"
]
},
"separator": "#",
"linkTemplate": "./%s",
"menuFile": "_Sidebar.md",
"multilang": false,
"menuOnly": true
}
job output:
export DEBUG=github-wiki-sidebar; npx github-wiki-sidebar --silent
github-wiki-sidebar Executing job silent +0ms
//-- github-wiki-sidebar: enquire mode
github-wiki-sidebar Generating the custom options.json file ... +2ms
github-wiki-sidebar Build the _Sidebar.md file ... +0ms
Error generating _Sidebar.md:
//-- Job completed.
ive npm installed github-wiki-sidebar
, ran it, and i see the _Sidebar.md that was generated and pushed to my repo. (https://github.com/1ak31sha/dotfiles/blob/master/_Sidebar.md)
but on wiki page, no custom sidebar shows up https://github.com/1ak31sha/dotfiles/wiki
any help much appreciated, thanks :)
Just tried out github-wiki-sidebar in enquire-mode and am unable to specify a category separator.
I am always being prompted that "The following characters are allowed a-z#~ @_!"
rregardless if I try to choose the default (just hitting enter) or manually defining a category separator.
(Running this within the latest PowerShell Core 6.2.2)
Originally posted by @tillik in #5 (comment)
It would be nice (in particular for wikis with a lot of content) to make subsections collapsible using javascript.
Home.md
FAQ/QA1.md
FAQ/QA2.md
About.md
running npx github-wiki-sidebar --silent
will see only following:
Home
About
When I run this, I only get the page titles and not the subheadings '#', '##', etc.
All markdown files beginning with a number are not added to the sidebar when generated. Seems it cannot be solved in the "menu"
configuration.
options.json:
{
"menu": {
"item": "{{#levelRepeat}} {{/levelRepeat}}* [[{{{title}}}|{{{link}}}]]\n",
"category": "{{#levelRepeat}} {{/levelRepeat}}* {{#link}}[[{{{title}}}|{{{link}}}]]{{/link}}{{^link}}{{{title}}}{{/link}}\n{{{subitems}}}",
"category-1": "{{{subitems}}}\n"
},
"rules": {
"exclude": [],
"order": [
"Home.md"
]
},
"separator": "_",
"linkTemplate": "%s",
"menuFile": "_Sidebar.md",
"multilang": false,
"menuOnly": true
}
File tree (markdown files):
Home
1-Le Dépôt_1-Backend_Outils tiers utilisés
I-Le Dépôt
I-Le Dépôt_1-Backend_Utiliser les services
2-Le Wiki
Terminal:
$ github-wiki-sidebar --silent
//-- github-wiki-sidebar: enquire mode
_Sidebar.md generated.
//-- Job completed.
Generated _Sidebar.md:
* [[Home|Home]]
* [[I Le Dépôt|I-Le Dépôt]]
* 1 Backend
* [[Utiliser les services|I-Le Dépôt_1-Backend_Utiliser les services]]
[//]: # (generated by https://www.npmjs.com/package/github-wiki-sidebar)
P.S.: @adriantanasa This project is still useful, please make it up to date.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.