git checkout
@rubyu2 试验方法错了,确实可以
试了下
git checkout <commit> <file>
只放入工作区,不会自动放入暂存区
git checkout HEAD file
同时也会清空暂存区