[pacman-dev] Fix srcinfo sometimes printing double newline at the end

Denton Liu liu.denton at gmail.com
Thu Jun 25 23:27:33 UTC 2020


Hi Marti,

On Fri, Jun 26, 2020 at 01:09:54AM +0200, Martin Rys wrote:
> Hi,
> this is a bit of an OCD thing, but `makepkg --printsrcinfo` usually
> generates a file with two newlines at the end.

I agree with you, this bugs me a lot too.

[...]

> Which seems to always print out a newline, so I believe the
> srcinfo_close_section function is not needed there and simply
> removing it and the two lines that call it would solve this issue, as
> per the patchfile in the attachment.

I proposed a similar patch recently[0] but it was rejected as the
newline separators are apparently part of the spec so they should be
retained[1]. I sent out another patch after that only removes the final
newline but it wasn't reviewed so I thought that the pacman devs thought
it was a non-issue. Since you seem to agree with me, though, I'll resend
that patch and hopefully it'll be reviewed this time around.

Thanks,

Denton

[0]: https://lists.archlinux.org/pipermail/pacman-dev/2020-June/024399.html
[1]: https://lists.archlinux.org/pipermail/pacman-dev/2020-June/024405.html


More information about the pacman-dev mailing list