git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Avoid double-slash in path names that depend on $(sharedir).

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 11, 2007, 08:18 UTC
Message-ID
<7v645usy4c.fsf@assigned-by-dhcp.pobox.com>
In-Reply-To
<11815489372169-git-send-email-johannes.sixt@telecom.at>
Johannes Sixt <johannes.sixt@telecom.at> writes:
Show 13 quoted lines
> diff --git a/Makefile b/Makefile
> index af84af9..c23031c 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -144,7 +144,7 @@ STRIP ?= strip
>  prefix = $(HOME)
>  bindir = $(prefix)/bin
>  gitexecdir = $(bindir)
> -sharedir = $(prefix)/share/
> +sharedir = $(prefix)/share
>  template_dir = $(sharedir)/git-core/templates/
>  ifeq ($(prefix),/usr)
>  sysconfdir = /etc

This suggests that we would also want to drop the trailing slash from template_dir, doesn't it?

I took a brief look at builtin-init-db.c but it seems that the code is safe with or without the trailing slash there.

Previous: Johannes SixtNext: Johannes Sixt
Message 2 of 3 in “Avoid double-slash in path names that depend on $(sharedir).”
  1. Avoid double-slash in path names that depend on $(sharedir).Johannes Sixt, Jun 11, 2007
  2. Junio C HamanoJun 11, 2007
  3. Johannes SixtJun 11, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.