How does git retrieve files lost due to gitignore changes

  git, question

The company synchronizes an item with the computer at home, and the subdirectory of imgs should be ignored.
Gitignore file writing imgs/*/
The company computer changed the name of imgs to img, and the gitignore file was changed to img/*/ and committed.
After the home computer git pull, the original imgs disappeared. Git reset back is no good. imgs appears, but the subdirectory in imgs is missing.
How to restore the state before git pull and retrieve the subdirectories of imgs

Turngit logFind the previouscommit id, roll back to the corresponding version to see.