From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id UJfVOONR+GCCEgEAgWs5BA (envelope-from ) for ; Wed, 21 Jul 2021 18:57:07 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id wIKhNONR+GBQZgAA1q6Kng (envelope-from ) for ; Wed, 21 Jul 2021 16:57:07 +0000 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 9B8446624 for ; Wed, 21 Jul 2021 18:57:07 +0200 (CEST) Received: from localhost ([::1]:58264 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6FWs-0003cx-EJ for larch@yhetil.org; Wed, 21 Jul 2021 12:57:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55188) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6FWo-0003ac-B2 for guix-patches@gnu.org; Wed, 21 Jul 2021 12:57:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:55168) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m6FWo-0007Lz-3G for guix-patches@gnu.org; Wed, 21 Jul 2021 12:57:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m6FWo-0004fX-2i for guix-patches@gnu.org; Wed, 21 Jul 2021 12:57:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#30053] [PATCH 1/3] Improve appearance of tabular output. Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 21 Jul 2021 16:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 30053 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 30053@debbugs.gnu.org, Steve Sprang , Roel Janssen Received: via spool by 30053-submit@debbugs.gnu.org id=B30053.162688660517908 (code B ref 30053); Wed, 21 Jul 2021 16:57:02 +0000 Received: (at 30053) by debbugs.gnu.org; 21 Jul 2021 16:56:45 +0000 Received: from localhost ([127.0.0.1]:38477 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m6FWW-0004em-K5 for submit@debbugs.gnu.org; Wed, 21 Jul 2021 12:56:44 -0400 Received: from eggs.gnu.org ([209.51.188.92]:57314) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m6FWQ-0004eV-Pf for 30053@debbugs.gnu.org; Wed, 21 Jul 2021 12:56:44 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:55754) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6FWL-0006vr-AB; Wed, 21 Jul 2021 12:56:33 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=45276 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6FWK-0008PH-TI; Wed, 21 Jul 2021 12:56:33 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <878td4nksy.fsf@gnu.org> <87fu7b2old.fsf@gnu.org> <87zi5d6g8f.fsf@gnu.org> <87im1cnnjb.fsf_-_@gmail.com> <871r7zcwdr.fsf_-_@gmail.com> Date: Wed, 21 Jul 2021 18:56:30 +0200 In-Reply-To: <871r7zcwdr.fsf_-_@gmail.com> (Maxim Cournoyer's message of "Thu, 15 Jul 2021 13:36:16 -0400") Message-ID: <875yx3fvwh.fsf_-_@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) 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: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1626886627; 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; bh=53LwAC6XEGn3Wi0HofLzu2ZRMYlEU4nQ27z5yhxWmR4=; b=uEN6pL7nS0XD3QqJRF567b9O+G9OsEjBV2E50TzsYEF8xWL4UT8CvNuaHKa7MzL0u2Qc8H +DrEBWhai1bq5P5IVpK7fJ7Qkt9wlRjELHCNMmCL+dyt9nTvqwBvrcSS1EhbV7uBUlGheJ JigPQVd4i5DNkZ+soojw4+SIH2xSuZwlRF68Ht3j6+tSGpt9/7kMi3O5CVK6LrVcgWfB4K Awxg1MghgviN30G0laIprWlqvyg4Y3Sf1FUwFz1kzxW0yxJ1WoImSKs0nNb7UUxzFT1m/Q bikeR/22bCIBKk6AwmJ8nM0iaEWfuPYRHNi+kx0++6+J89e9j/ltKjAQwLbr0g== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1626886627; a=rsa-sha256; cv=none; b=SnKRfL4Gi5ld75T2JgnGQl753lYfafyVm/+cm9W49eK0YxsRRxW4ihE9RoyAaifhW5wnex JrAC4SSuYcJKSA/2vOfswOjc9U2fTiegprfZsC2NQ6peR0g7nWAs0K1MGTs4rZ2W9PRuKb dtk+bUMHR8C32YlHWNmYYaZBATmP8o7Y3tquP1cS5s33r1apADe0qL+PMGHp6dzfEuGGNa BeI9WbniROkNsOgX9rFktgnAdOdrE94t4vIJn1ZpVggtl123IpeG0LGMxOM4rgLYeJ9E3O zzgPmxKZUbCc7psw1ZHfAOXeGrNK6rTOPir+7B4pY8qODav4/MDAq5BNTgYs8w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -1.41 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 9B8446624 X-Spam-Score: -1.41 X-Migadu-Scanner: scn0.migadu.com X-TUID: 4T2GDF7X52+V Hi Maxim and all, Thank you for unlocking this old patch series. :-) Maxim Cournoyer skribis: >>>From d8fd6c9a1b8677cd69e50fe4f3e50c60c5fb7e35 Mon Sep 17 00:00:00 2001 > From: Steve Sprang > Date: Tue, 9 Jan 2018 14:00:11 -0800 > Subject: [PATCH] utils: Add a procedure for pretty printing tabular data. > > * guix/utils.scm (pretty-print-table): New procedure. > > Co-authored-by: Maxim Cournoyer > Signed-off-by: Maxim Cournoyer [...] > +(define* (pretty-print-table rows #:key (max-column-width 20)) > + "Print ROWS in neat columns. All rows should be lists of strings and = each > +row should have the same length. The columns are separated by a tab > +character, and aligned using spaces. The maximum width of each column is > +bound by MAX-COLUMN-WIDTH." The version that was pushed has: (setvbuf (current-output-port) 'block) I=E2=80=99m in favor of removing it because it=E2=80=99s =E2=80=9Cimpolite= =E2=80=9D so to speak :-) to have such a side effect buried here. (guix ui) enables line-buffering on startup anyway. Ludo=E2=80=99. PS: Commit 01d7e8c2782f61e741f8beff7888adfbdb61779d shows an incompatibility with some previously-fine uses of =E2=80=98cut=E2=80=99= , but surely that was the price to pay. (An option would be to behave differently depending on whether stdout is a tty or not, but that=E2=80= =99s probably bad style=E2=80=A6)