Add optional Git protocol clone URLs - #8360
Open
landeqiming666 wants to merge 1 commit into
Open
Conversation
landeqiming666
force-pushed
the
git-protocol-clone-url
branch
from
July 13, 2026 04:22
799a732 to
cdfffa9
Compare
Author
|
Rebased onto the current main branch and re-ran the validation. |
Author
|
Hi, a brief follow-up on this PR. It is rebased on the current main branch, the pull request body follows the repository template, and the focused repository/configuration plus related context and database tests pass. The change remains limited to the optional Git protocol clone URL setting. Please let me know if any further adjustment would help with review. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe the pull request
This adds an optional
[repository] ENABLE_GIT_PROTOCOL_CLONEsetting for sites that already expose public repositories through a separately configured git daemon.When enabled, public repository and wiki clone panels include a
GITprotocol button usinggit://<domain>/<owner>/<repo>.git. The setting defaults tofalse, so existing installations do not showgit://clone URLs unless administrators explicitly enable it.This keeps the scope to the clone URL surface and does not start, configure, or manage a git daemon.
Link to the issue: #1929
Checklist
Test plan
go test ./internal/conf ./internal/repox ./internal/context -count=1go test ./internal/database -run Test_CreateRepository_PreventDeletion -count=1node --check public/js/gogs.jsgit diff --check