Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Commit list preview merging line breaks after running BFG

Glecko August 23, 2025

I've ran BFG on several of my repos (see r****s, and r****s-t***s) using BFG (deleting large blobs and adding files to LFS).

After force-pushing to bitbucket, my commit previews (e.g. on the "Commits" section) now displays texts from all commit message lines, not just the subject line.

This, together with the fact that BFG has added newlines with "Former-commit-id" to all commits, makes the whole section unreadable and spammy.

Example:

Screenshot 2025-08-23 100252.png

It doesn't seem to be an issue with BFG, which has correctly added the extra text in the body, after a line break:

Screenshot 2025-08-23 100348.png

I can run a regex with git filter-branch to remove the former-commit-id texts. But several of my commits had messages beyond the first line, which now also display like this, so this would only slightly mitigate the issue, not fix it.

1 answer

0 votes
Mark C
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 24, 2025

Hi @Glecko

Welcome to the community.

This is currently an expected outcome when using the BFG tool where it adds the former commit to the existing commit after the re-write for tracking purposes. This is a known behaviour of the tool.

Indeed, an alternative is to use git filter-branch you mentioned. - https://github.com/rtyley/bfg-repo-cleaner/issues/102

Regards,
Mark C

Glecko August 25, 2025

Hey @Mark C 

I am aware this is an expected outcome of BFG (mentioned in the original post).

What I don't think is an expected outcome is the Bitbucket web UI ignoring line breaks when determining a commit list preview message.

And as mentioned in the original post, git filter-branch is not a valid solution for me.

Mark C
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 2, 2025

Hi @Glecko

I went ahead and raised this to our team.

You can find the public ticket here where you can upvote and watch. - https://jira.atlassian.com/browse/BCLOUD-23847

We appreciate your patience and understanding as we continue to improve Bitbucket Cloud according to our policy on implementing new features.

Regards,
Mark C

Glecko September 2, 2025

Hey there @Mark C 

The public ticket doesn't really capture the core of the issue. The issue at hand is that when you preview a commit, it displays text from all lines (subject & body) of the commit message. I expect it to only display text from the subject. Or, if we really need the body to be rendered in other use cases, I'd expect it to be formatted differently.

Running BFG isn't the root cause, I just mentioned it because it's a standarised / common example where the commit previews become extremely unreadable.

But the same thing happens if I manually push a commit with the following format:

Fix some pesky issue

Contains a cherry-pick of: github.com/UnrealEngine/agu3890u3249h34ygu4g43890gvhsegu48

The root cause was lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua... (long text continues)

The preview will be spammed with the commit link hash, while ideally I'd just like it to read Fix some pesky issue

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events