Skip to content

Commit ff6b4ba

Browse files
author
jguerreiro
committed
fix(cli): fix message logging
1 parent aeabbe4 commit ff6b4ba

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

extractor.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ type FastExtractor struct {
3131
}
3232

3333
func (fe *FastExtractor) Run(path string) chan *GitFile {
34-
log.Infof("Extracting commits from path %s", path)
34+
log.Infof("Extracting commits from path %s\n", path)
3535
cmdBase := "git rev-list --objects --all | git cat-file --batch-check='{\"sha\": \"%(objectname)\", \"type\": \"%(objecttype)\", \"filepath\": \"%(rest)\", \"size\": \"%(objectsize:disk)\"}' | grep '\"type\": \"blob\"'" //nolint
3636
cmd := exec.Command("bash", "-c", cmdBase)
3737
cmd.Dir = path
@@ -53,7 +53,7 @@ func (fe *FastExtractor) Run(path string) chan *GitFile {
5353
for {
5454
line, _, _ := buf.ReadLine()
5555
if len(line) == 0 {
56-
log.Info("finish reading all files from stdout from git")
56+
log.Infoln("finished reading all files from stdout from git")
5757

5858
break
5959
}
@@ -73,8 +73,8 @@ func (fe *FastExtractor) Run(path string) chan *GitFile {
7373
}
7474

7575
close(fe.ChanGitFiles)
76-
log.Info("channel is closed")
77-
log.Infof("finishing iterating over files, we have collected %d files", num)
76+
log.Infoln("channel is closed")
77+
log.Infof("finishing iterating over files, we have collected %d files\n", num)
7878

7979
if err := os.RemoveAll(path); err != nil {
8080
log.Errorln("Unable to remove directory ", path)

pipeline.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ func (p *Pipeline) gather(
8686
output <- repository
8787
}
8888

89-
log.Info("Done gathering repositories")
89+
log.Infoln("Done gathering repositories")
9090
}
9191

9292
// ExtractRepository extracts for a single repository.

0 commit comments

Comments
 (0)