From: Larry Hunter <larhun.it@gmail.com>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: [Bug] git log --show-signature print extra carriage return ^M
Date: Tue, 6 Mar 2018 10:47:10 +0100 [thread overview]
Message-ID: <CAL+2DvR4ZBicrCYSkQ1jDaWaLJHgp8yVkKQZgxVc9txzHbNFkg@mail.gmail.com> (raw)
In-Reply-To: <nycvar.QRO.7.76.6.1803051457570.20700@ZVAVAG-6OXH6DA.rhebcr.pbec.zvpebfbsg.pbz>
The same ^M is shown in the output of tutorial
https://www.geekality.net/2017/08/23/setting-up-gpg-signing-for-gitgithub-on-windows/
at item "4. Verify commit was signed"
I confirm the output is right (no ^M characters) with commands
git verify-commit HEAD
git -p verify-commit HEAD
git verify-commit --v HEAD
git verify-commit --raw HEAD
and wrong (ending with ^M characters) with
git log --show-signature -1 HEAD
git -p log --show-signature -1 HEAD
I need gpg version 2.1 or greater to generate a gpg key for my windows
system, as stated by the github documentation:
https://help.github.com/articles/generating-a-new-gpg-key/
that saves my keys in ~/AppData/Roaming/GnuPG.
2018-03-05 15:29 GMT+01:00 Johannes Schindelin <Johannes.Schindelin@gmx.de>:
> Hi Larry,
>
> On Sun, 4 Mar 2018, Larry Hunter wrote:
>
>> There is bug using "git log --show-signature" in my installation
>>
>> git 2.16.2.windows.1
>> gpg (GnuPG) 2.2.4
>> libgcrypt 1.8.2
>
> The gpg.exe shipped in Git for Windows should say something like this:
>
> $ gpg --version
> gpg (GnuPG) 1.4.22
> Copyright (C) 2015 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later
> <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.
>
> Home: ~/.gnupg
> Supported algorithms:
> Pubkey: RSA, RSA-E, RSA-S, ELG-E, DSA
> Cipher: IDEA, 3DES, CAST5, BLOWFISH, AES, AES192, AES256, TWOFISH,
> CAMELLIA128, CAMELLIA192, CAMELLIA256
> Hash: MD5, SHA1, RIPEMD160, SHA256, SHA384, SHA512, SHA224
> Compression: Uncompressed, ZIP, ZLIB, BZIP2
>
> Therefore, the GNU Privacy Guard version you use is not the one shipped
> and supported by the Git for Windows project.
>
>> that prints (with colors) an extra ^M (carriage return?) at the end of
>> the gpg lines. As an example, the output of "git log --show-signature
>> HEAD" looks like:
>>
>> $ git log --show-signature HEAD
>> commit 46c490188ebd216f20c454ee61108e51b481844e (HEAD -> master)
>> gpg: Signature made 03/04/18 16:53:06 ora solare Europa occidentale^M
>> gpg: using RSA key ...^M
>> gpg: Good signature from "..." [ultimate]^M
>> Author: ... <...>
>> Date: Sun Mar 4 16:53:06 2018 +0100
>> ...
>>
>> To help find a fix, I tested the command "git verify-commit HEAD" that
>> prints (without colors) the same lines without extra ^M characters.
>>
>> $ git verify-commit HEAD
>> gpg: Signature made 03/04/18 16:53:06 ora solare Europa occidentale
>> gpg: using RSA key ...
>> gpg: Good signature from "..." [ultimate]
>
> My guess is that the latter command simply does not go through the pager
> while the former does.
>
> Do you see the ^M in the output of `git -p verify-commit HEAD`?
>
> Ciao,
> Johannes
next prev parent reply other threads:[~2018-03-06 9:47 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-04 17:09 [Bug] git log --show-signature print extra carriage return ^M Larry Hunter
2018-03-05 14:29 ` Johannes Schindelin
2018-03-06 9:47 ` Larry Hunter [this message]
2018-04-28 12:18 ` Johannes Schindelin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAL+2DvR4ZBicrCYSkQ1jDaWaLJHgp8yVkKQZgxVc9txzHbNFkg@mail.gmail.com \
--to=larhun.it@gmail.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).