リポジトリのクローン時に以下のエラーメッセージが表示されて、一部のファイルしかダウンロードされない現象が発生。
![](https://i0.wp.com/juraku-software.net/wp-content/uploads/2022/10/GitHubError.png?resize=300%2C166&ssl=1)
このエラーメッセージだけだと分からないが、Visual Studioの出力ウィンドウには詳細のエラーが表示されていた。
git-lfs filter-process: git-lfs: command not found
リモート リポジトリの複製を作成中にエラーが発生しました: Git failed with a fatal error.
the remote end hung up unexpectedly
Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry with 'git restore --source=HEAD :/'
「git-lfs: command not found」とあるので、Git Large File Storage (LFS)のサイトから、「git-lfs-windows-v3.2.0.exe」をダウンロードする。
![](https://i0.wp.com/juraku-software.net/wp-content/uploads/2022/10/git_lfs_download.png?resize=300%2C126&ssl=1)
上記をインストール後、コマンドプロンプトで「git lfs install」を実行する。
念のため「git lfs version」を実行して、正常にインストールされていることを確認した。
![](https://i0.wp.com/juraku-software.net/wp-content/uploads/2022/10/git_lfs_install.png?resize=300%2C127&ssl=1)
そして、中途半端にダウンロードされたソースをフォルダごと削除して、Visual Studioを再起動後、再度リポジトリのクローンを実行したところ、正常にファイルをダウンロードできた。
エラーメッセージダイアログだけ見ても原因が分からないので注意!