]> git.ipfire.org Git - thirdparty/git.git/commit
t5548: refactor to reuse setup_upstream() function
authorJiang Xin <zhiyou.jx@alibaba-inc.com>
Mon, 3 Feb 2025 06:29:32 +0000 (07:29 +0100)
committerJunio C Hamano <gitster@pobox.com>
Mon, 3 Feb 2025 23:24:56 +0000 (15:24 -0800)
commit12ad6b8feaf9dbbe8f040ce8620700cae793708b
tree84cf0f89835b2aaa00a8ed5572bf60f6199acca1
parentb1be3953e5ff5c85853e184d16cb213e8f9c4623
t5548: refactor to reuse setup_upstream() function

Refactor the function setup_upstream_and_workbench(), extracting
create_upstream_template() and setup_upstream() from it. The former is
used to create the upstream repository template, while the latter is
used to rebuild the upstream repository and will be reused in subsequent
commits.

To ensure that setup_upstream() works properly in both local and HTTP
protocols, the HTTP settings have been moved to the setup_upstream() and
setup_upstream_and_workbench() functions.

Signed-off-by: Jiang Xin <zhiyou.jx@alibaba-inc.com>
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t5548-push-porcelain.sh