From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.1 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 4740 invoked from network); 30 Dec 2021 21:08:40 -0000 Received: from lists.zx2c4.com (165.227.139.114) by inbox.vuxu.org with ESMTPUTF8; 30 Dec 2021 21:08:40 -0000 Received: by lists.zx2c4.com (OpenSMTPD) with ESMTP id c7bb83fc; Thu, 30 Dec 2021 21:08:25 +0000 (UTC) Return-Path: Received: from mail.kasad.com (mail.kasad.com [2001:19f0:5:46cc:5400:2ff:fed9:9eba]) by lists.zx2c4.com (OpenSMTPD) with ESMTPS id 2ea2a3cc (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO) for ; Thu, 30 Dec 2021 21:08:23 +0000 (UTC) Received: from localhost (unknown [98.37.92.49]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.kasad.com (Postfix) with ESMTPSA id 054F227E1A; Thu, 30 Dec 2021 13:08:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kasad.com; s=mail; t=1640898502; bh=INSt+hAmzMXI9HAKYT1uR7AFkR3qEyxWd+bMYoKYrz0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=bW2bCl8JdlotTg1KOkTh5egvxDq7jaAuz4DjTGC9iKlsnHfK2UjWkKu6BhI18A5bG Ki4UfQk4dl5FFLfw2xOv1h8kfxVyAz7ajRVag5gg4nPH+eGKDw44gVzS+ELCqNPE89 G2aufE7Ask8x9+lS/oZuFnwJRDqSp66opHkgrGjSYnXBfXLoQY1a9uolcfjphRVZf8 In252uTElxxnnGEvFR5s+ZwUsPfi/nfg9vXxc5ZIAh0o2kERrAoPA5QwA9lh5EmE9/ odnkpt3jwbzR3EB0YOmWqaWx2OT2X7nd5kdFG5ISzThZiSncCeEvCwFyS0yhKpo5rT KRYoz2t7EjhwQ== Date: Thu, 30 Dec 2021 13:08:20 -0800 From: Kian Kasad To: John Keeping Cc: cgit@lists.zx2c4.com Subject: Re: User-configurable log graph option Message-ID: <20211230210820.3ncgngexbbhlpbdq@frisbee.local> References: <20210218223126.yrgfjni73fi4rvw4@frisbee> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="sp7axqmy5c5vcq7g" Content-Disposition: inline In-Reply-To: X-BeenThere: cgit@lists.zx2c4.com X-Mailman-Version: 2.1.30rc1 Precedence: list List-Id: List for cgit developers and users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: cgit-bounces@lists.zx2c4.com Sender: "CGit" --sp7axqmy5c5vcq7g Content-Type: text/plain; protected-headers=v1; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: User-configurable log graph option MIME-Version: 1.0 On 21/02/19 12:22PM, John Keeping wrote: > On Thu, Feb 18, 2021 at 02:31:26PM -0800, Kian Kasad wrote: > > I'm using cgit on my website and I'm wondering if it's possible to allow > > the user (i.e. the person visiting the site) to choose whether or not > > the commit graph is displayed on the log page. > >=20 > > If this isn't currently possible, what do you think about adding such > > functionality? Maybe something like how the diff page lets the user > > choose between a "unified diff" and "ssdiff". >=20 > This sounds like a great new feature! >=20 > I think we still want to allow the administrator to turn the feature > on/off but if it is permitted, then it makes sense to allow the end user > to choose whether or not they want it enabled. Following up on this as I'm finally getting around to implementing this feature. I'm not too familiar with CGit's codebase, so I think it would be easier to implement this as a separate "graph" page which is identical to the log page except that it always displays a graph. This graph page would only be shown in the navbar's tab list if the "enable-commit-graph" option is set to "separate" in the configuration. If it is set to "combined" then the graph page will be disabled and the commit graph will be displayed on the log page as it currently is when the "enable-commit-graph" option is set to "1". In order to maintain backwards compatibility, the value "1" could also be interpreted as the value "combined" since it has the same functionality currently. The value "none" (or "0" for backwards compatibility) would disable the graph page as well as disabling the commit graph on the log page. I've already started working on this as I want it for my own CGit site. If this is something that the maintainer(s) want to integrate, I'll send patches when I'm done. -- Kian Kasad PGP 0x1715EEAA14DAEC1 --sp7axqmy5c5vcq7g Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRrgCQ5gHlZM+2U6fU7QHlES2ZOcgUCYc4fwgAKCRA7QHlES2ZO cjREAQDQRbkvNIbLzDS2bVbzQ0XpgYEieR/EL4z36XEWuBMkfAD8C67liGXDegsE tsqBjKtodBv8V1b1x9PY+M/TGzUgfQs= =EITx -----END PGP SIGNATURE----- --sp7axqmy5c5vcq7g--