From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <bug-guix-bounces+larch=yhetil.org@gnu.org>
Received: from mp12.migadu.com ([2001:41d0:306:2d92::])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	by ms9.migadu.com with LMTPS
	id ILqyCRf5/mQwgQAAauVa8A:P1
	(envelope-from <bug-guix-bounces+larch=yhetil.org@gnu.org>)
	for <larch@yhetil.org>; Mon, 11 Sep 2023 13:25:11 +0200
Received: from aspmx1.migadu.com ([2001:41d0:306:2d92::])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	by mp12.migadu.com with LMTPS
	id ILqyCRf5/mQwgQAAauVa8A
	(envelope-from <bug-guix-bounces+larch=yhetil.org@gnu.org>)
	for <larch@yhetil.org>; Mon, 11 Sep 2023 13:25:11 +0200
Received: from lists.gnu.org (lists.gnu.org [209.51.188.17])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by aspmx1.migadu.com (Postfix) with ESMTPS id 54ADC354DE
	for <larch@yhetil.org>; Mon, 11 Sep 2023 13:25:10 +0200 (CEST)
Authentication-Results: aspmx1.migadu.com;
	dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20221208 header.b=G+mlTAwX;
	spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org";
	dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none)
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org;
	s=key1; t=1694431510;
	h=from:from:sender:sender:reply-to:subject:subject:date:date:
	 message-id:message-id:to:to:cc:cc:mime-version:mime-version:
	 content-type:content-type:
	 content-transfer-encoding:content-transfer-encoding:resent-cc:
	 resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to:
	 references:references:list-id:list-help:list-unsubscribe:
	 list-subscribe:list-post:dkim-signature;
	bh=C8OuW9Kc/Bl4fezquUaFGZUMX86ENwX4OYueChGdRGI=;
	b=RqWF9tDP3L3NUyLFBB0owvxMNQd7d2p1zD1rZg+kSwJo4vQje9CJ3wXCRIusjTGdK8h0vt
	SPFlby585+Hv30H/ZSMimDS/Z9JR2KJOfJLGxsMiBLJVk0wjSh/vq9l0VHwAfzypBl5fKj
	IOzc0sZ+lD2FGPBlRnfP76zjv0X0QUekZ36BIWkBZbxG8Qao7mRssWmjn/jo/r+5WCsRQq
	nVKFlvJOu3lOeVCQEZ0PncA5oPIW1ruWyUMMCfNKlm+7oAuouBdWZr/R3/yWTA14f6NC/9
	Cqod5ZqfnOZRs4GpowZqgEL8Dl7dPaO3U2iyOjX+uThdCM8hS+loERKW3nsm9Q==
ARC-Seal: i=1; s=key1; d=yhetil.org; t=1694431510; a=rsa-sha256; cv=none;
	b=Xn3njwOuVnxqzONURkU2gQYuaUHzdAcDbsO+awf1cF2Zka1Kik2mnT4aAqS97G5PopBrDq
	kQgN0YISz5w3ZBq2RktYP+ua6vP9m4EH72vUhjJxM4ouAAm71/TEDeCFXcRELcPOUhSP3r
	JRTGEdKY5pjpWxLxaECjT5Em7TV1h7mMTU2iUkosdXuBvP6+I5MwSF3PopK/er2Rge2ksG
	JLxaqkLxbgsz98w84BeOzsK01AuXrkqC4ViSkV4ydq7Oy5n0dzeeKdhe/gGkjQnpdTbk+G
	wM5yamnvaJ7jFWcrNQsexcNR1zAs7tntGdv929j0PfeA8/8tyfCkx5gFj8r17Q==
ARC-Authentication-Results: i=1;
	aspmx1.migadu.com;
	dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20221208 header.b=G+mlTAwX;
	spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org";
	dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none)
Received: from localhost ([::1] helo=lists1p.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.90_1)
	(envelope-from <bug-guix-bounces@gnu.org>)
	id 1qff2L-000605-0r; Mon, 11 Sep 2023 07:25:01 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10])
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>)
 id 1qff2J-0005ws-DJ
 for bug-guix@gnu.org; Mon, 11 Sep 2023 07:24:59 -0400
Received: from debbugs.gnu.org ([2001:470:142:5::43])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>)
 id 1qff2J-0006zP-1W
 for bug-guix@gnu.org; Mon, 11 Sep 2023 07:24:59 -0400
Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2)
 (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1qff2M-0007Sb-Lo
 for bug-guix@gnu.org; Mon, 11 Sep 2023 07:25:02 -0400
X-Loop: help-debbugs@gnu.org
Subject: bug#65720: Digression about Git implementations (was Re: bug#65720:
 Guile-Git-managed checkouts grow way too much)
