mirror of https://github.com/perkeep/perkeep.git
make: copy all files found in testdata/
This saves people from needing to updating rxMirrored every time they add a new type of file to their tests. Change-Id: I32f87dbe92ae844e411ce77d0abe67c37a668ff3
This commit is contained in:
parent
e3cdaf4f27
commit
77d36bf198
4
make.go
4
make.go
|
@ -515,7 +515,9 @@ func walkDir(src string, opts walkOpts) (maxMod time.Time, err error) {
|
|||
}
|
||||
return nil
|
||||
}
|
||||
if strings.HasPrefix(base, ".#") || !rxMirrored.MatchString(base) {
|
||||
dir, _ := filepath.Split(path)
|
||||
parent := filepath.Base(dir)
|
||||
if (strings.HasPrefix(base, ".#") || !rxMirrored.MatchString(base)) && parent != "testdata" {
|
||||
return nil
|
||||
}
|
||||
suffix, err := filepath.Rel(src, path)
|
||||
|
|
Loading…
Reference in New Issue