diff options
author | CHEN, Hua <chuaphy@163.com> | 2021-05-23 19:12:20 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-23 19:12:20 +0300 |
commit | 25be50d1a2d135b7912e6ae8ffc1e46d0acbf2a1 (patch) | |
tree | ed4cdfa6183edd74b3dd2480bfb8f5c3fb96a3fe | |
parent | 2dc1f8bb184c36329375af3b4bafc445e2c2210d (diff) |
fix: resolve the editURL problem on Windows (#308)
updates #279
-rw-r--r-- | layouts/partials/components/post-gitinfo.html | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/layouts/partials/components/post-gitinfo.html b/layouts/partials/components/post-gitinfo.html index 03da597..17fcd38 100644 --- a/layouts/partials/components/post-gitinfo.html +++ b/layouts/partials/components/post-gitinfo.html @@ -42,7 +42,7 @@ {{ with .Site.Params.repoEditURL }} {{ $contentDir := (cond $.Site.IsMultiLingual (printf `/%s/` $.Site.Params.contentDir) "/content/") }} <div class="gitinfo-item edit"> - <a href="{{ . }}{{ $contentDir }}{{ $.Path }}" target="_blank" rel="noopener"> + <a href="{{ . }}{{ $contentDir }}{{ replace $.Path "\\" "/" }}" target="_blank" rel="noopener"> {{- partial "utils/icon.html" (dict "$" $ "name" $.Site.Params.editIcon "class" "edit-icon") -}} {{- $.Site.Params.editText -}} </a> |