You can get them back. Even though the only thing pointing to it was the index, git add
still put the added content in the repo. I’d start with a git fsck
to find “dangling” (git’s slightly quirky spelling of “unreferenced”) blobs and git cat-file -p
those blobs, if there’s too many I’d do something like find .git/objects -type f | xargs ls -lt
.