From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id E896F138359 for ; Wed, 7 Oct 2020 10:07:31 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3781FE086B; Wed, 7 Oct 2020 10:07:31 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 21D6DE086B for ; Wed, 7 Oct 2020 10:07:31 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D832633BEDD for ; Wed, 7 Oct 2020 10:07:29 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 95035332 for ; Wed, 7 Oct 2020 10:07:28 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1602065236.3d90ee5686e54fb1c3242f10e644a789579a4372.mgorny@gentoo> Subject: [gentoo-commits] proj/gentoo-syntax:master commit in: plugin/ X-VCS-Repository: proj/gentoo-syntax X-VCS-Files: plugin/gentoo-common.vim X-VCS-Directories: plugin/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 3d90ee5686e54fb1c3242f10e644a789579a4372 X-VCS-Branch: master Date: Wed, 7 Oct 2020 10:07:28 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 176fce7d-97ed-45c6-b795-a9a4db9526eb X-Archives-Hash: e4e5185df6f9e6fcebb5d95fb9ad6a70 commit: 3d90ee5686e54fb1c3242f10e644a789579a4372 Author: Freed-Wu qq com> AuthorDate: Wed Sep 23 13:34:24 2020 +0000 Commit: Michał Górny gentoo org> CommitDate: Wed Oct 7 10:07:16 2020 +0000 URL: https://gitweb.gentoo.org/proj/gentoo-syntax.git/commit/?id=3d90ee56 Add trim for GentooGetUser() Signed-off-by: 吴振宇 qq.com> Closes: https://github.com/gentoo/gentoo-syntax/pull/31 Signed-off-by: Michał Górny gentoo.org> plugin/gentoo-common.vim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugin/gentoo-common.vim b/plugin/gentoo-common.vim index a15636a..1c9f4ed 100644 --- a/plugin/gentoo-common.vim +++ b/plugin/gentoo-common.vim @@ -13,8 +13,8 @@ let g:loaded_gentoo_common=1 fun! GentooGetUser() let l:result = expand("\$ECHANGELOG_USER") if l:result ==# "\$ECHANGELOG_USER" - let l:email = executable('git') ? system('git config --global user.email') : expand('$HOST') - let l:name = executable('git') ? system('git config --global user.name') : expand('$USER') + let l:email = executable('git') ? trim(system('git config --global user.email')) : expand('$HOST') + let l:name = executable('git') ? trim(system('git config --global user.name')) : expand('$USER') let l:result = l:name . ' <' . l:email . '>' endif return l:result