pgindent truncates last line of files missing a trailing newline

Edit
ID 6489
Title pgindent truncates last line of files missing a trailing newline
CI (CFBot) Needs rebase! Needs rebase since 4 days. Failing since 5 days.
Additional links previous successfully applied patch (outdated):
Summary
Stats (from CFBot) Unknown
Tags Bugfix
Created 2026-02-16 14:42:07
Last modified 2026-03-28 10:40:33 (2 days ago)
Latest email 2026-03-29 02:26:35 (yesterday)
Status
PG19-Final (2026-03-01 – 2026-03-31): Committed
Target version
Authors Akshay Joshi (akshay.joshi)
Reviewers Become reviewer
Committer Tom Lane (tgl)
Links
Emails
[PATCH] pgindent truncates last line of files missing a trailing newline
First at 2026-02-16 14:09:46 by Akshay Joshi <akshay.joshi at enterprisedb.com>
Latest at 2026-03-29 02:26:35 by Bruce Momjian <bruce at momjian.us>
Latest attachment (v3-0001-Fix-pgindent-truncates-last-line-of-files.patch) at 2026-03-26 16:29:46 from Tom Lane <tgl at sss.pgh.pa.us>
    Attachment (v3-0001-Fix-pgindent-truncates-last-line-of-files.patch) at 2026-03-26 16:29:46 from Tom Lane <tgl at sss.pgh.pa.us> (Patch: Yes)
    Attachment (v2-0001-Fix-pgindent-truncates-last-line-of-files.patch) at 2026-02-17 07:54:05 from Akshay Joshi <akshay.joshi at enterprisedb.com> (Patch: Yes)
    Attachment (0001-Fix-pgindent-truncates-last-line-of-files.patch) at 2026-02-16 14:09:46 from Akshay Joshi <akshay.joshi at enterprisedb.com> (Patch: Yes)
History
When Who What
2026-03-28 10:40:33 Andrew Dunstan (adunstan) Closed in commitfest PG19-Final with status: Committed
2026-03-28 10:40:33 Andrew Dunstan (adunstan) Changed committer to tgl
2026-03-26 16:33:27 CFbot Patch needs rebase
2026-03-20 08:58:22 Akshay Joshi (akshay.joshi) New status: Ready for Committer
2026-02-16 14:42:08 Akshay Joshi (akshay.joshi) Attached mail thread CANxoLDfca8O5SkeDxB_j6SVNXd+pNKaDmVmEW+2yyicdU8fy0w@mail.gmail.com
2026-02-16 14:42:08 Akshay Joshi (akshay.joshi) Created patch record
Edit