Skip to content

Commit 0acceb8

Browse files
committed
Allowed follow of files in log
1 parent 8c2a68d commit 0acceb8

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Git.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -646,11 +646,16 @@ public function pull($remote, $branch) {
646646
* @param strgin $format
647647
* @return string
648648
*/
649-
public function log($format = null, $fulldiff=false, $filepath=null) {
649+
public function log($format = null, $fulldiff=false, $filepath=null, $follow=false) {
650650

651651
if ($fulldiff){
652652
$diff = "--full-diff -p ";
653653
}
654+
655+
if ($follow){
656+
// Can't use full-diff with follow
657+
$diff = "--follow -- ";
658+
}
654659

655660
if ($format === null)
656661
return $this->run('log ' . $diff . $filepath);

0 commit comments

Comments
 (0)