public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: "Kristoffer Haugsbakk" <kristofferhaugsbakk@fastmail•com>
To: "Patrick Steinhardt" <ps@pks•im>, git@vger•kernel.org
Subject: Re: [PATCH 2/2] builtin/init-db: deprecate alias for git-init(1)
Date: Mon, 01 Jun 2026 11:31:46 +0200	[thread overview]
Message-ID: <276a92ac-b2cb-4a89-96d0-9071ab6200be@app.fastmail.com> (raw)
In-Reply-To: <20260601-pks-deprecate-git-init-db-v1-2-ea3e6eebe674@pks.im>

On Mon, Jun 1, 2026, at 09:56, Patrick Steinhardt wrote:
> The git-init-db(1) command was initially only initializing the object
> database of a Git repository. This has changed over time so that the
> command also initializes all the other data structures, which is why we
> have eventually introduced git-init(1) as a more aptly named replacement
> for it.
>
> This has all happened in 2007 already, and with 5c94f87e6b (use 'init'
> instead of 'init-db' for shipped docs and tools, 2007-01-12) we have
> also adapted all user-facing documentation to mention the replacement.
> It is thus safe to assume that (almost) nobody uses git-init-db(1)
> nowadays anymore.
>
> Deprecate the command in favor of git-init(1) and wire up the removal
> when compiling Git with breaking changes enabled.
>
> Signed-off-by: Patrick Steinhardt <ps@pks•im>
> ---
>[snip]
> diff --git a/git.c b/git.c
> index a72394b599..6bf6a60360 100644
> --- a/git.c
> +++ b/git.c
> @@ -591,7 +591,9 @@ static struct cmd_struct commands[] = {
>  	{ "hook", cmd_hook, RUN_SETUP_GENTLY },
>  	{ "index-pack", cmd_index_pack, RUN_SETUP_GENTLY | NO_PARSEOPT },
>  	{ "init", cmd_init },
> +#ifndef WITH_BREAKING_CHANGES
>  	{ "init-db", cmd_init },

This can be marked as deprecated.

	{ "init-db", cmd_init, DEPRECATED },

> +#endif
>  	{ "interpret-trailers", cmd_interpret_trailers, RUN_SETUP_GENTLY },
>  	{ "last-modified", cmd_last_modified, RUN_SETUP },
>  	{ "log", cmd_log, RUN_SETUP },
>[snip]

  reply	other threads:[~2026-06-01  9:32 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-01  7:55 [PATCH 0/2] Deprecate git-init-db(1) alias Patrick Steinhardt
2026-06-01  7:55 ` [PATCH 1/2] builtin/init-db: rename to "builtin/init.c" Patrick Steinhardt
2026-06-01  7:56 ` [PATCH 2/2] builtin/init-db: deprecate alias for git-init(1) Patrick Steinhardt
2026-06-01  9:31   ` Kristoffer Haugsbakk [this message]
2026-06-01 12:10     ` Patrick Steinhardt
2026-06-01 13:48       ` Phillip Wood
2026-06-01 14:20         ` Patrick Steinhardt
2026-06-01 21:23           ` Kristoffer Haugsbakk
2026-06-01 22:22             ` Junio C Hamano
2026-06-02  6:45               ` Patrick Steinhardt
2026-06-02  7:54                 ` Kristoffer Haugsbakk
2026-06-02 12:34                   ` Patrick Steinhardt
2026-06-02  8:27                 ` Junio C Hamano
2026-06-02 12:34                   ` Patrick Steinhardt
2026-06-02 13:12                     ` Phillip Wood
2026-06-02 14:58                       ` Patrick Steinhardt
2026-06-02 15:24                     ` SZEDER Gábor
2026-06-01 22:18           ` Junio C Hamano
2026-06-02 13:09           ` Phillip Wood
2026-06-02 13:50             ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=276a92ac-b2cb-4a89-96d0-9071ab6200be@app.fastmail.com \
    --to=kristofferhaugsbakk@fastmail$(echo .)com \
    --cc=git@vger$(echo .)kernel.org \
    --cc=ps@pks$(echo .)im \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox