diff options
author | Runxi Yu <me@runxiyu.org> | 2025-04-05 21:47:44 +0800 |
---|---|---|
committer | Runxi Yu <me@runxiyu.org> | 2025-04-05 21:47:44 +0800 |
commit | efa6f33b4c67f64a4a8d8cd723b9bbc9494fc735 (patch) | |
tree | c4075c78bc4126d764f91ec68931c34281913dcc /remote_url.go | |
parent | Add missing copyright headers (diff) | |
download | forge-efa6f33b4c67f64a4a8d8cd723b9bbc9494fc735.tar.gz forge-efa6f33b4c67f64a4a8d8cd723b9bbc9494fc735.tar.zst forge-efa6f33b4c67f64a4a8d8cd723b9bbc9494fc735.zip |
Unexport fields in Serverv0.1.24
Diffstat (limited to 'remote_url.go')
-rw-r--r-- | remote_url.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/remote_url.go b/remote_url.go index 8fc5528..a9d8bf2 100644 --- a/remote_url.go +++ b/remote_url.go @@ -15,11 +15,11 @@ import ( // genSSHRemoteURL generates SSH remote URLs from a given group path and repo // name. func (s *Server) genSSHRemoteURL(groupPath []string, repoName string) string { - return strings.TrimSuffix(s.Config.SSH.Root, "/") + "/" + misc.SegmentsToURL(groupPath) + "/-/repos/" + url.PathEscape(repoName) + return strings.TrimSuffix(s.config.SSH.Root, "/") + "/" + misc.SegmentsToURL(groupPath) + "/-/repos/" + url.PathEscape(repoName) } // genHTTPRemoteURL generates HTTP remote URLs from a given group path and repo // name. func (s *Server) genHTTPRemoteURL(groupPath []string, repoName string) string { - return strings.TrimSuffix(s.Config.HTTP.Root, "/") + "/" + misc.SegmentsToURL(groupPath) + "/-/repos/" + url.PathEscape(repoName) + return strings.TrimSuffix(s.config.HTTP.Root, "/") + "/" + misc.SegmentsToURL(groupPath) + "/-/repos/" + url.PathEscape(repoName) } |