fix: silently go away if we face permissions errors

This commit is contained in:
decentral1se 2022-02-01 18:53:09 +01:00
parent d2a56656b6
commit 192ea75a9d
No known key found for this signature in database
GPG Key ID: 03789458B3D0C410

View File

@ -259,10 +259,10 @@ func distribusify(c *cli.Context, root string, ignore []string) error {
if content.Name() == "index.html" {
file, err := os.ReadFile(path.Join(absPath, content.Name()))
if err != nil {
return err
return filepath.SkipDir
}
if strings.Contains(string(file), generatedInDistribusi) {
continue
return filepath.SkipDir
}
}
files = append(files, path.Join(absPath, content.Name()))