GIT_MEDIA_PROGRESS => HAWSER_PROGRESS
This commit is contained in:
parent
50ed75c495
commit
97edd110e6
@ -20,7 +20,7 @@ func TestSmudge(t *testing.T) {
|
||||
cmd := repo.Command("smudge", "somefile")
|
||||
cmd.Input = bytes.NewBufferString("version https://hawser.github.com/spec/v1\noid sha256:SOMEOID\nsize 9\n")
|
||||
cmd.Output = "whatever"
|
||||
cmd.Env = append(cmd.Env, "GIT_MEDIA_PROGRESS="+progressFile)
|
||||
cmd.Env = append(cmd.Env, "HAWSER_PROGRESS="+progressFile)
|
||||
|
||||
cmd.Before(func() {
|
||||
path := filepath.Join(repo.Path, ".git", "hawser", "objects", "SO", "ME")
|
||||
|
@ -44,13 +44,13 @@ func CopyWithCallback(writer io.Writer, reader io.Reader, totalSize int64, cb Co
|
||||
}
|
||||
|
||||
func CopyCallbackFile(event, filename string, index, totalFiles int) (CopyCallback, *os.File, error) {
|
||||
logPath := os.Getenv("GIT_MEDIA_PROGRESS")
|
||||
logPath := os.Getenv("HAWSER_PROGRESS")
|
||||
if len(logPath) == 0 || len(filename) == 0 || len(event) == 0 {
|
||||
return nil, nil, nil
|
||||
}
|
||||
|
||||
if !filepath.IsAbs(logPath) {
|
||||
return nil, nil, fmt.Errorf("GIT_MEDIA_PROGRESS must be an absolute path")
|
||||
return nil, nil, fmt.Errorf("HAWSER_PROGRESS must be an absolute path")
|
||||
}
|
||||
|
||||
cbDir := filepath.Dir(logPath)
|
||||
|
Loading…
Reference in New Issue
Block a user