How to git diff without typing the whole path

前端 未结 4 650
太阳男子
太阳男子 2020-12-30 21:28

I\'m using the github windows shell and I\'ll do the following

git status

see a list of modified files and want to remind myself what\'s ch

4条回答
  •  [愿得一人]
    2020-12-30 22:23

    git diff -- **/FooBar.aspx
    

    In general * stands for any part of a filename while ** stands for any subpath. E.g. git diff -- **/main/**/*.aspx will diff only aspx files that are residing somewhere in a subdirectory of main or main itself. This applies to other commands that accept paths, like commit and add.

提交回复
热议问题