From: Junio C Hamano <gitster@pobox.com>
To: Thomas Nemeth <tnemeth@free.fr>
Cc: git@vger.kernel.org
Subject: Re: Git trailing blank lines feature configuration
Date: Fri, 31 Jul 2026 08:50:26 -0700 [thread overview]
Message-ID: <xmqqy0ercg59.fsf@gitster.g> (raw)
In-Reply-To: <6022080.DvuYhMxLoT@cixi> (Thomas Nemeth's message of "Fri, 31 Jul 2026 12:19:09 +0200")
Thomas Nemeth <tnemeth@free.fr> writes:
> Hi !
>
> I have the habit to keep 1 blank line at the end of my files. To me,
> it eases the EOF modifications (selecting code blocks, pasting them)
> in vim.
>
> Note that I still want to remove blanks at EOL. But I'd like to keep
> 1 blank trailing line. I still can, of course, but the diff still
> shows me a red "+"...
>
> Would it be possible to have a configuration option to avoid warnings
> (because I see that as a warning) about trailing blank lines ?
>
> Thanks
>
> Thomas.
Would it be possible with the current system? No.
Would it be possible to add such a new feature? If designed well,
perhaps.
Things to consider (though not exhaustive) include:
- What mechanism should this modify?
- What should the new option be called?
- Do we only need to accommodate those who want one trailing blank
line? What about those who want two? Three?
Thanks.
prev parent reply other threads:[~2026-07-31 15:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-31 10:19 Git trailing blank lines feature configuration Thomas Nemeth
2026-07-31 11:08 ` Johannes Sixt
2026-07-31 11:50 ` Thomas Nemeth
2026-07-31 18:49 ` Junio C Hamano
2026-07-31 15:50 ` Junio C Hamano [this message]
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqy0ercg59.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=tnemeth@free.fr \
/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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox