fix(repo): stop advertising HTTP clone URLs when DISABLE_HTTP_GIT is set (#38378)

Fixes #38339

---------

Signed-off-by: TowyTowy <towy@airreps.link>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
TowyTowy
2026-07-17 07:17:28 +02:00
committed by GitHub
parent bca44bd736
commit 8a3daef525
12 changed files with 116 additions and 116 deletions
+1 -1
View File
@@ -84,7 +84,7 @@ func prepareRepoCommit(ctx context.Context, repo *repo_model.Repository, tmpDir
return fmt.Errorf("GetRepoInitFile[%s]: %w", opts.Readme, err)
}
cloneLink := repo.CloneLink(ctx, nil /* no doer so do not generate user-related SSH link */)
cloneLink := repo.CloneLinkGeneral(ctx)
match := map[string]string{
"Name": repo.Name,
"Description": util.NormalizeStringEOL(repo.Description),