To count the number of lines added/edited between two commits or branches:

git diff --stat <commit or branch> <commit or branch>