Skip to content

Commit 37df96e

Browse files
committed
fix(git_cmd): fix the object size for git command to avoid inconsistencies
1 parent de0b22e commit 37df96e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

extractor.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ type FastExtractor struct {
3232

3333
func (fe *FastExtractor) Run(path string) chan *GitFile {
3434
log.Infof("Extracting commits from path %s\n", path)
35-
cmdBase := "git rev-list --objects --all | git cat-file --batch-check='{\"sha\": \"%(objectname)\", \"type\": \"%(objecttype)\", \"filepath\": \"%(rest)\", \"size\": \"%(objectsize:disk)\"}' | grep '\"type\": \"blob\"'" //nolint
35+
cmdBase := "git rev-list --objects --all | git cat-file --batch-check='{\"sha\": \"%(objectname)\", \"type\": \"%(objecttype)\", \"filepath\": \"%(rest)\", \"size\": \"%(objectsize)\"}' | grep '\"type\": \"blob\"'" //nolint
3636
cmd := exec.Command("bash", "-c", cmdBase)
3737
cmd.Dir = path
3838

0 commit comments

Comments
 (0)