From 000a0baae8b6002cbb85253719f79ec568773870 Mon Sep 17 00:00:00 2001 From: Christian Rocha Date: Thu, 12 Nov 2020 15:23:34 -0500 Subject: [PATCH] Use path separator const when building relative path --- ui/ui.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/ui.go b/ui/ui.go index af83f80..656a4f2 100644 --- a/ui/ui.go +++ b/ui/ui.go @@ -654,7 +654,7 @@ func localFileToMarkdown(cwd string, res gitcha.SearchResult) *markdown { md := &markdown{ markdownType: localMarkdown, localPath: res.Path, - displayPath: strings.Replace(res.Path, cwd+"/", "", -1), // strip absolute path + displayPath: strings.Replace(res.Path, cwd+string(os.PathSeparator), "", -1), // strip absolute path Markdown: charm.Markdown{}, }