Error with BFG Tool: Multiple File Attributes Causing Conversion Error

プラットフォームについて: Cloud と Data Center - この記事は クラウド プラットフォームとデータセンター プラットフォームの両方に等しく当てはまります。

Server* 製品のサポートは 2024 年 2 月 15 日に終了しました。Server 製品を実行している場合は、 アトラシアン Server サポート終了 のお知らせにアクセスして、移行オプションを確認してください。

*Fisheye および Crucible は除く

要約

The BFG tool is frequently used to clean up and alter the history of Git repositories. However, an issue arises when multiple file attributes are converted using the tool. During the Git LFS clone process, the multiple file extensions are being copied into one line instead of separate lines. This causes the LFS files not to be automatically pulled.

Multiple File Attributes to Conversion Error with BFG Tool

環境

本番環境

診断

The issue can be diagnosed by examining the .gitattributes file in the Git repository. If there are multiple file extensions listed in a single line, then the issue is confirmed. To address this, the .gitattributes file must contain a separate line for each file extension, with the proper LFS configuration. This will allow the Git LFS system to identify and pull the corresponding LFS files smoothly.

原因

The issue is caused by the improper formatting of multiple file attributes during the BFG tool conversion process. When the file extensions are joined together in a single line, it makes it difficult for the Git LFS system to identify and retrieve the corresponding LFS files.

*.{ext1,ext2,ext3,…} filter=lfs diff=lfs merge=lfs –text

ソリューション

To address the issue, separate the file extensions into individual lines within the .gitattributes file. By doing this, the Git LFS system will be able to correctly recognize and retrieve the corresponding LFS files during the cloning process.

*.ext1 filter=lfs diff=lfs merge=lfs –text *.ext2 filter=lfs diff=lfs merge=lfs –text *.ext3 filter=lfs diff=lfs merge=lfs –text
更新日時: September 26, 2025

さらにヘルプが必要ですか?

アトラシアン コミュニティをご利用ください。