[doc] Add possibility to override editme link location
If the page contains the variable "editmepath" in the yaml frontmatter, this will be used instead of "page.path" (the actual markdown file). This is useful, if the page is generated from another source.
This commit is contained in:
parent
5360974903
commit
236154100f
@ -41,7 +41,12 @@ layout: default
|
||||
|
||||
{% if site.github_editme_path %}
|
||||
|
||||
<a target="_blank" href="https://github.com/{{site.github_editme_path}}{{page.path}}" class="btn btn-default githubEditButton" role="button"><i class="fa fa-github fa-lg"></i> Edit me</a>
|
||||
{% assign editmepath = page.path %}
|
||||
{% if page.editmepath %}
|
||||
{% assign editmepath = page.editmepath %}
|
||||
{% endif %}
|
||||
|
||||
<a target="_blank" href="https://github.com/{{site.github_editme_path}}{{editmepath}}" class="btn btn-default githubEditButton" role="button"><i class="fa fa-github fa-lg"></i> Edit me</a>
|
||||
|
||||
{% endif %}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user