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

Let Flow-Launcher/Flow.Launcher.Plugin.PythonTemplate readme could show #30

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion _sidebar.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,6 @@
- JSONRPC Plugins
- [**JSON RPC Introduction**](/json-rpc.md)
- [**Develop Python Plugins**](/develop-py-plugins.md)
- [**Porting Plugins**](/port-plugins.md)
- [**Porting Plugins**](/port-plugins.md)
- Plugin Templates
- [**Python Template**](/pytemplate.md)
15 changes: 13 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,21 @@
subMaxLevel: 4,
search: 'auto',
auto2top: true,
alias: {
'.*?/pytemplate':
'https://raw.githubusercontent.com/Flow-Launcher/Flow.Launcher.Plugin.PythonTemplate/master/README.md',
},
Copy link
Member

Choose a reason for hiding this comment

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

Also here, what does the alias do?

Copy link
Member Author

Choose a reason for hiding this comment

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

Note that what I added pytemplate.md in _sidebar.md, doesn't exist in Flow-Launcher/docs project.
pytemplate.md is a reproject of Flow-Launcher/Flow.Launcher.Plugin.PythonTemplate/README.md

Copy link
Member

Choose a reason for hiding this comment

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

I see, sorry for the huge late review.

plugins: [
function (hook, vm) {
hook.beforeEach(function (html) {
url = 'https://github.com/Flow-Launcher/Docs/blob/main/' + vm.route.file
if (/githubusercontent\.com/.test(vm.route.file)) {
url = vm.route.file
.replace('raw.githubusercontent.com', 'github.com')
.replace(/\/master/, '/blob/master')
.replace(/\/main/, '/blob/main');
} else {
url = 'https://github.com/Flow-Launcher/docs/blob/main/' + vm.route.file
}
var editHtml = '[:memo: Edit this Page](' + url + ')\n'
return editHtml + html
})
Expand All @@ -43,4 +54,4 @@
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-csharp.min.js"></script>
</body>

</html>
</html>