Handle empty directories more gracefully
This commit is contained in:
3
main.go
3
main.go
@ -383,7 +383,8 @@ func genDocs() error {
|
||||
},
|
||||
// Define callback to run after processing all children for a directory.
|
||||
PostChildrenCallback: func(path string, de *walk.Dirent) error {
|
||||
if !(pkgs[path].isGoPkg) {
|
||||
// Skip packages that don't contain go files or sub packages.
|
||||
if !(pkgs[path].isGoPkg) && len(pkgs[path].subPkgs.ToSlice()) == 0 {
|
||||
return nil
|
||||
}
|
||||
verboseLogf("Generating Documentation for %s", path)
|
||||
|
Reference in New Issue
Block a user