Resent-From: Simon Tournier <zimon.toutoune@gmail.com>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org>
Resent-CC: bug-guix@gnu.org
Resent-Date: Mon, 11 Sep 2023 11:25:02 +0000
Resent-Message-ID: <handler.65720.B65720.169443145628622@debbugs.gnu.org>
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 65720
X-GNU-PR-Package: guix
X-GNU-PR-Keywords: 
To: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludo@gnu.org>,
 Josselin Poiret <dev@jpoiret.xyz>
Cc: 65720@debbugs.gnu.org
Received: via spool by 65720-submit@debbugs.gnu.org id=B65720.169443145628622
 (code B ref 65720); Mon, 11 Sep 2023 11:25:02 +0000
Received: (at 65720) by debbugs.gnu.org; 11 Sep 2023 11:24:16 +0000
Received: from localhost ([127.0.0.1]:52246 helo=debbugs.gnu.org)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <debbugs-submit-bounces@debbugs.gnu.org>)
 id 1qff1c-0007RU-4b
 for submit@debbugs.gnu.org; Mon, 11 Sep 2023 07:24:16 -0400
Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]:39077)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <zimon.toutoune@gmail.com>) id 1qff1W-0007R6-O6
 for 65720@debbugs.gnu.org; Mon, 11 Sep 2023 07:24:14 -0400
Received: by mail-wr1-x433.google.com with SMTP id
 ffacd0b85a97d-31f2ab21231so655497f8f.0
 for <65720@debbugs.gnu.org>; Mon, 11 Sep 2023 04:24:06 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20221208; t=1694431441; x=1695036241; darn=debbugs.gnu.org;
 h=content-transfer-encoding:mime-version:message-id:date:references
 :in-reply-to:subject:cc:to:from:from:to:cc:subject:date:message-id
 :reply-to; bh=C8OuW9Kc/Bl4fezquUaFGZUMX86ENwX4OYueChGdRGI=;
 b=G+mlTAwXUNAeLYJ36WBqUOa6RNy4wwHwiL02IEmXpKmxWM+rI3zX8zorKnI0iCmofH
 69zmMk718qaaLe8gO1naMAEIAnNlYKrmuH1C5YFNfLUDgMCHJ3JCWasgiAAgI/sEdGZB
 b6kQ6lnt+K2tTpqT9s6abh3Hzk6jscGlp94y/QTgVjrv6uYiHNvecA1X74Tl5jG9PlRJ
 IvGuFNJKcwOwpxxQktK4vFYqLPu9MwNP+ngOCV6i0FJxa86zKHmfsh2XwKPYSz0tKcfp
 nhUYQO4owx0UoTI7FGF1Ivem7C6YGk1QTNXZSvuQT1yBOTtX95WOxTmczf2wKGLIhauV
 k7VQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1694431441; x=1695036241;
 h=content-transfer-encoding:mime-version:message-id:date:references
 :in-reply-to:subject:cc:to:from:x-gm-message-state:from:to:cc
 :subject:date:message-id:reply-to;
 bh=C8OuW9Kc/Bl4fezquUaFGZUMX86ENwX4OYueChGdRGI=;
 b=Sxn1Ut1/T+hy66up0Sfv6LKq+Oj9goelZ5McDFQg8UTBA4OQ3ecLTbz4ahMvzy8JGw
 hyIymOy2P37+D+wW7Pnht7obN7Tto/irShKQZI+nr+scnGc7m8wbub9LrCkzDqJehQ5+
 ebscD/EEmrnePzVZTmUZe5n55XM7KA0hUy7OK4XTvkyJJNS8hVecHU5kyfcipjMJD/HE
 uvHSWcm4gNDbZYyvlL2SeFJ58hjKqZR32NP6fJWJFQJgqosfEQl+FVaf0ul1Oqo5B5SU
 1au73q8LurJZQLNVFjfEE4B5tPL0AMKC1pJTfFARZqv7L6Zq21nfoCzYoadHl+mgcaeI
 kdbg==
X-Gm-Message-State: AOJu0YzPmYPBsjV1a6vkp6iiDxAepvWYuDuhyzQgJSQ4ellq82y/s9GR
 3DI9cIl4lzxXJ/asgT1lCSAcFvr1PqM=
X-Google-Smtp-Source: AGHT+IEm53aH9z6OxtH/I6npDph9yH7BvLZyuJ9ib2+pNIYApogUVArOxNt9CXz3Y8I58fR/1FfdBQ==
X-Received: by 2002:a5d:5707:0:b0:317:3da0:7606 with SMTP id
 a7-20020a5d5707000000b003173da07606mr7133550wrv.4.1694431440677; 
 Mon, 11 Sep 2023 04:24:00 -0700 (PDT)
