From: Junio C Hamano <gitster@pobox.com>
To: Todd Zullinger <tmz@pobox.com>
Cc: Akshay Hegde <lists+git@akshay.is>,
git@vger.kernel.org, Patrick Steinhardt <ps@pks.im>
Subject: Re: [PATCH] meson: install shell completion scripts
Date: Wed, 09 Apr 2025 10:42:52 -0700 [thread overview]
Message-ID: <xmqq4iyxs02r.fsf@gitster.g> (raw)
In-Reply-To: <Z_SJSKrUdiWzg4pw@teonanacatl.net> (Todd Zullinger's message of "Mon, 7 Apr 2025 22:26:16 -0400")
Todd Zullinger <tmz@pobox.com> writes:
>> Most people won't run into this since if you have this installed in the
>> standard locations, it should just work, and the zsh script does have
>> logic to look for additional paths it may be under. I just wanted to
>> mention it for info.
>
> I wonder whether it is proper to install the completion
> scripts relative to git's $datadir by default.
>
> I think the default ought to use the pkg-config call to get
> the completionsdir variable, as the zsh completion script
> suggests. I am presuming that's something meson can do
> rather trivially, just as it would do to find the compile
> options for git's various build dependencies?
>
> I don't know if that becomes too messy to be worthwhile when
> determining whether git is being installed by a normal user
> in $HOME or by a privileged user in a system-wide prefix
> like /usr.
Yes, exactly. We left it out of what Makefile does for that exact
reason. Distros will do what is best for their environment, and I
do not think, unlike pkg-config used to figure out distro specific
locations when doing a system-wide install, there is a location that
will make everybody happy in the context of per-user installation.
If we were to install these completion script from make or meson, I
suspect that we'd eventually need a separate make variable or meson
configuration item (whose default value can come from $datadir
unless there is a better setting that already exists in our system)
that is only used to specify the location completion script.
Thanks.
next prev parent reply other threads:[~2025-04-09 17:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-07 7:42 [PATCH] meson: install shell completion scripts Patrick Steinhardt
2025-04-08 0:00 ` Akshay Hegde
2025-04-08 2:26 ` Todd Zullinger
2025-04-09 17:42 ` Junio C Hamano [this message]
2025-04-17 3:58 ` Eli Schwartz
2025-04-17 14:31 ` Junio C Hamano
2025-04-22 8:36 ` Patrick Steinhardt
2025-04-22 8:36 ` [PATCH v2] contrib/completion: install Bash completion Patrick Steinhardt
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=xmqq4iyxs02r.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=lists+git@akshay.is \
--cc=ps@pks.im \
--cc=tmz@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.