]> git.ipfire.org Git - thirdparty/git.git/commit
url: move scheme detection to URL header/source
authorMatheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Sat, 2 May 2026 05:28:37 +0000 (05:28 +0000)
committerJunio C Hamano <gitster@pobox.com>
Wed, 6 May 2026 00:48:27 +0000 (09:48 +0900)
commitd48e36a8a23d931e869fbb3156fc95a5732cb061
tree0fbd4b9dde776d3947ab12f93b9b49fb8c85d7e2
parent51fcf73014f542f074a253add5867c24c82c854f
url: move scheme detection to URL header/source

Move enum url_scheme and url_get_scheme()
from connect.c to url.h and url.c
so that other code can identify
a URL's scheme without depending
on connect.c.

No behavior change. url_get_scheme() still dies
on an unrecognized scheme name, with the same
translated message as before.

scheme_name() stays in connect.c
because it has no other callers.

Signed-off-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
connect.c
url.c
url.h