mirror of
https://git.mills.io/prologic/zs
synced 2025-04-09 12:02:03 +00:00
added check for fs walk errors
This commit is contained in:
parent
61600d0951
commit
b31a2cc1ca
1 changed files with 5 additions and 0 deletions
5
zs.go
5
zs.go
|
@ -243,6 +243,11 @@ func buildAll(watch bool) {
|
||||||
if filepath.Base(path)[0] == '.' || strings.HasPrefix(path, ".") {
|
if filepath.Base(path)[0] == '.' || strings.HasPrefix(path, ".") {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
// inform user about fs walk errors, but continue iteration
|
||||||
|
if err != nil {
|
||||||
|
log.Println("ERROR:", err)
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
if info.IsDir() {
|
if info.IsDir() {
|
||||||
os.Mkdir(filepath.Join(PUBDIR, path), 0755)
|
os.Mkdir(filepath.Join(PUBDIR, path), 0755)
|
||||||
|
|
Loading…
Add table
Reference in a new issue