Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1032149pxj; Thu, 17 Jun 2021 20:44:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyby8Abe/qJE73ArmFzk7+jvO+Z7RlDPlUVBvtQxkaG5EQI2kAJOBmL2x5zogQ9bscwM5/C X-Received: by 2002:a17:906:ce43:: with SMTP id se3mr8588005ejb.554.1623987862309; Thu, 17 Jun 2021 20:44:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623987862; cv=none; d=google.com; s=arc-20160816; b=uSHlIMlr84ptIsrVYDNR8imDmqFyNl4DRUBwzJHpcdvqIMh8EgndsdgBcxvUbv/TYU VxziLjuFRyReMfNfKiQ3rBgcCy1rcvI2Lo4CEQJ8LEY/jb39Eph5WD21KCrOCzeVgnAQ WjVwRr7ri9UoT2HiadM45HE4bWYntofWM6rUsFYQbvZwzwayDaJz19IS4MFtyIAwXJEa MEi+gQfhApe7K5pQMMabrvPVBS5On9tKTANisCbD3B4Eba7RybJXpEWqokjYbA2IX1qQ VvcSVKfhs1L3YvT9vFCZLGDPCVyQK9VXCX4OuDtIntAaJZUeK5xqwBtEU3q0icnz/9eY T9pw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=lHcmcig3rOoQNK2Qm7OgEwe2ZDMqsMc0V+ZubzTofYE=; b=mg0rGLx3GhkJ//BM6v98XtN2SvtCxGVUAf5VkBYs2F56+O9MvwGGnnY0g8CzrLMl06 Td6M0WEu/9uEnLR9XqvP9SeFus0c1gpO6KhAPGTV4m/Gb7T2MYfZrysHhGMJ0mqE9QDC haRaic0KLa1PZU5pRiRUFVJUuIeWOujImcSRAOjWtRs8D6Pezl7p3hDt/WOCDO7qjx4D EA0eHXy6DhDiTXlqudaLEy8GFcVyiq7rdfuTytmgxZOSTvNHTvZFYXwTFePBlPiwA5ZX GilO+TYdEda+OZDCnjnxGthfRhhxTZqOzeOzYdJgzXh8kkVJ74DmXIon2re5qxekmfAT nSmA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a4si1140881ejs.331.2021.06.17.20.44.00; Thu, 17 Jun 2021 20:44:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231572AbhFRCx2 (ORCPT + 99 others); Thu, 17 Jun 2021 22:53:28 -0400 Received: from szxga02-in.huawei.com ([45.249.212.188]:5398 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230393AbhFRCx1 (ORCPT ); Thu, 17 Jun 2021 22:53:27 -0400 Received: from dggemv711-chm.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4G5jys58clz70m7; Fri, 18 Jun 2021 10:48:05 +0800 (CST) Received: from dggpemm500006.china.huawei.com (7.185.36.236) by dggemv711-chm.china.huawei.com (10.1.198.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Fri, 18 Jun 2021 10:51:16 +0800 Received: from [127.0.0.1] (10.174.179.0) by dggpemm500006.china.huawei.com (7.185.36.236) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Fri, 18 Jun 2021 10:51:15 +0800 Subject: Re: [PATCH v2 1/3] scripts: add spelling_sanitizer.sh script To: Petr Mladek CC: Jonathan Corbet , Joe Perches , "Andrew Morton" , Nicolas Dichtel , Jason Baron , Stefani Seibold , Jacob Keller , Thomas Graf , Herbert Xu , Jens Axboe , Sergey Senozhatsky , "Andy Shevchenko" , Rasmus Villemoes , linux-kernel References: <20210616122507.896-1-thunder.leizhen@huawei.com> <20210616122507.896-2-thunder.leizhen@huawei.com> <87bl85yi68.fsf@meer.lwn.net> <4c8ca535-398c-0d19-5242-27ed1d3905ec@huawei.com> From: "Leizhen (ThunderTown)" Message-ID: <2dd756b6-a02b-0bad-4161-1b3dbc223d84@huawei.com> Date: Fri, 18 Jun 2021 10:51:14 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.179.0] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To dggpemm500006.china.huawei.com (7.185.36.236) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021/6/17 15:32, Petr Mladek wrote: > On Thu 2021-06-17 09:11:05, Leizhen (ThunderTown) wrote: >> >> >> On 2021/6/16 22:53, Jonathan Corbet wrote: >>> Zhen Lei writes: >>> >>>> The file scripts/spelling.txt recorded a large number of spelling >>>> "mistake||correction" pairs. These entries are currently maintained in >>>> order, but the results are not strict. In addition, when someone wants to >>>> add some new pairs, he either sort them manually or write a script, which >>>> is clearly a waste of labor. So add this script. For all spelling >>>> "mistake||correction" pairs, sort based on "correction", then on "mistake", >>>> and remove duplicates. Sorting based on "mistake" first is not chosen >>>> because it is uncontrollable. >>>> >>>> Signed-off-by: Zhen Lei >>>> --- >>>> scripts/spelling_sanitizer.sh | 27 +++++++++++++++++++++++++++ >>>> 1 file changed, 27 insertions(+) >>>> create mode 100755 scripts/spelling_sanitizer.sh >>>> >>>> diff --git a/scripts/spelling_sanitizer.sh b/scripts/spelling_sanitizer.sh >>>> new file mode 100755 >>>> index 000000000000..603bb7e0e66b >>>> --- /dev/null >>>> +++ b/scripts/spelling_sanitizer.sh >>>> @@ -0,0 +1,27 @@ >>>> +#!/bin/sh -efu >>>> +# SPDX-License-Identifier: GPL-2.0 >>>> + >>>> +# To get the traditional sort order that uses native byte values >>> >>> So I am of the naive opinion that everything we drop into scripts/ >>> should start with a comment saying why it exists and how to use it. >>> Otherwise how are people going to benefit from it? >> >> Rigth, I will add the description, thanks. > > Ideally, please add also some -h/--help option that would print a short > description and usage. OK, I will add it. > > Best Regards, > Petr > > . >