From ac0e831090eda5f0a59ec4a9e1c67c78f1d0f8ed Mon Sep 17 00:00:00 2001
From: Nick Craig-Wood <nick@craig-wood.com>
Date: Tue, 2 Jun 2020 12:09:45 +0100
Subject: [PATCH] docs: remove leading slash in page reference in footer when
 present

---
 docs/layouts/_default/baseof.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/layouts/_default/baseof.html b/docs/layouts/_default/baseof.html
index 7922ce25c..c5670e720 100644
--- a/docs/layouts/_default/baseof.html
+++ b/docs/layouts/_default/baseof.html
@@ -40,7 +40,7 @@
             <div class="card card-body">
               <p style="font-size: 90%;">
                 &copy; <a href="https://www.craig-wood.com/nick/">Nick Craig-Wood</a> 2014-{{ now.Format "2006" }}<br>
-                {{ if .File}}Source file <a href="https://github.com/rclone/rclone/blob/master/docs/content/{{ .File.Path }}">{{ .File.Path }}</a>
+                {{ if .File}}{{ with $path := strings.TrimPrefix "/" .File.Path }}Source file <a href="https://github.com/rclone/rclone/blob/master/docs/content/{{ $path }}">{{ $path }}</a>{{ end }}
                 last updated <a href="https://github.com/rclone/rclone/commit/{{ with .GitInfo }}{{ .Hash }}{{ end }}">{{ .Lastmod.Format "2006-01-02" }}</a><br>{{end}}
                 Website hosted on a <a href="https://www.memset.com/dedicated-servers/vps/"><span style="font-weight: bold; font-family: arial black, arial, sans-serif; font-style: italic;">MEMSET CLOUD VPS</span></a>,
                 uploaded with <a href="https://rclone.org">rclone</a>