Create commit API does not respect LFS tracking rules
The create commit API doesn't create LFS pointers when specified by the .gitattributes
files. This causes problem in the Web IDE which uses the API and for any API consumers by causing the project to enter an invalid state.
https://docs.gitlab.com/ce/api/commits.html#create-a-commit-with-multiple-files-and-actions
Why
Not doing so results in the repo being in an invalid state, with changes to the working tree made by git on checkout.
Related
- https://gitlab.com/gitlab-org/gitlab-ce/issues/29876
- I've got a prototype fix in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/16412/diffs?diff_id=10308883#8823ce29beae0c9af8b935076bfe9ea4192295f9 at https://gitlab.com/gitlab-org/gitlab-ce/commit/da520419d7ceb5d3247d874c2928666d60e1fa22, but will likely split that into a new MR
Edited by James Ramsay (ex-GitLab)