DEV Community

C.OG
C.OG

Posted on

Git: Exclude a folder when diffing

When doing a git diff, especially between branches, you may be greeted with a mountain of changes that you have to sift through to find what you're looking for.

Consider excluding certain folders:

git diff -- ':!<folder-name>'

You can also exclude multiple folders:

git diff -- ':!<folder-name>' ':!<other-folder>'`

Top comments (0)