From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Mon, 16 Nov 2020 01:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 44675@debbugs.gnu.org X-Debbugs-Original-To: bug-guix@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.160549164725735 (code B ref -1); Mon, 16 Nov 2020 01:55:01 +0000 Received: (at submit) by debbugs.gnu.org; 16 Nov 2020 01:54:07 +0000 Received: from localhost ([127.0.0.1]:54680 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keTiZ-0006h1-0h for submit@debbugs.gnu.org; Sun, 15 Nov 2020 20:54:07 -0500 Received: from lists.gnu.org ([209.51.188.17]:45320) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keTiV-0006gp-Ma for submit@debbugs.gnu.org; Sun, 15 Nov 2020 20:54:06 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:50756) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1keTiT-00084g-SY for bug-guix@gnu.org; Sun, 15 Nov 2020 20:54:03 -0500 Received: from cascadia.aikidev.net ([173.255.214.101]:60544) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1keTiR-0005jG-Ng for bug-guix@gnu.org; Sun, 15 Nov 2020 20:54:01 -0500 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id F08D61AA41 for ; Sun, 15 Nov 2020 17:53:56 -0800 (PST) From: Vagrant Cascadian Date: Sun, 15 Nov 2020 17:53:53 -0800 Message-ID: <87ima6rrri.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Received-SPF: none client-ip=173.255.214.101; envelope-from=vagrant@debian.org; helo=cascadia.aikidev.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/15 20:53:57 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain Please consider a guix lint description/synopsis check for basic spelling, typo and rudimentary grammar issues. Most of the ones I've found were caught by debian's "lintian" tool: https://tracker.debian.org/lintian Common issues appear to be: "This packages" -> "This package" "allows to X" -> "Xs" or "Xing" I've fixed many of these in the past: git log --author=vagrant --extended-regexp --grep='spelling|typo|grammar' --patch But some of the very same patterns keep reappearing! Many of these are likely to be caught by most spell checking routines; I'm not sure if there is anything that would be implementable in pure guile, or it if would make sense to call out to an external spellchecker. Some of them might be harder, and obviously we do not want too many false positives, but no need to get perfectionist on solving this; even just checking for "This packages" would haved detected many of these issues! That is, of course, if "guix lint" is being used consistently... :) live well, vagrant --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCX7HbsQAKCRDcUY/If5cW qkGNAP9k5PHKWQUAar5lQzxIfjyZkqBArCd2xtcWvgAtrofqrgD+Prxswpjl9TST rnfFB5SnKII3Ytwftt5aM5WHpw5BJQY= =7RdI -----END PGP SIGNATURE----- --=-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Mon, 16 Nov 2020 06:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Vagrant Cascadian , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.160550668017996 (code B ref 44675); Mon, 16 Nov 2020 06:05:01 +0000 Received: (at 44675) by debbugs.gnu.org; 16 Nov 2020 06:04:40 +0000 Received: from localhost ([127.0.0.1]:54823 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keXd2-0004gC-3j for submit@debbugs.gnu.org; Mon, 16 Nov 2020 01:04:40 -0500 Received: from mail-wr1-f45.google.com ([209.85.221.45]:38383) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keXcy-0004fy-4B for 44675@debbugs.gnu.org; Mon, 16 Nov 2020 01:04:39 -0500 Received: by mail-wr1-f45.google.com with SMTP id p8so17354885wrx.5 for <44675@debbugs.gnu.org>; Sun, 15 Nov 2020 22:04:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:in-reply-to:references:date:message-id:mime-version :content-transfer-encoding; bh=bxrKptiez7BxNpnnBdVB4EZHIFU7lLn9YJVb8npsoh0=; b=tfVfqnvTj94t+onBHzK4B6SqspigZ/6/2fvtq7MOF94IG9dDo3N4gluFh/qPcNnfig bK3kWcXDvPDHSAiWMQfthoz2wuyXZ3Ar9X+OORUIcu5lt0HxP1DZxXtvZSvv1SAjbQx8 XJvfFXeoh3kk9GniZOYhZk8gR/oh6LX6xU2KXR7tCvDD7tUeo5VADqLw7QApISCYMTJm w/SM0TtBLpKYw9oO3pBIZF9WCpn2TKyoJbMiFqYvfXM6q/gFLEUI6Ip3mvTE9N4SCLXL OmYISO2r+nOAg9p0kqXTIO7OxlfDlUzJOuns8zidU2CB5dfnLroSTIBjvqNd3/bo2K22 mcpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=bxrKptiez7BxNpnnBdVB4EZHIFU7lLn9YJVb8npsoh0=; b=O5YmD/vEylC96aSwy32hUGWbRsp1pncz5M2VvwBCOeZaKPPs8BtKmpYh69bVZuwkzw stPgKIAviSJoYK5ePwWhOCgtajHEIkePV22ll1LHrgoyY17DAluMbZUCn17+xTLrEBKi ojXez/YNup/myoImX0arcWcZcFiSxUfOtvTRqi/nsJ28B6PB6Esl8YdK61sXpMyrLT3X 7pUvVv0tP00/MMjxev+wW+GN9VXFLL115ot/ome2Hp979373CiVrWAYCvxgdPzHPt/Rb Q5oBM4VsQ3Ky4WL+dIzN+meh4jajndMoiU6+qBrf10e0AdqwVp7zrAWvtTa3bC/gVUEw oMAA== X-Gm-Message-State: AOAM533jR3ioXCHMsSAmSn7R5Dt8rczwJLUb6Ion6830DSZSzjfLF1Ft kXWmWGDgPj7bwugEsq/mKTf4hiljD31Kdg== X-Google-Smtp-Source: ABdhPJw4HHSOninYh/1yaNbZSnPqRRURTBzkvNR98Ihg2ZeXF9yAsQUEpzrDmzuSLKzsewTNg9/N9w== X-Received: by 2002:a5d:56c7:: with SMTP id m7mr18537916wrw.201.1605506668949; Sun, 15 Nov 2020 22:04:28 -0800 (PST) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id i5sm22975035wrw.45.2020.11.15.22.04.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 15 Nov 2020 22:04:28 -0800 (PST) From: zimoun In-Reply-To: <87ima6rrri.fsf@yucca> References: <87ima6rrri.fsf@yucca> Date: Mon, 16 Nov 2020 06:55:44 +0100 Message-ID: <868sb1u9pb.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Vagrant, On Sun, 15 Nov 2020 at 17:53, Vagrant Cascadian wrote: > Please consider a guix lint description/synopsis check for basic > spelling, typo and rudimentary grammar issues. > > Most of the ones I've found were caught by debian's "lintian" tool: > > https://tracker.debian.org/lintian [...] > Many of these are likely to be caught by most spell checking routines; > I'm not sure if there is anything that would be implementable in pure > guile, or it if would make sense to call out to an external > spellchecker. The tool is =E2=80=99spellintian=E2=80=99 [1], right? If yes, the work see= ms done by [2] but I am not sure to understand if it is only regexp and Perl or if an external tool is called. And the list in debian/control is not very helpful. 1: https://salsa.debian.org/lintian/lintian/-/blob/master/bin/spellintian 2: https://salsa.debian.org/lintian/lintian/-/blob/master/lib/Lintian/Spelling= .pm=20 > That is, of course, if "guix lint" is being used consistently... :) It should be! :-) All the best, simon From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 03 12:06:49 2020 Received: (at control) by debbugs.gnu.org; 3 Dec 2020 17:06:49 +0000 Received: from localhost ([127.0.0.1]:41605 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kks49-000518-Jg for submit@debbugs.gnu.org; Thu, 03 Dec 2020 12:06:49 -0500 Received: from eggs.gnu.org ([209.51.188.92]:60696) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kks47-00050u-8n for control@debbugs.gnu.org; Thu, 03 Dec 2020 12:06:47 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47254) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kks42-00068y-55 for control@debbugs.gnu.org; Thu, 03 Dec 2020 12:06:42 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=51452 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kks40-0000n5-6e for control@debbugs.gnu.org; Thu, 03 Dec 2020 12:06:42 -0500 Date: Thu, 03 Dec 2020 18:06:39 +0100 Message-Id: <87360mddk0.fsf@gnu.org> To: control@debbugs.gnu.org From: =?utf-8?Q?Ludovic_Court=C3=A8s?= Subject: control message for bug #44675 MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) tags 44675 + easy quit From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Wed, 21 Apr 2021 23:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.161904665313754 (code B ref 44675); Wed, 21 Apr 2021 23:11:02 +0000 Received: (at 44675) by debbugs.gnu.org; 21 Apr 2021 23:10:53 +0000 Received: from localhost ([127.0.0.1]:60061 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZLzh-0003Zl-62 for submit@debbugs.gnu.org; Wed, 21 Apr 2021 19:10:53 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:45518) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZLze-0003ZY-DA for 44675@debbugs.gnu.org; Wed, 21 Apr 2021 19:10:52 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id 0A6821AAB4 for <44675@debbugs.gnu.org>; Wed, 21 Apr 2021 16:10:44 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: <87ima6rrri.fsf@yucca> References: <87ima6rrri.fsf@yucca> Date: Wed, 21 Apr 2021 16:10:40 -0700 Message-ID: <87tunznsi7.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Control: tags 44675 +patch On 2020-11-15, Vagrant Cascadian wrote: > Please consider a guix lint description/synopsis check for basic > spelling, typo and rudimentary grammar issues. ... > Many of these are likely to be caught by most spell checking routines; > I'm not sure if there is anything that would be implementable in pure > guile, or it if would make sense to call out to an external > spellchecker. > > Some of them might be harder, and obviously we do not want too many > false positives, but no need to get perfectionist on solving this; even > just checking for "This packages" would haved detected many of these > issues! In the attached patch, I've implemented a simple lint check for "This packages", which has been fixed in ... 42 packages so far in the git repository, so maybe this could help catch future ones! I haven't implemented a more complicated spellchecker or grammar checker or anything, but at least this is a start. I think it is also within my skills to address "allows to" and "permits to", if I'm not heading down the wrong path here... live well, vagrant --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: inline; filename=0001-lint-Add-description-check-for-check-pluralized-pack.patch Content-Transfer-Encoding: quoted-printable From=20d4b851f5722cd6f8d514a4254884d1f7a016b74f Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Wed, 21 Apr 2021 09:26:45 -0700 Subject: [PATCH] lint: Add description check for check-pluralized-package Fixes: https://issues.guix.gnu.org/44675 * guix/lint.scm: Check for occurances of "This packages" in package descriptions. * tests/lint.scm: Add test. =2D-- guix/lint.scm | 9 +++++++++ tests/lint.scm | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/guix/lint.scm b/guix/lint.scm index 1bebfe03d3..ffeac18077 100644 =2D-- a/guix/lint.scm +++ b/guix/lint.scm @@ -221,6 +221,14 @@ markup is valid return a plain-text version of DESCRIP= TION, otherwise #f." (G_ "Texinfo markup in description is invalid") #:field 'description)))) =20 + (define (check-pluralized-this-package description) + "Check that DESCRIPTION does not contain This packages" + (if (string-match "This packages" description) + (list + (make-warning package + (G_ "description contains This Packages but should just be This p= ackage"))) + '())) + (define (check-trademarks description) "Check that DESCRIPTION does not contain '=E2=84=A2' or '=C2=AE' chara= cters. See http://www.gnu.org/prep/standards/html_node/Trademarks.html." @@ -283,6 +291,7 @@ by two spaces; possible infraction~p at ~{~a~^, ~}") (check-not-empty description) (check-quotes description) (check-trademarks description) + (check-pluralized-this-package description) ;; Use raw description for this because Texinfo rendering ;; automatically fixes end of sentence space. (check-end-of-sentence-space description) diff --git a/tests/lint.scm b/tests/lint.scm index a2c8665142..6cb7a98686 100644 =2D-- a/tests/lint.scm +++ b/tests/lint.scm @@ -160,6 +160,13 @@ (description "This is a 'quoted' thing.")))) (check-description-style pkg)))) =20 +(test-equal "description: pluralized this package" + "description contains This Packages but should just be This package" + (single-lint-warning-message + (let ((pkg (dummy-package "x" + (description "This packages is a typo.")))) + (check-description-style pkg)))) + (test-equal "synopsis: not a string" "invalid synopsis: #f" (single-lint-warning-message =2D-=20 2.30.2 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYICw8AAKCRDcUY/If5cW ql31AQDhw/mVDLHlM7VAiztoP8oGG+hY2Zkmksac+kaAFKTEiQD9Gmi+llqfzsUz 2rP03GAKD8s9BKyuMDu9havpzQXHpAo= =M7KV -----END PGP SIGNATURE----- --==-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 22 Apr 2021 16:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Vagrant Cascadian , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.161910974722781 (code B ref 44675); Thu, 22 Apr 2021 16:43:02 +0000 Received: (at 44675) by debbugs.gnu.org; 22 Apr 2021 16:42:27 +0000 Received: from localhost ([127.0.0.1]:35404 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZcPL-0005vN-De for submit@debbugs.gnu.org; Thu, 22 Apr 2021 12:42:27 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:38114) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZcPJ-0005vD-Au for 44675@debbugs.gnu.org; Thu, 22 Apr 2021 12:42:26 -0400 Received: from ptr-bvsjgyjmffd7q9timvx.18120a2.ip6.access.telenet.be ([IPv6:2a02:1811:8c09:9d00:aaf1:9810:a0b8:a55d]) by michel.telenet-ops.be with bizsmtp id vsiP2400Z0mfAB406siPkm; Thu, 22 Apr 2021 18:42:24 +0200 Message-ID: <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> From: Maxime Devos Date: Thu, 22 Apr 2021 18:42:23 +0200 In-Reply-To: <87tunznsi7.fsf@yucca> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-EVvT3TpiFMe2R7njijlE" User-Agent: Evolution 3.34.2 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r21; t=1619109744; bh=mPAUGHfjZSbW87hQOfSHHIIb+Q2vsc9bqlBthK0xLbs=; h=Subject:From:To:Date:In-Reply-To:References; b=IAQ3+iojzMYWJOq9sqltbFZUdEby7A1YjNN82LHPDvnjM7E/1wRLENhlyhTcOPbuK nHvmwLD9gLIA8KX4yzN/UscdpphSN6Nzsf6zfHTUOw23IBbH2hCDHXDr0hLYohZIs4 HCkDSOa23txGjxDpHk/8AP7iONYP5SNlZ1Hc5H9KO4Kgrmr4rRenRaZhMhLiS2Q3s1 eX2Ulzj/IKfocioUpomu+omjWJuL91+L5L2K1ZdBDJ28gZBLCWj7fqRAaBJ4lGv7jO 0AN6477fT/DU3BuJhaKkreQkOjh9BRtq+smxhit+m5RlJrbtaALx3fZ6xlJ8N1xH1T IkUeED8zweGRA== X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-EVvT3TpiFMe2R7njijlE Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable + (define (check-pluralized-this-package description) + "Check that DESCRIPTION does not contain This packages" The sentence structure would be clearer if you used quotes here, something like "Check that DESCRIPTION does not contain =E2=80=98This packa= ges=E2=80=99". + (if (string-match "This packages" description) + (list + (make-warning package + (G_ "description contains This Packages but should just be This p= ackage"))) There are no package descriptions containing "This Packages". Did you mean "This packages"? =20 > +(test-equal "description: pluralized this package" Quotes: "description: pluralized =E2=80=98this package=E2=80=99". > + "description contains This Packages but should just be This package" Capitalisation error: This Packages --> This packages Also, quotes: "description contains =E2=80=98This packages=E2=80=99 but sho= uld just be =E2=80=98This package=E2=80=99". Greetings, Maxime. --=-EVvT3TpiFMe2R7njijlE Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYIGnbxccbWF4aW1lZGV2 b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7pxIAP4xHGk1slA5mIN7UDipnEXShvCc r2MyB+hdGP3FeD5GVAD5AUDkrtMMqNir0cYacA/mlJz/l0L6sQyOG2MF0yP1TQY= =s0SE -----END PGP SIGNATURE----- --=-EVvT3TpiFMe2R7njijlE-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 22 Apr 2021 17:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Maxime Devos , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.161911430229824 (code B ref 44675); Thu, 22 Apr 2021 17:59:02 +0000 Received: (at 44675) by debbugs.gnu.org; 22 Apr 2021 17:58:22 +0000 Received: from localhost ([127.0.0.1]:35479 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZdao-0007ky-3e for submit@debbugs.gnu.org; Thu, 22 Apr 2021 13:58:22 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:49642) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZdak-0007ki-4Z for 44675@debbugs.gnu.org; Thu, 22 Apr 2021 13:58:20 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id 6B80E1AF0F; Thu, 22 Apr 2021 10:58:11 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> Date: Thu, 22 Apr 2021 10:57:56 -0700 Message-ID: <87o8e6nqvv.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 2021-04-22, Maxime Devos wrote: > + (define (check-pluralized-this-package description) > + "Check that DESCRIPTION does not contain This packages" > > The sentence structure would be clearer if you used quotes here, > something like "Check that DESCRIPTION does not contain =E2=80=98This pac= kages=E2=80=99". Any compelling reason to use =E2=80=98This packages=E2=80=99 vs. 'This pack= ages' ? It seems other quotes in guix/lint.scm use '' also, and I'm not apparently skilled enough with a keyboard to generate =E2=80=98=E2=80=99-style quotes.= .. :) > + (if (string-match "This packages" description) > + (list > + (make-warning package > + (G_ "description contains This Packages but should just be This= package"))) > > There are no package descriptions containing "This Packages". > Did you mean "This packages"? Nice catch, thanks! >> +(test-equal "description: pluralized this package" > Quotes: "description: pluralized =E2=80=98this package=E2=80=99". Noted. >> + "description contains This Packages but should just be This package" > Capitalisation error: This Packages --> This packages > Also, quotes: "description contains =E2=80=98This packages=E2=80=99 but s= hould just be =E2=80=98This package=E2=80=99". Again, nice catch! Updated the commit message and incorporated the above suggestions into the updated attached patch. live well, vagrant --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: inline; filename=0001-lint-Add-description-check-for-pluralized-This-packa.patch Content-Transfer-Encoding: quoted-printable From=204e724fbe9815e1c27967b835f08d2259164538ba Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Wed, 21 Apr 2021 09:26:45 -0700 Subject: [PATCH] lint: Add description check for pluralized "This package" Partial fix for: https://issues.guix.gnu.org/44675 * guix/lint.scm (check-pluralized-this-package): Add check for occurances of "This packages" in package descriptions. * tests/lint.scm: Add test. =2D-- guix/lint.scm | 9 +++++++++ tests/lint.scm | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/guix/lint.scm b/guix/lint.scm index 1bebfe03d3..e00048349b 100644 =2D-- a/guix/lint.scm +++ b/guix/lint.scm @@ -221,6 +221,14 @@ markup is valid return a plain-text version of DESCRIP= TION, otherwise #f." (G_ "Texinfo markup in description is invalid") #:field 'description)))) =20 + (define (check-pluralized-this-package description) + "Check that DESCRIPTION does not contain 'This packages'" + (if (string-match "This packages" description) + (list + (make-warning package + (G_ "description contains 'This packages' but should just be 'Thi= s package'"))) + '())) + (define (check-trademarks description) "Check that DESCRIPTION does not contain '=E2=84=A2' or '=C2=AE' chara= cters. See http://www.gnu.org/prep/standards/html_node/Trademarks.html." @@ -283,6 +291,7 @@ by two spaces; possible infraction~p at ~{~a~^, ~}") (check-not-empty description) (check-quotes description) (check-trademarks description) + (check-pluralized-this-package description) ;; Use raw description for this because Texinfo rendering ;; automatically fixes end of sentence space. (check-end-of-sentence-space description) diff --git a/tests/lint.scm b/tests/lint.scm index a2c8665142..3e1b95680a 100644 =2D-- a/tests/lint.scm +++ b/tests/lint.scm @@ -160,6 +160,13 @@ (description "This is a 'quoted' thing.")))) (check-description-style pkg)))) =20 +(test-equal "description: pluralized 'This package'" + "description contains 'This packages' but should just be 'This package'" + (single-lint-warning-message + (let ((pkg (dummy-package "x" + (description "This packages is a typo.")))) + (check-description-style pkg)))) + (test-equal "synopsis: not a string" "invalid synopsis: #f" (single-lint-warning-message =2D-=20 2.30.2 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYIG5JAAKCRDcUY/If5cW qkSZAQCLAsyse5gMhpIQdnBHmq2g75AeRUC7sYA+k2X5YS+pZgD+JWMjxaj/9CAn WYlkeiP/Rviat5RG6a63NTlHq96zUQo= =r0Zx -----END PGP SIGNATURE----- --==-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 22 Apr 2021 18:06:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Vagrant Cascadian , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.161911473330578 (code B ref 44675); Thu, 22 Apr 2021 18:06:01 +0000 Received: (at 44675) by debbugs.gnu.org; 22 Apr 2021 18:05:33 +0000 Received: from localhost ([127.0.0.1]:35485 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZdhk-0007x8-WA for submit@debbugs.gnu.org; Thu, 22 Apr 2021 14:05:33 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:39480) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lZdhh-0007ww-P9 for 44675@debbugs.gnu.org; Thu, 22 Apr 2021 14:05:32 -0400 Received: from ptr-bvsjgyjmffd7q9timvx.18120a2.ip6.access.telenet.be ([IPv6:2a02:1811:8c09:9d00:aaf1:9810:a0b8:a55d]) by michel.telenet-ops.be with bizsmtp id vu5T2400d0mfAB406u5Ut3; Thu, 22 Apr 2021 20:05:28 +0200 Message-ID: <1f1a7b54fce32d0241d9f689e00cf52b5c4d48fd.camel@telenet.be> From: Maxime Devos Date: Thu, 22 Apr 2021 20:05:22 +0200 In-Reply-To: <87o8e6nqvv.fsf@yucca> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-2VIjVyZrhFZYcegwHDxm" User-Agent: Evolution 3.34.2 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r21; t=1619114728; bh=zYYf6WHmIDPN7X8ThRteBXbQnQyvnL4i0T+AEGOwaIs=; h=Subject:From:To:Date:In-Reply-To:References; b=ZB4Apa6BWJAUNhja5D2d27svC9khwFMHJO4EUlhMNKnKCzLY5LA8D0hFODZfutfQK 7acYYdDPKfyHAW/yDDvg4rxzESmx1Itx+jMw+ednonTk482hUOF1xYte1B42fwjBf6 LthKiTYdf9sAy4h9cepsvEmyAcWVRAyz4fegDQEN5gU0iIF2wWlEpjFuC8doks7h2e Bjw5UUPxivhiTJnW7v3aMDlIR/waouPnU4rUwGDrgdnPP6ffnNRrKiEO40ZZfUiCcn l/0kpnAGDNsm4UZJw2nCet/dsoE+OHPiovMJLGFlRvaZ5Oo7wJRf5pLKk2L6JtlP3g 8puwkVtiJ6ZHw== X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-2VIjVyZrhFZYcegwHDxm Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Vagrant Cascadian schreef op do 22-04-2021 om 10:57 [-0700]: > On 2021-04-22, Maxime Devos wrote: > > + (define (check-pluralized-this-package description) > > + "Check that DESCRIPTION does not contain This packages" > >=20 > > The sentence structure would be clearer if you used quotes here, > > something like "Check that DESCRIPTION does not contain =E2=80=98This p= ackages=E2=80=99". >=20 > Any compelling reason to use =E2=80=98This packages=E2=80=99 vs. 'This pa= ckages' ? I find =E2=80=98curly quotes=E2=80=99 more aesthetically pleasing, though t= hat's a bit subjective I guess. > It seems other quotes in guix/lint.scm use '' also, I believe they should use =E2=80=98curly quotes=E2=80=99 as well, though I = would like to hear what other things about that first. > and I'm not apparently > skilled enough with a keyboard to generate =E2=80=98=E2=80=99-style quote= s... :) If your keyboard is azerty, you could choose =E2=80=98Belgian alternative= =E2=80=99, and type =E2=80=98 with alt-gr+f and =E2=80=99 with alt-gr+g. > Updated the commit message and incorporated the above suggestions into > the updated attached patch. One other suggestion: you used "string-match" in 'check-pluralized-this-pac= kage', which is a bit overkill. string-match interprets its first argument as a r= egex. The procedure "string-contains" is simpler and probably more efficient. The patch looks good otherwise. Greetings, Maxime. --=-2VIjVyZrhFZYcegwHDxm Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYIG64hccbWF4aW1lZGV2 b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7s1SAP49qSu0Cb+lpiG9d3u/bp6jldfK 1bFVLabTd1mjvILUgQD+OQQL38Y3qweGxWKqGg2njcvMGu3cDi3mQTz/GkXxzw0= =/QsW -----END PGP SIGNATURE----- --=-2VIjVyZrhFZYcegwHDxm-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Efraim Flashner Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 25 Apr 2021 07:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Vagrant Cascadian Cc: 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.161933570631675 (code B ref 44675); Sun, 25 Apr 2021 07:29:02 +0000 Received: (at 44675) by debbugs.gnu.org; 25 Apr 2021 07:28:26 +0000 Received: from localhost ([127.0.0.1]:41901 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1laZBp-0008Eo-Un for submit@debbugs.gnu.org; Sun, 25 Apr 2021 03:28:26 -0400 Received: from flashner.co.il ([178.62.234.194]:59630) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1laZBl-0008EZ-Kk for 44675@debbugs.gnu.org; Sun, 25 Apr 2021 03:28:25 -0400 Received: from localhost (unknown [31.210.177.125]) by flashner.co.il (Postfix) with ESMTPSA id 5B60240363; Sun, 25 Apr 2021 07:28:15 +0000 (UTC) Date: Sun, 25 Apr 2021 10:27:28 +0300 From: Efraim Flashner Message-ID: Mail-Followup-To: Efraim Flashner , Vagrant Cascadian , 44675@debbugs.gnu.org References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="aq6JK6J/d3NQoyHM" Content-Disposition: inline In-Reply-To: <87tunznsi7.fsf@yucca> X-PGP-Key-ID: 0x41AAE7DCCA3D8351 X-PGP-Key: https://flashner.co.il/~efraim/efraim_flashner.asc X-PGP-Fingerprint: A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --aq6JK6J/d3NQoyHM Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Apr 21, 2021 at 04:10:40PM -0700, Vagrant Cascadian wrote: > Control: tags 44675 +patch >=20 > On 2020-11-15, Vagrant Cascadian wrote: > > Please consider a guix lint description/synopsis check for basic > > spelling, typo and rudimentary grammar issues. > ... > > Many of these are likely to be caught by most spell checking routines; > > I'm not sure if there is anything that would be implementable in pure > > guile, or it if would make sense to call out to an external > > spellchecker. > > > > Some of them might be harder, and obviously we do not want too many > > false positives, but no need to get perfectionist on solving this; even > > just checking for "This packages" would haved detected many of these > > issues! >=20 > In the attached patch, I've implemented a simple lint check for "This > packages", which has been fixed in ... 42 packages so far in the git > repository, so maybe this could help catch future ones! >=20 > I haven't implemented a more complicated spellchecker or grammar checker > or anything, but at least this is a start. >=20 > I think it is also within my skills to address "allows to" and "permits > to", if I'm not heading down the wrong path here... >=20 >=20 > live well, > vagrant It might make more sense to name it something more like 'catch-common-typos' and to search for 'This packages', 'allows to', 'permits to', 'file-name' and then print out the different mistakes in the description. Then we can add more as we find them, rather than one check per mistake. --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --aq6JK6J/d3NQoyHM Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAmCFGd0ACgkQQarn3Mo9 g1Gbyg//UlUXH/f0eliEyVtjqJQt+8hNoW0RMgHITqW11z9JZ/n/2Ahff+Jb//83 O4o/9CELlgKZKb9sLCXJFGFAHBQlZVY1zVxTd2QbzFebdN/l5Fya2stJarynHFUJ HWORKHkoq0pC7kSKKxOmIklfxV8sC9EjmiiTKnYlTSWUiex7hlHpTW39PBoXoDn8 xUeHk8SstbO00oYyLN89mmcgjWuUSOFFO0K7fHJxgWeL8F/m298KaJTCbteRS0D7 3o69Hi2+aNpj/742DiWhNCv1CuwNY+aI0Q0V5whJFiZONMJHqQbTqctNn1n5ujjh Zkl5CK5DnYoMKLIg91Oujp+s2BvP9MSiIHXw6EqkaTryG3LQmUZAXcaTTBtBttHb fbbacjiam2JRfaUCL2h/31dZJ71zi095Taeqlah+OjUxNi9+BYacxM+w02iHUxlc j34PJSs30waldU+84+LH+lbN/hZ23qFbvKZ5Meq9NdRsAjGaeceZIO605K7WqLbr A9eP5iRHagsS1OsVc9crkU8h2Q9lLIWMmxq8ZZSuxZJh7fee+BEcyMaK+aa8fwZg 7no5wlSJaoIybvflO15GrMbaWyBoGD3Q6Po8QAp7Hif5uEMIEy0Xj8wEIVd0VcB3 7KDKhWnvJ3iwv3vZlS8VlZXNKiB7jMq1SYqhUmdULwNnc7fogFc= =DYJF -----END PGP SIGNATURE----- --aq6JK6J/d3NQoyHM-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 25 Apr 2021 16:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Efraim Flashner Cc: 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.161936901228951 (code B ref 44675); Sun, 25 Apr 2021 16:44:02 +0000 Received: (at 44675) by debbugs.gnu.org; 25 Apr 2021 16:43:32 +0000 Received: from localhost ([127.0.0.1]:43606 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lahr2-0007Wt-8H for submit@debbugs.gnu.org; Sun, 25 Apr 2021 12:43:32 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:53042) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lahr0-0007Wf-1u for 44675@debbugs.gnu.org; Sun, 25 Apr 2021 12:43:30 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id 43D1C1AF0F; Sun, 25 Apr 2021 09:43:23 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> Date: Sun, 25 Apr 2021 09:43:17 -0700 Message-ID: <87eeeynwm2.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On 2021-04-25, Efraim Flashner wrote: > On Wed, Apr 21, 2021 at 04:10:40PM -0700, Vagrant Cascadian wrote: >> Control: tags 44675 +patch >>=20 >> On 2020-11-15, Vagrant Cascadian wrote: >> > Please consider a guix lint description/synopsis check for basic >> > spelling, typo and rudimentary grammar issues. >> ... >> > Many of these are likely to be caught by most spell checking routines; >> > I'm not sure if there is anything that would be implementable in pure >> > guile, or it if would make sense to call out to an external >> > spellchecker. >> > >> > Some of them might be harder, and obviously we do not want too many >> > false positives, but no need to get perfectionist on solving this; even >> > just checking for "This packages" would haved detected many of these >> > issues! >>=20 >> In the attached patch, I've implemented a simple lint check for "This >> packages", which has been fixed in ... 42 packages so far in the git >> repository, so maybe this could help catch future ones! >>=20 >> I haven't implemented a more complicated spellchecker or grammar checker >> or anything, but at least this is a start. >>=20 >> I think it is also within my skills to address "allows to" and "permits >> to", if I'm not heading down the wrong path here... >>=20 >>=20 >> live well, >> vagrant > > It might make more sense to name it something more like > 'catch-common-typos' and to search for 'This packages', 'allows to', > 'permits to', 'file-name' and then print out the different mistakes in > the description. Then we can add more as we find them, rather than one > check per mistake. That makes sense, though 'This packages' is very straightforward and has a simple recommendation to fix it, whereas 'allows to' requires more complicated english skills to come up with the correct solution... it could just simply flag those cases as "wrong" without a solution. Basically, I already stretched my cargo-culting, er, guile skills just to get something obvious fixed that I keep seeing over and over again. It would be a good excercise for me to better learn guile to extend to further typos, though ... limited time. Playing whack-a-mole with typos does get tiring :) live well, vagrant --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYIWcJQAKCRDcUY/If5cW qnAFAP4qgz82H73sev7l5ghpUl6hb+G9KLOH/HtdY5XPVUxVIAD+J1bPekfF9yJq J4kM0wW5WF7HTJN2ZbE2X2ITOCgMsgk= =7Ckg -----END PGP SIGNATURE----- --=-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Tue, 04 May 2021 16:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Vagrant Cascadian Cc: Maxime Devos , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.162014643912817 (code B ref 44675); Tue, 04 May 2021 16:41:02 +0000 Received: (at 44675) by debbugs.gnu.org; 4 May 2021 16:40:39 +0000 Received: from localhost ([127.0.0.1]:54220 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldy6B-0003Kf-6s for submit@debbugs.gnu.org; Tue, 04 May 2021 12:40:39 -0400 Received: from eggs.gnu.org ([209.51.188.92]:56166) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldy69-0003KV-H0 for 44675@debbugs.gnu.org; Tue, 04 May 2021 12:40:37 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:55699) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldy63-0008Tk-GG; Tue, 04 May 2021 12:40:31 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=59960 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ldy61-0005zi-70; Tue, 04 May 2021 12:40:29 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 15 =?UTF-8?Q?Flor=C3=A9al?= an 229 de la =?UTF-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Tue, 04 May 2021 18:40:27 +0200 In-Reply-To: <87o8e6nqvv.fsf@yucca> (Vagrant Cascadian's message of "Thu, 22 Apr 2021 10:57:56 -0700") Message-ID: <87o8dqmozo.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-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hi Vagrant, Vagrant Cascadian skribis: > From 4e724fbe9815e1c27967b835f08d2259164538ba Mon Sep 17 00:00:00 2001 > From: Vagrant Cascadian > Date: Wed, 21 Apr 2021 09:26:45 -0700 > Subject: [PATCH] lint: Add description check for pluralized "This package" > > Partial fix for: https://issues.guix.gnu.org/44675 > > * guix/lint.scm (check-pluralized-this-package): Add check for > occurances of "This packages" in package descriptions. > * tests/lint.scm: Add test. I had missed this patch, nice! > + (define (check-pluralized-this-package description) > + "Check that DESCRIPTION does not contain 'This packages'" > + (if (string-match "This packages" description) > + (list > + (make-warning package > + (G_ "description contains 'This packages' but should just be 'T= his package'"))) > + '())) How about making this =E2=80=98check-spelling=E2=80=99 and generalizing a b= it so that it iterates over a bunch of regexps or strings? Like: (if (any (cut string-contains description <>) patterns) =E2=80=A6) where =E2=80=98patterns=E2=80=99 is a list of strings. (Note that =E2=80=98string-match=E2=80=99 invokes libc=E2=80=99s regcomp + = regexec, so it=E2=80=99s more heavyweight than needed here.) Thanks, Ludo=E2=80=99. From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Wed, 09 Jun 2021 15:34:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: Maxime Devos , Efraim Flashner , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.16232528261003 (code B ref 44675); Wed, 09 Jun 2021 15:34:01 +0000 Received: (at 44675) by debbugs.gnu.org; 9 Jun 2021 15:33:46 +0000 Received: from localhost ([127.0.0.1]:34440 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lr0DC-0000G7-7z for submit@debbugs.gnu.org; Wed, 09 Jun 2021 11:33:46 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:60166) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lr0D9-0000Fq-L4 for 44675@debbugs.gnu.org; Wed, 09 Jun 2021 11:33:44 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id 964431A904; Wed, 9 Jun 2021 08:33:37 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: <87o8dqmozo.fsf@gnu.org> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> Date: Wed, 09 Jun 2021 08:33:33 -0700 Message-ID: <87zgvz129e.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 2021-05-04, Ludovic Court=C3=A8s wrote: > Vagrant Cascadian skribis: > >> From 4e724fbe9815e1c27967b835f08d2259164538ba Mon Sep 17 00:00:00 2001 >> From: Vagrant Cascadian >> Date: Wed, 21 Apr 2021 09:26:45 -0700 >> Subject: [PATCH] lint: Add description check for pluralized "This packag= e" >> >> Partial fix for: https://issues.guix.gnu.org/44675 >> >> * guix/lint.scm (check-pluralized-this-package): Add check for >> occurances of "This packages" in package descriptions. >> * tests/lint.scm: Add test. > > I had missed this patch, nice! > >> + (define (check-pluralized-this-package description) >> + "Check that DESCRIPTION does not contain 'This packages'" >> + (if (string-match "This packages" description) >> + (list >> + (make-warning package >> + (G_ "description contains 'This packages' but should just be '= This package'"))) >> + '())) > > How about making this =E2=80=98check-spelling=E2=80=99 and generalizing a= bit so that it > iterates over a bunch of regexps or strings? > > Like: > > (if (any (cut string-contains description <>) patterns) > =E2=80=A6) > > where =E2=80=98patterns=E2=80=99 is a list of strings. Love the idea, but would need some help in implementing! There have been at least three newly added "This packages" since I submitted this patch, so wondering if we can at least get the simple case merged before getting too caught up in all the potential improvements? > (Note that =E2=80=98string-match=E2=80=99 invokes libc=E2=80=99s regcomp = + regexec, so it=E2=80=99s more > heavyweight than needed here.) I can probably manage that! (I'll dig up where the simpler suggestion was) live well, vagrant --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYMDfTQAKCRDcUY/If5cW qgzgAP9D/QK00msHp9nAnF49CJThYxuajJrLHjts0/9KLXy9JQEAw4CVPdEbgH67 AGhsq8QOmGHm6cdfa21MIKqdP/zv7Q8= =iO+2 -----END PGP SIGNATURE----- --=-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 21 Oct 2021 23:19:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: 44675@debbugs.gnu.org Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Maxime Devos , Efraim Flashner Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.163485832713995 (code B ref 44675); Thu, 21 Oct 2021 23:19:01 +0000 Received: (at 44675) by debbugs.gnu.org; 21 Oct 2021 23:18:47 +0000 Received: from localhost ([127.0.0.1]:58909 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mdhKh-0003de-Hp for submit@debbugs.gnu.org; Thu, 21 Oct 2021 19:18:47 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:40348) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mdhKg-0003dP-7C for 44675@debbugs.gnu.org; Thu, 21 Oct 2021 19:18:46 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id E7FD21AA2C; Thu, 21 Oct 2021 16:18:39 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: <87zgvz129e.fsf@yucca> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> <87zgvz129e.fsf@yucca> Date: Thu, 21 Oct 2021 16:18:34 -0700 Message-ID: <8735ouotkl.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On 2021-06-09, Vagrant Cascadian wrote: > There have been at least three newly added "This packages" since I > submitted this patch, so wondering if we can at least get the simple > case merged before getting too caught up in all the potential > improvements? And up until today, that list grew to 7! (fixed by=20 Long delayed updated patch ... I think it addresses almost all of the issues brought up, and maybe introduces a few new ones! It has been rewritten to easily add new typo checks, but this one so far only addresses pluralized "This packages". Would be easy enough to add "allows to" but hard to add a suggested fix... Big thanks to rekado, vivien and nckx who helped via #guix IRC! live well, vagrant --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: inline; filename=0001-lint-Add-description-check-for-pluralized-This-packa.patch Content-Transfer-Encoding: quoted-printable From=203ab46ca7932614ab4c699512c2fbfa8207ffa964 Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Thu, 21 Oct 2021 15:51:11 -0700 Subject: [PATCH] lint: Add description check for pluralized "This package" Partial fix for: https://issues.guix.gnu.org/44675 * guix/lint.scm (check-description-typo): Add check for occurances of "This packages" in package descriptions. * tests/lint.scm: Add test. =2D-- guix/lint.scm | 12 ++++++++++++ tests/lint.scm | 7 +++++++ 2 files changed, 19 insertions(+) diff --git a/guix/lint.scm b/guix/lint.scm index 7b02b9cec0..b22454fd31 100644 =2D-- a/guix/lint.scm +++ b/guix/lint.scm @@ -321,6 +321,17 @@ markup is valid return a plain-text version of DESCRIP= TION, otherwise #f." (G_ "Texinfo markup in description is invalid") #:field 'description)))) =20 + (define (check-description-typo description typo correction) + "Check that DESCRIPTION does not contain typo, with optional correctio= n" + (if (string-contains description typo) + (list + (make-warning package + (G_ + (format #false + "description contains typo '~a'~@[, should= be '~a'~]" + typo correction)))) + '())) + (define (check-trademarks description) "Check that DESCRIPTION does not contain '=E2=84=A2' or '=C2=AE' chara= cters. See http://www.gnu.org/prep/standards/html_node/Trademarks.html." @@ -401,6 +412,7 @@ by two spaces; possible infraction~p at ~{~a~^, ~}") (check-not-empty description) (check-quotes description) (check-trademarks description) + (check-description-typo description "This packages" "This package= ") ;; Use raw description for this because Texinfo rendering ;; automatically fixes end of sentence space. (check-end-of-sentence-space description) diff --git a/tests/lint.scm b/tests/lint.scm index 699a750eb9..1902a87354 100644 =2D-- a/tests/lint.scm +++ b/tests/lint.scm @@ -177,6 +177,13 @@ (description "Whitespace. ")))) (check-description-style pkg)))) =20 +(test-equal "description: pluralized 'This package'" + "description contains typo 'This packages', should be 'This package'" + (single-lint-warning-message + (let ((pkg (dummy-package "x" + (description "This packages is a typo.")))) + (check-description-style pkg)))) + (test-equal "synopsis: not a string" "invalid synopsis: #f" (single-lint-warning-message =2D-=20 2.30.2 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYXH1SwAKCRDcUY/If5cW qvtEAP9hlcihBOeEnrbS6zZjgdxG84VvbfSVPK6KtvLt0Di1/wD+MxXNMtIeRn7h uJZQ50L0D3MKsoJoZnfKQcG9CprXjQ0= =YK9i -----END PGP SIGNATURE----- --==-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Fri, 22 Oct 2021 08:39:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Vagrant Cascadian , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.16348919406086 (code B ref 44675); Fri, 22 Oct 2021 08:39:01 +0000 Received: (at 44675) by debbugs.gnu.org; 22 Oct 2021 08:39:00 +0000 Received: from localhost ([127.0.0.1]:59307 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mdq4p-0001a6-Lu for submit@debbugs.gnu.org; Fri, 22 Oct 2021 04:38:59 -0400 Received: from mail-wr1-f42.google.com ([209.85.221.42]:33379) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mdq4o-0001Zp-1K for 44675@debbugs.gnu.org; Fri, 22 Oct 2021 04:38:58 -0400 Received: by mail-wr1-f42.google.com with SMTP id m22so2922865wrb.0 for <44675@debbugs.gnu.org>; Fri, 22 Oct 2021 01:38:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:in-reply-to:references:date:message-id:mime-version :content-transfer-encoding; bh=KmUvvfiFXeBkqV2DuOumx/2YQqoXWhuCoZBzvaGK+n4=; b=OEl/9K80w7Cy/nJKuUHn8zTYL23rF8/1tZLgM+JCd4sEpcl1kwwABxZ2FlXIFaGZCW pf3pO/pAtptXhaZ8SA5CZleUQhhxCTG1m+Fbr4KyC3ACNfhxVdDievukxHlva8wqquRP CrXq0hmXvsD8QpACin115Jg7yCSIRoL+nUBPqS5Mulf4bwqpnkgOVxQI/ijJz8pryAlv 59gqQ4I7BdzPvqlNJYb7RWUQZKHVWPKwpaXEoW1YA+XtjHMRR3EOB1eqotWT42GVoXpi K0KluiY3uXiae+X/NFtMlFA1HjdelVN15EYfaZK99vVQuqUnxzt75biMaU4gHjvXih3u yBlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=KmUvvfiFXeBkqV2DuOumx/2YQqoXWhuCoZBzvaGK+n4=; b=Jp6W3ZMDm4YbEbxUm50GZ9l/N+NLf/ZmhI9kF1M+ppRvQ2ABM7qD3+jH1h/zW0bczK Dzzcu6dG7d1qGrXDkVU+Ii3RXgmgfMhEEE5j2cUShyEp9v9F92bij58FE5K+VTfpa5Rc wtH2q22VunZdSbW95ufE7Sg4Ww4ztn1carpRiNlEafNrbh8PodnBrFJBspRT44I8mmXj U8SVRYgAw0Gw7fPq+9u6AUKsUT5mn0q8jTNjQHrwIt0XlCsv6Gwi4/AwpkrtTwkBq1ig 9n89sSvsKFg/V3JZ0Zgs2Mj9m0EB5jPcEiqLMjfwenLRsdUjI4fL+xtftjAuH29R8v8C VeWw== X-Gm-Message-State: AOAM530thl3+FfRwOvBJTdh/PWyXSgSUmy9JNm8VvcwjH9bNUAOSX0iJ 0DKbDO3vLqV9yFJsjK/P/Ox7jvqSLxM= X-Google-Smtp-Source: ABdhPJyPgldB+CHQfbIHuQmf6EanLrUXPzXOoKEuDdMsEIkxEvYiespfJ39xcWf+aKTq22XLMIEy+g== X-Received: by 2002:adf:fccc:: with SMTP id f12mr10164340wrs.208.1634891932251; Fri, 22 Oct 2021 01:38:52 -0700 (PDT) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id j7sm9350602wmq.32.2021.10.22.01.38.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Oct 2021 01:38:51 -0700 (PDT) From: zimoun In-Reply-To: <8735ouotkl.fsf@yucca> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> <87zgvz129e.fsf@yucca> <8735ouotkl.fsf@yucca> Date: Fri, 22 Oct 2021 10:33:27 +0200 Message-ID: <865ytpzcfc.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Vagrant, On Thu, 21 Oct 2021 at 16:18, Vagrant Cascadian wrote: > It has been rewritten to easily add new typo checks, but this one so far > only addresses pluralized "This packages". Would be easy enough to add > "allows to" but hard to add a suggested fix... If I remember correctly the previous discussion, Debian uses an external tool for spellchecking. Here, the patch uses a list of =E2=80=9Ccommon=E2= =80=9D mistakes. It is seems an easy good start. :-) > + (define (check-description-typo description typo correction) Instead, I would use a list of alist =E2=80=99typo-corrections=E2=80=99 as = argument. For instance, --8<---------------cut here---------------start------------->8--- (define (check-description-typo description typo-corrections) (for-each (match-lambda ((typo . correction) (if (string-contains description typo) (list (make-warning ...)) '()))) typo-corrections)) --8<---------------cut here---------------end--------------->8--- > + "Check that DESCRIPTION does not contain typo, with optional > correction" > + (if (string-contains description typo) > + (list > + (make-warning package > + (G_ > + (format #false > + "description contains typo '~a'~@[, shou= ld be '~a'~]" > + typo correction)))) > + '())) > + [...] > + (check-description-typo description "This packages" "This packa= ge") And the call reads, (check-description-typo description '(("This packages" . "This = package"))) which allows easily to add new pattern; such as, '(("This packages" . "This package") ("this packages" . "this package") ("This modules" . "This module")) Then, as a second step, depending on the patterns listed, let see if there is a pattern inside these patterns. ;-) (Check both capitalize and lower-case, etc.) Cheers, simon From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 24 Oct 2021 11:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: zimoun Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.16350745454952 (code B ref 44675); Sun, 24 Oct 2021 11:23:02 +0000 Received: (at 44675) by debbugs.gnu.org; 24 Oct 2021 11:22:25 +0000 Received: from localhost ([127.0.0.1]:38001 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1meba4-0001Ho-Rk for submit@debbugs.gnu.org; Sun, 24 Oct 2021 07:22:25 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:45666) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1meba3-0001Hc-CS for 44675@debbugs.gnu.org; Sun, 24 Oct 2021 07:22:23 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id A6C011AA2C; Sun, 24 Oct 2021 04:22:17 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: <865ytpzcfc.fsf@gmail.com> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> <87zgvz129e.fsf@yucca> <8735ouotkl.fsf@yucca> <865ytpzcfc.fsf@gmail.com> Date: Sun, 24 Oct 2021 04:22:14 -0700 Message-ID: <87mtmyr7kp.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 2021-10-22, zimoun wrote: > On Thu, 21 Oct 2021 at 16:18, Vagrant Cascadian wrot= e: > >> It has been rewritten to easily add new typo checks, but this one so far >> only addresses pluralized "This packages". Would be easy enough to add >> "allows to" but hard to add a suggested fix... > > If I remember correctly the previous discussion, Debian uses an external > tool for spellchecking. Here, the patch uses a list of =E2=80=9Ccommon= =E2=80=9D > mistakes. It is seems an easy good start. :-) Yes, I definitely went for "catch some useful things" rather than trying to be comprehensive... these checks should catch the majority of historical ones I've noticed, but I didn't bother adding one-off typos. > Instead, I would use a list of alist =E2=80=99typo-corrections=E2=80=99 a= s argument. > For instance, > > --8<---------------cut here---------------start------------->8--- > (define (check-description-typo description typo-corrections) > (for-each > (match-lambda > ((typo . correction) > (if (string-contains description typo) > (list > (make-warning ...)) > '()))) > typo-corrections)) > --8<---------------cut here---------------end--------------->8--- So close! Ludo spotted that the for-each needed to be replaced with append-map, and that basically did it! > (check-description-typo description '(("This packages" . "Thi= s package"))) > > which allows easily to add new pattern; such as, > > '(("This packages" . "This package") > ("this packages" . "this package") > ("This modules" . "This module")) > > Then, as a second step, depending on the patterns listed, let see if > there is a pattern inside these patterns. ;-) (Check both capitalize and > lower-case, etc.) I haven't seen case issues in practice for these. I've added "This packages", "This modules", "allows to" and "permits to" to the list while I was at it. I only added tests for "This packages" and "allows to" as the others are so similar I'm not sure it's worth testing... Here's to hoping for a guix with fewer glaring typos with which to craft guix poetry. :) New patch attached! live well, vagrant --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: inline; filename=0001-lint-Add-description-check-for-common-typos.patch Content-Transfer-Encoding: quoted-printable From=20a171769da0f737468e06866164eadf1e720764ba Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Sun, 24 Oct 2021 04:00:15 -0700 Subject: [PATCH] lint: Add description check for common typos. Fixes: https://issues.guix.gnu.org/44675 * guix/lint.scm (check-description-typo): Add check for occurances of "This packages", "This modules", "allows to" and "permits to" in package descriptions. * tests/lint.scm: Add tests for "This packages" and "allows to". =2D-- guix/lint.scm | 19 +++++++++++++++++++ tests/lint.scm | 14 ++++++++++++++ 2 files changed, 33 insertions(+) diff --git a/guix/lint.scm b/guix/lint.scm index 7b02b9cec0..ac2e7b3841 100644 =2D-- a/guix/lint.scm +++ b/guix/lint.scm @@ -321,6 +321,21 @@ markup is valid return a plain-text version of DESCRIP= TION, otherwise #f." (G_ "Texinfo markup in description is invalid") #:field 'description)))) =20 + (define (check-description-typo description typo-corrections) + "Check that DESCRIPTION does not contain typo, with optional correctio= n" + (append-map + (match-lambda + ((typo . correction) + (if (string-contains description typo) + (list + (make-warning package + (G_ + (format #false + "description contains typo '~a'~@[, sho= uld be '~a'~]" + typo correction)))) + '()))) + typo-corrections)) + (define (check-trademarks description) "Check that DESCRIPTION does not contain '=E2=84=A2' or '=C2=AE' chara= cters. See http://www.gnu.org/prep/standards/html_node/Trademarks.html." @@ -401,6 +416,10 @@ by two spaces; possible infraction~p at ~{~a~^, ~}") (check-not-empty description) (check-quotes description) (check-trademarks description) + (check-description-typo description '(("This packages" . "This pa= ckage") + ("This modules" . "This mod= ule") + ("allows to" . #f) + ("permits to" . #f))) ;; Use raw description for this because Texinfo rendering ;; automatically fixes end of sentence space. (check-end-of-sentence-space description) diff --git a/tests/lint.scm b/tests/lint.scm index 699a750eb9..6a7eed02e0 100644 =2D-- a/tests/lint.scm +++ b/tests/lint.scm @@ -177,6 +177,20 @@ (description "Whitespace. ")))) (check-description-style pkg)))) =20 +(test-equal "description: pluralized 'This package'" + "description contains typo 'This packages', should be 'This package'" + (single-lint-warning-message + (let ((pkg (dummy-package "x" + (description "This packages is a typo.")))) + (check-description-style pkg)))) + +(test-equal "description: grammar 'allows to'" + "description contains typo 'allows to'" + (single-lint-warning-message + (let ((pkg (dummy-package "x" + (description "This package allows to do stuff= .")))) + (check-description-style pkg)))) + (test-equal "synopsis: not a string" "invalid synopsis: #f" (single-lint-warning-message =2D-=20 2.30.2 --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYXVB5wAKCRDcUY/If5cW qikvAQDiaQqa8kHiYS4AWxIus3x1VkdMUhmBTLOMgolSxqIkcAD8CmhSqhprnrfp 8P3vwacCFwk7lCGy4soPAYKsBFPJuQc= =mfD9 -----END PGP SIGNATURE----- --==-=-=-- From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 24 Oct 2021 12:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Vagrant Cascadian Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.163507686725154 (code B ref 44675); Sun, 24 Oct 2021 12:02:02 +0000 Received: (at 44675) by debbugs.gnu.org; 24 Oct 2021 12:01:07 +0000 Received: from localhost ([127.0.0.1]:38030 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mecBW-0006Xd-Uj for submit@debbugs.gnu.org; Sun, 24 Oct 2021 08:01:07 -0400 Received: from mail-wr1-f53.google.com ([209.85.221.53]:47000) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mecBW-0006X3-1y for 44675@debbugs.gnu.org; Sun, 24 Oct 2021 08:01:06 -0400 Received: by mail-wr1-f53.google.com with SMTP id k7so2614116wrd.13 for <44675@debbugs.gnu.org>; Sun, 24 Oct 2021 05:01:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=PqPGKGFA4Rp0FnMQA55rChOZc5xO+lKEAUwtm1Ai9Ug=; b=FzjegTU0+KQQpyRyjR5/5/HJIDqmKtb2Bx+NIeDHsNGluvLGa5yPhzGWC4HhTg98Wa lbFIOt0G3TJJeRa5SNHGRUGKdmMfkD1oslIRHOOXv+CYbGn2bbndnWe8zNy7mgQr4lqi U4YdUYdtMMbE/u4anjpbnm/O41vNPccooZUTee86iXAfC5bZ0kjk7lhIjYu6ii7ywH88 Wd09pgfMSEvc1hQODFJlIxUs1HhXpMw3YiS5N0eH7WUckQwCp9aHHOVRYN3znAEaOdXM 9oUvRhhZCNkHFWFKzJVAGU1bkD1cPfHCtCU8zQ1YFXKFUmOrMM5j0IBSo494QofNnKsd 3lrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=PqPGKGFA4Rp0FnMQA55rChOZc5xO+lKEAUwtm1Ai9Ug=; b=XO+8Q68+RsFRI6nJ/8DdnnxSCp5zB2K/AIz/FldUiWrmroLf7BQdFFyMgT7GClIJKA GhrkIvwldZYekrJn9A3eJ1WZ+uM7/yMNcDGRqPgF8ks4eW5KujZl9H6rEuMeBoakgZZW F9j2ysyFoxUeLc0jQJMd+HCv3hgdioESaYsCS17D8yDLidC+UuAEx7a8ZiktB6eP0GBp iOuVfYBRHxC4VkqansGNlCjeTuJ9axPNFGP5YIrZ12/uD8tYTnWteABN/JN/JNKReA1z HkUWHWOuIMnW8/pm0MTxbgY6ObVXIAWpeX5DO7lXSMwx5Iw5sZkC06jxkqFjx31TALeA YBIQ== X-Gm-Message-State: AOAM530ZPcPHL8h+JqfGAKZe25Cn9KIBhgd61hABktd3jWofRExAXOzg xQHX2Cm8J+hLF/y9alzicIGhwBAzzPg= X-Google-Smtp-Source: ABdhPJw6b1mmwXxvDr7z6sclBJcC19tP/xm2OognexvPsoE29aT9qUlt+EI8gOkdV/S27ip3Ockbfw== X-Received: by 2002:adf:ba87:: with SMTP id p7mr15082874wrg.282.1635076859944; Sun, 24 Oct 2021 05:00:59 -0700 (PDT) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id n11sm3891484wrs.14.2021.10.24.05.00.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Oct 2021 05:00:59 -0700 (PDT) From: zimoun In-Reply-To: <87mtmyr7kp.fsf@yucca> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> <87zgvz129e.fsf@yucca> <8735ouotkl.fsf@yucca> <865ytpzcfc.fsf@gmail.com> <87mtmyr7kp.fsf@yucca> Date: Sun, 24 Oct 2021 13:56:14 +0200 Message-ID: <86ilxmab6p.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi, On Sun, 24 Oct 2021 at 04:22, Vagrant Cascadian wrote: > So close! Ludo spotted that the for-each needed to be replaced with > append-map, and that basically did it! Indeed, I have not checked the type of full chain. :-) And the return value probably needs to be strongly a list, instead of not-specified. ;-) > Here's to hoping for a guix with fewer glaring typos with which to craft > guix poetry. :) Guix poetry, oh well. :-) > From a171769da0f737468e06866164eadf1e720764ba Mon Sep 17 00:00:00 2001 > From: Vagrant Cascadian > Date: Sun, 24 Oct 2021 04:00:15 -0700 > Subject: [PATCH] lint: Add description check for common typos. > > Fixes: https://issues.guix.gnu.org/44675 > > * guix/lint.scm (check-description-typo): Add check for occurances of ----^^ Occurrence, no? Well, maybe a US vs UK vs French-glish. :-) > "This packages", "This modules", "allows to" and "permits to" in package > descriptions. > * tests/lint.scm: Add tests for "This packages" and "allows to". > --- > guix/lint.scm | 19 +++++++++++++++++++ > tests/lint.scm | 14 ++++++++++++++ > 2 files changed, 33 insertions(+) Otherwise, LGTM. Cheers, simon From unknown Tue Sep 09 13:20:25 2025 X-Loop: help-debbugs@gnu.org Subject: bug#44675: guix lint: support for spellchecker or basic grammar Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 24 Oct 2021 19:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44675 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: zimoun Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , 44675@debbugs.gnu.org Received: via spool by 44675-submit@debbugs.gnu.org id=B44675.163510214629308 (code B ref 44675); Sun, 24 Oct 2021 19:03:02 +0000 Received: (at 44675) by debbugs.gnu.org; 24 Oct 2021 19:02:26 +0000 Received: from localhost ([127.0.0.1]:40931 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1meilG-0007cS-Js for submit@debbugs.gnu.org; Sun, 24 Oct 2021 15:02:26 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:46294) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1meilE-0007Xd-SU for 44675@debbugs.gnu.org; Sun, 24 Oct 2021 15:02:25 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id 102D21AA2C; Sun, 24 Oct 2021 12:02:19 -0700 (PDT) From: Vagrant Cascadian In-Reply-To: <86ilxmab6p.fsf@gmail.com> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> <87zgvz129e.fsf@yucca> <8735ouotkl.fsf@yucca> <865ytpzcfc.fsf@gmail.com> <87mtmyr7kp.fsf@yucca> <86ilxmab6p.fsf@gmail.com> Date: Sun, 24 Oct 2021 12:02:15 -0700 Message-ID: <87fssqqma0.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain On 2021-10-24, zimoun wrote: > On Sun, 24 Oct 2021 at 04:22, Vagrant Cascadian wrote: >> From a171769da0f737468e06866164eadf1e720764ba Mon Sep 17 00:00:00 2001 >> From: Vagrant Cascadian >> Date: Sun, 24 Oct 2021 04:00:15 -0700 >> Subject: [PATCH] lint: Add description check for common typos. >> >> Fixes: https://issues.guix.gnu.org/44675 >> >> * guix/lint.scm (check-description-typo): Add check for occurances of > ----^^ > > Occurrence, no? Well, maybe a US vs UK vs French-glish. :-) You are correct! French-glish FTW! :) >> "This packages", "This modules", "allows to" and "permits to" in package >> descriptions. >> * tests/lint.scm: Add tests for "This packages" and "allows to". >> --- >> guix/lint.scm | 19 +++++++++++++++++++ >> tests/lint.scm | 14 ++++++++++++++ >> 2 files changed, 33 insertions(+) > > Otherwise, LGTM. Shall I fix the above typo (the irony!) and push before we get any more of these typos in the repository? :) live well, vagrant --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYXWtuAAKCRDcUY/If5cW qmTDAP93Z9HX8mkdrpkp2zxU/CGQOcMOvez8dUhl223rZdA7nQEAwB0bEOBx1QKs ggU3lETzZ6YIHeOv1L75xkdmcj2nowM= =03vP -----END PGP SIGNATURE----- --=-=-=-- From unknown Tue Sep 09 13:20:25 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Vagrant Cascadian Subject: bug#44675: closed (Re: bug#44675: guix lint: support for spellchecker or basic grammar) Message-ID: References: <87bl3eqewv.fsf@yucca> <87ima6rrri.fsf@yucca> X-Gnu-PR-Message: they-closed 44675 X-Gnu-PR-Package: guix X-Gnu-PR-Keywords: easy Reply-To: 44675@debbugs.gnu.org Date: Sun, 24 Oct 2021 21:42:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1635111722-22168-1" This is a multi-part message in MIME format... ------------=_1635111722-22168-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #44675: guix lint: support for spellchecker or basic grammar which was filed against the guix package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 44675@debbugs.gnu.org. --=20 44675: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D44675 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1635111722-22168-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 44675-done) by debbugs.gnu.org; 24 Oct 2021 21:41:31 +0000 Received: from localhost ([127.0.0.1]:41131 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1melFD-0005km-A9 for submit@debbugs.gnu.org; Sun, 24 Oct 2021 17:41:31 -0400 Received: from cascadia.aikidev.net ([173.255.214.101]:50518) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1melFC-0005ka-0i for 44675-done@debbugs.gnu.org; Sun, 24 Oct 2021 17:41:30 -0400 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id E439D1AA2C; Sun, 24 Oct 2021 14:41:23 -0700 (PDT) From: Vagrant Cascadian To: zimoun Subject: Re: bug#44675: guix lint: support for spellchecker or basic grammar In-Reply-To: <87fssqqma0.fsf@yucca> References: <87ima6rrri.fsf@yucca> <87tunznsi7.fsf@yucca> <2f3077c0d040e4b40db19d98195845e124b064d3.camel@telenet.be> <87o8e6nqvv.fsf@yucca> <87o8dqmozo.fsf@gnu.org> <87zgvz129e.fsf@yucca> <8735ouotkl.fsf@yucca> <865ytpzcfc.fsf@gmail.com> <87mtmyr7kp.fsf@yucca> <86ilxmab6p.fsf@gmail.com> <87fssqqma0.fsf@yucca> Date: Sun, 24 Oct 2021 14:41:20 -0700 Message-ID: <87bl3eqewv.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44675-done Cc: Ludovic =?utf-8?Q?Court=C3=A8s?= , 44675-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain On 2021-10-24, Vagrant Cascadian wrote: > On 2021-10-24, zimoun wrote: >> On Sun, 24 Oct 2021 at 04:22, Vagrant Cascadian wrote: >>> "This packages", "This modules", "allows to" and "permits to" in package >>> descriptions. >>> * tests/lint.scm: Add tests for "This packages" and "allows to". >>> --- >>> guix/lint.scm | 19 +++++++++++++++++++ >>> tests/lint.scm | 14 ++++++++++++++ >>> 2 files changed, 33 insertions(+) >> >> Otherwise, LGTM. > > Shall I fix the above typo (the irony!) and push before we get any more > of these typos in the repository? :) Pushed to master as b5f45a21c27b80210753e184e52708bb75a347bb. Thanks for all your help! live well, vagrant --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCYXXTAAAKCRDcUY/If5cW qr/HAQCBiXxMCF9RtAed7NaWXn/vVEQIgFDZBZDtoz12IpuWGQD9E8yi3i3Ix3RI ZZDH3uxa9z9h6DrvwMkUm8dKIAgG+QU= =qzn3 -----END PGP SIGNATURE----- --=-=-=-- ------------=_1635111722-22168-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 16 Nov 2020 01:54:07 +0000 Received: from localhost ([127.0.0.1]:54680 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keTiZ-0006h1-0h for submit@debbugs.gnu.org; Sun, 15 Nov 2020 20:54:07 -0500 Received: from lists.gnu.org ([209.51.188.17]:45320) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keTiV-0006gp-Ma for submit@debbugs.gnu.org; Sun, 15 Nov 2020 20:54:06 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:50756) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1keTiT-00084g-SY for bug-guix@gnu.org; Sun, 15 Nov 2020 20:54:03 -0500 Received: from cascadia.aikidev.net ([173.255.214.101]:60544) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1keTiR-0005jG-Ng for bug-guix@gnu.org; Sun, 15 Nov 2020 20:54:01 -0500 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id F08D61AA41 for ; Sun, 15 Nov 2020 17:53:56 -0800 (PST) From: Vagrant Cascadian To: bug-guix@gnu.org Subject: guix lint: support for spellchecker or basic grammar Date: Sun, 15 Nov 2020 17:53:53 -0800 Message-ID: <87ima6rrri.fsf@yucca> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Received-SPF: none client-ip=173.255.214.101; envelope-from=vagrant@debian.org; helo=cascadia.aikidev.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/15 20:53:57 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain Please consider a guix lint description/synopsis check for basic spelling, typo and rudimentary grammar issues. Most of the ones I've found were caught by debian's "lintian" tool: https://tracker.debian.org/lintian Common issues appear to be: "This packages" -> "This package" "allows to X" -> "Xs" or "Xing" I've fixed many of these in the past: git log --author=vagrant --extended-regexp --grep='spelling|typo|grammar' --patch But some of the very same patterns keep reappearing! Many of these are likely to be caught by most spell checking routines; I'm not sure if there is anything that would be implementable in pure guile, or it if would make sense to call out to an external spellchecker. Some of them might be harder, and obviously we do not want too many false positives, but no need to get perfectionist on solving this; even just checking for "This packages" would haved detected many of these issues! That is, of course, if "guix lint" is being used consistently... :) live well, vagrant --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEARYKAB0WIQRlgHNhO/zFx+LkXUXcUY/If5cWqgUCX7HbsQAKCRDcUY/If5cW qkGNAP9k5PHKWQUAar5lQzxIfjyZkqBArCd2xtcWvgAtrofqrgD+Prxswpjl9TST rnfFB5SnKII3Ytwftt5aM5WHpw5BJQY= =7RdI -----END PGP SIGNATURE----- --=-=-=-- ------------=_1635111722-22168-1--