git log only folder 1

git log only folder

git log -p 8a5fb..HEAD -- A B

commit 62ad8c5d
Author: Scott Tiger
Date:   Mon Nov 27 14:25:29 2017 +0100

    My comment

...
@@ -216,6 +216,10 @@ public class MyClass {

+  Added
-  Deleted

Here is what the above code is Doing:
1. git log -p 8a5fb..HEAD — A B
2. git log -p 8a5fb..HEAD — A B | grep -E ‘^\+’
3. git log -p 8a5fb..HEAD — A B | grep -E ‘^\+’ | grep -v ‘^\+\+\+’
4. git log -p 8a5fb..HEAD — A B | grep -E ‘^\+’ | grep -v ‘^\+\+\+’ | sed ‘s/^\+//’
5. git log -p 8a5fb..HEAD — A B | grep -E ‘^\+’ | grep -v ‘^\+\+\+’ | sed ‘s/^\+//’ | sort | uniq
6. git log -p 8a5fb..HEAD — A B | grep -E ‘^\+’ | grep -v ‘^\+\+\+’ | sed ‘s/^\+//’ | sort | uniq | wc -l

Similar Posts