From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-1.8 required=3.0 tests=BAYES_00,DATE_IN_FUTURE_06_12, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_PASS, SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by dcvr.yhbt.net (Postfix) with ESMTP id 47AE81F66F for ; Thu, 5 Nov 2020 12:16:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730184AbgKEMQZ (ORCPT ); Thu, 5 Nov 2020 07:16:25 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:6745 "EHLO szxga04-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725468AbgKEMQZ (ORCPT ); Thu, 5 Nov 2020 07:16:25 -0500 Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4CRjDF4VWfzkXgl; Thu, 5 Nov 2020 20:16:13 +0800 (CST) Received: from workwork.huawei.com (10.108.148.37) by DGGEMS406-HUB.china.huawei.com (10.3.19.206) with Microsoft SMTP Server id 14.3.487.0; Thu, 5 Nov 2020 20:16:11 +0800 From: Hu Keping To: CC: , , , , , Subject: [PATCH] Lengthening FORMAT_PATCH_NAME_MAX to 80 Date: Thu, 5 Nov 2020 20:15:48 +0000 Message-ID: <20201105201548.2333425-1-hukeping@huawei.com> X-Mailer: git-send-email 2.18.0.huawei.25 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.108.148.37] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org The file name of the patch generated by `git format-patch` usually be truncated as there is less than 60 bytes left for the subject of commit message exclude the prefix patch number, say "0001-". As per the kernel documentation[1], it suggest the length of subject no more than 75. > > [...] > For these reasons, the ``summary`` must be no more than 70-75 > characters, and it must describe both what the patch changes, as well > as why the patch might be necessary. > Considered the prefix patch number "0001-" would take 5 characters, increase the FORMAT_PATCH_NAME_MAX to 80. [1] https://www.kernel.org/doc/Documentation/process/submitting-patches.rst Signed-off-by: Hu Keping --- log-tree.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/log-tree.h b/log-tree.h index 8fa79289ec..021aee0d21 100644 --- a/log-tree.h +++ b/log-tree.h @@ -33,7 +33,7 @@ void log_write_email_headers(struct rev_info *opt, struct commit *commit, int maybe_multipart); void load_ref_decorations(struct decoration_filter *filter, int flags); -#define FORMAT_PATCH_NAME_MAX 64 +#define FORMAT_PATCH_NAME_MAX 80 void fmt_output_commit(struct strbuf *, struct commit *, struct rev_info *); void fmt_output_subject(struct strbuf *, const char *subject, struct rev_info *); void fmt_output_email_subject(struct strbuf *, struct rev_info *); -- 2.18.0.huawei.25