mirror of https://github.com/Xhofe/alist
feat(local): add show hidden config (#2087)
parent
02df3759df
commit
da7e17aa38
|
@ -68,7 +68,7 @@ func (d *Local) List(ctx context.Context, dir model.Obj, args model.ListArgs) ([
|
|||
}
|
||||
var files []model.Obj
|
||||
for _, f := range rawFiles {
|
||||
if strings.HasPrefix(f.Name(), ".") {
|
||||
if !d.ShowHidden && strings.HasPrefix(f.Name(), ".") {
|
||||
continue
|
||||
}
|
||||
thumb := ""
|
||||
|
|
|
@ -7,7 +7,8 @@ import (
|
|||
|
||||
type Addition struct {
|
||||
driver.RootPath
|
||||
Thumbnail bool `json:"thumbnail" required:"true" help:"enable thumbnail"`
|
||||
Thumbnail bool `json:"thumbnail" required:"true" help:"enable thumbnail"`
|
||||
ShowHidden bool `json:"show_hidden" default:"true" required:"false" help:"show hidden directories and files"`
|
||||
}
|
||||
|
||||
var config = driver.Config{
|
||||
|
|
Loading…
Reference in New Issue