Received: from pfiuh07 ([193.48.40.241]) by smtp.gmail.com with ESMTPSA id
 y19-20020a05600c365300b003fef5e76f2csm3498262wmq.0.2023.09.11.04.24.00
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Mon, 11 Sep 2023 04:24:00 -0700 (PDT)
From: Simon Tournier <zimon.toutoune@gmail.com>
In-Reply-To: <87pm2s385m.fsf@gnu.org>
References: <87bkejc7go.fsf@inria.fr> <87fs3tobju.fsf@gnu.org>
 <87tts9uj6x.fsf@jpoiret.xyz> <87msy0ln4m.fsf@gnu.org>
 <87pm2vvibo.fsf@jpoiret.xyz> <87pm2s385m.fsf@gnu.org>
Date: Mon, 11 Sep 2023 10:42:35 +0200
Message-ID: <87zg1tje2s.fsf@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
X-BeenThere: bug-guix@gnu.org
List-Id: Bug reports for GNU Guix <bug-guix.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-guix>,
 <mailto:bug-guix-request@gnu.org?subject=unsubscribe>
List-Archive: <https://lists.gnu.org/archive/html/bug-guix>
List-Post: <mailto:bug-guix@gnu.org>
List-Help: <mailto:bug-guix-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-guix>,
 <mailto:bug-guix-request@gnu.org?subject=subscribe>
Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org
Sender: bug-guix-bounces+larch=yhetil.org@gnu.org
X-Migadu-Country: US
X-Migadu-Flow: FLOW_IN
X-Migadu-Scanner: mx2.migadu.com
X-Spam-Score: -3.79
X-Migadu-Queue-Id: 54ADC354DE
X-Migadu-Spam-Score: -3.79
X-TUID: Oz5YfrmcLByj

Hi Ludo,

On Fri, 08 Sep 2023 at 19:08, Ludovic Court=C3=A8s <ludo@gnu.org> wrote:

> Years ago, Andy Wingo sketched a plan for GNU hackers to implement Git
> in pure Scheme.  That was on April 1st though, so people mistakenly
> assumed it was a joke and the project was never carried out.

Well, that is a piece of work. :-)

Maybe there is an hope with: git-std-lib.

    Subject: Proposal/Discussion: Turning parts of Git into libraries
    From: Emily Shaffer <nasamuffin@google.com>
    To: Git List <git@vger.kernel.org>
    Date: Fri, 17 Feb 2023 13:12:23 -0800=09=20=20=20=20
    https://lore.kernel.org/git/CAJoAoZ=3DCig_kLocxKGax31sU7Xe4=3D=3DBGzC__=
Bg2_pr7krNq6MA@mail.gmail.com/

And some patches are starting to float around.
https://public-inbox.org/git/20230810163346.274132-1-calvinwan@google.com/


> I digress, but I wonder: is there not even a viable Haskell or OCaml
> implementation of Git?

It depends on what means =E2=80=9Cviable=E2=80=9D. :-)

https://github.com/mirage/ocaml-git
https://hackage.haskell.org/package/git

Irmin [1] is an OCaml library for building mergeable, branchable
distributed data stores =E2=80=93 A Distributed Database Built on the Same
Principles as Git.  And irmin relies on ocaml-git.

1: https://github.com/mirage/irmin

Then there is a pure Go implementation and another using Java.

https://git-scm.com/book/en/v2/Appendix-B%3A-Embedding-Git-in-your-Applicat=
ions-go-git
https://git-scm.com/book/en/v2/Appendix-B%3A-Embedding-Git-in-your-Applicat=
ions-JGit

I do not know all that are =E2=80=9Cviable=E2=80=9D.  Well, I do not know i=
f =E2=80=99git gc=E2=80=99 is
implemented.  And I do not know which plumbing is implemented and which
porcelain is available.

Last, SWH uses dulwich [2] which is a pure Python implementation of Git.

2: https://www.dulwich.io/

To my knowledge, there is no =E2=80=9Cdulwich gc=E2=80=9D but they implemen=
t =E2=80=9Cdulwich
fsck=E2=80=9D and =E2=80=9Cdulwich repack=E2=80=9D.

Back on 10 Years of Guix or at UNESCO on February =E2=80=93 I do not rememb=
er
exactly when =E2=80=93 we were discussing about implementation of Git.  And=
 we
mentioned an implementation in Rust.  Maybe this one:

https://github.com/Byron/gitoxide

Cheers,
simon