feat(drivers): add BaiduYun share link support (#3801)

新增百度网盘分享链接挂载
This commit is contained in:
Brian
2023-03-12 14:00:11 +08:00
committed by GitHub
parent adc3a56552
commit 2a601f06cb
5 changed files with 210 additions and 0 deletions

View File

@ -0,0 +1,34 @@
package baidu_share
import (
"github.com/alist-org/alist/v3/internal/driver"
"github.com/alist-org/alist/v3/internal/op"
)
type Addition struct {
// Usually one of two
driver.RootPath
// driver.RootID
// define other
// Field string `json:"field" type:"select" required:"true" options:"a,b,c" default:"a"`
Surl string `json:"surl"`
Pwd string `json:"pwd"`
BDUSS string `json:"BDUSS"`
}
var config = driver.Config{
Name: "BaiduShare",
LocalSort: true,
OnlyLocal: false,
OnlyProxy: false,
NoCache: false,
NoUpload: true,
NeedMs: false,
DefaultRoot: "",
}
func init() {
op.RegisterDriver(func() driver.Driver {
return &BaiduShare{}
})
}