]> git.ipfire.org Git - thirdparty/git.git/commit - setup.c
setup: adopt shared init-db & clone code
authorElijah Newren <newren@gmail.com>
Tue, 16 May 2023 06:33:44 +0000 (06:33 +0000)
committerJunio C Hamano <gitster@pobox.com>
Wed, 21 Jun 2023 20:39:53 +0000 (13:39 -0700)
commite8cf8ef5075d7805846f0f7159f8d072b07e588e
treeb69f575968eeff49cb682502e5687e1587f6374c
parentfc8173505703a08bea5c648f1ab286013c3fd730
setup: adopt shared init-db & clone code

The functions init_db() and initialize_repository_version() were shared
by builtin/init-db.c and builtin/clone.c, and declared in cache.h.

Move these functions, plus their several helpers only used by these
functions, to setup.[ch].

Diff best viewed with `--color-moved`.

Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile
builtin/init-db.c
cache.h
setup.c
setup.h