Make paths output consistent with git status, i.e. relative to cwd

This commit is contained in:
rubyist 2014-05-28 13:56:56 -04:00 committed by Rick Olson
parent 09fe9588a9
commit e1ede045c9

@ -164,7 +164,9 @@ func findPaths() []mediaPath {
if strings.Contains(line, "filter=media") {
fields := strings.Fields(line)
paths = append(paths, mediaPath{Path: fields[0], Source: path})
wd, _ := os.Getwd()
relPath, _ := filepath.Rel(wd, path)
paths = append(paths, mediaPath{Path: fields[0], Source: relPath})
}
}
}