{% if site.github %}{% capture github_link %} {% assign github_edit_text = site.github_edit_text | default: "Edit page on GitHub" %} {% if page.source %} {% if page.source contains '/wiki/' %} {% assign wiki = '/_edit'%} {% endif %} {{ github_edit_text }} {% else %} {{ github_edit_text }} {% endif %} {% endcapture %}{{ github_link | strip_new_lines | lstrip | rstrip }}{% endif %}