Initial commit

This commit is contained in:
2026-01-19 01:51:08 +02:00
commit 2dbb7e5d7e
18 changed files with 1475 additions and 0 deletions

30
ffs/util.go Normal file
View File

@@ -0,0 +1,30 @@
package ffs
import (
"strings"
"bazil.org/fuse"
"bazil.org/fuse/fs"
)
type TopLevelDir interface {
fs.Node
GetAttr() *fuse.Attr
}
func IsValidName(name string) bool {
l := len(name)
if l == 0 || l > 255 {
return false
}
if name == "." || name == ".." {
return false
}
if strings.ContainsRune(name, '/') {
return false
}
return true
}