DEV Community

Dumb Down Demistifying Dev
Dumb Down Demistifying Dev

Posted on

Useful lesser known Git commands

Just some useful tips that will be further added with more commands that should be useful to take note of and aids in increasing productivity when working with GIT.

Commands

When you want to get all files that have been modified in git branch:

# i.e.
git diff --name-only <notMainDev> $(git merge-base <notMainDev> <mainDev>)

# e.g.
git diff --name-only feature-branch-a $(git merge-base master feature-branch-a)
Enter fullscreen mode Exit fullscreen mode

Oldest comments (0)