Add function my-git-apply-index-from-buffer