mirror of
https://github.com/filebrowser/filebrowser.git
synced 2024-06-07 23:00:43 +00:00
updates
This commit is contained in:
parent
0797fde4e3
commit
b81ec9ecdf
0
assets/public/css/styles.css
Normal file
0
assets/public/css/styles.css
Normal file
0
assets/public/js/application.js
Normal file
0
assets/public/js/application.js
Normal file
48
binary.go
48
binary.go
@ -1,5 +1,7 @@
|
||||
// Code generated by go-bindata.
|
||||
// sources:
|
||||
// assets/public/css/styles.css
|
||||
// assets/public/js/application.js
|
||||
// assets/templates/editor.tmpl
|
||||
// assets/templates/frontmatter.tmpl
|
||||
// DO NOT EDIT!
|
||||
@ -28,6 +30,42 @@ type asset struct {
|
||||
info os.FileInfo
|
||||
}
|
||||
|
||||
// publicCssStylesCss reads file data from disk. It returns an error on failure.
|
||||
func publicCssStylesCss() (*asset, error) {
|
||||
path := "D:\\Code\\Go\\src\\github.com\\hacdias\\caddy-hugo\\assets\\public\\css\\styles.css"
|
||||
name := "public/css/styles.css"
|
||||
bytes, err := bindataRead(path, name)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
fi, err := os.Stat(path)
|
||||
if err != nil {
|
||||
err = fmt.Errorf("Error reading asset info %s at %s: %v", name, path, err)
|
||||
}
|
||||
|
||||
a := &asset{bytes: bytes, info: fi}
|
||||
return a, err
|
||||
}
|
||||
|
||||
// publicJsApplicationJs reads file data from disk. It returns an error on failure.
|
||||
func publicJsApplicationJs() (*asset, error) {
|
||||
path := "D:\\Code\\Go\\src\\github.com\\hacdias\\caddy-hugo\\assets\\public\\js\\application.js"
|
||||
name := "public/js/application.js"
|
||||
bytes, err := bindataRead(path, name)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
fi, err := os.Stat(path)
|
||||
if err != nil {
|
||||
err = fmt.Errorf("Error reading asset info %s at %s: %v", name, path, err)
|
||||
}
|
||||
|
||||
a := &asset{bytes: bytes, info: fi}
|
||||
return a, err
|
||||
}
|
||||
|
||||
// templatesEditorTmpl reads file data from disk. It returns an error on failure.
|
||||
func templatesEditorTmpl() (*asset, error) {
|
||||
path := "D:\\Code\\Go\\src\\github.com\\hacdias\\caddy-hugo\\assets\\templates\\editor.tmpl"
|
||||
@ -116,6 +154,8 @@ func AssetNames() []string {
|
||||
|
||||
// _bindata is a table, holding each asset generator, mapped to its name.
|
||||
var _bindata = map[string]func() (*asset, error){
|
||||
"public/css/styles.css": publicCssStylesCss,
|
||||
"public/js/application.js": publicJsApplicationJs,
|
||||
"templates/editor.tmpl": templatesEditorTmpl,
|
||||
"templates/frontmatter.tmpl": templatesFrontmatterTmpl,
|
||||
}
|
||||
@ -160,6 +200,14 @@ type bintree struct {
|
||||
Children map[string]*bintree
|
||||
}
|
||||
var _bintree = &bintree{nil, map[string]*bintree{
|
||||
"public": &bintree{nil, map[string]*bintree{
|
||||
"css": &bintree{nil, map[string]*bintree{
|
||||
"styles.css": &bintree{publicCssStylesCss, map[string]*bintree{}},
|
||||
}},
|
||||
"js": &bintree{nil, map[string]*bintree{
|
||||
"application.js": &bintree{publicJsApplicationJs, map[string]*bintree{}},
|
||||
}},
|
||||
}},
|
||||
"templates": &bintree{nil, map[string]*bintree{
|
||||
"editor.tmpl": &bintree{templatesEditorTmpl, map[string]*bintree{}},
|
||||
"frontmatter.tmpl": &bintree{templatesFrontmatterTmpl, map[string]*bintree{}},
|
||||
|
10
setup.go
10
setup.go
@ -96,6 +96,14 @@ func ParseHugo(c *caddy.Controller, root string) (*Config, error) {
|
||||
Hugo: installer.GetPath(),
|
||||
}
|
||||
|
||||
stlsbytes, err := Asset("public/css/styles.css")
|
||||
|
||||
if err != nil {
|
||||
return conf, err
|
||||
}
|
||||
|
||||
conf.Styles = string(stlsbytes)
|
||||
|
||||
for c.Next() {
|
||||
args := c.RemainingArgs()
|
||||
|
||||
@ -116,7 +124,7 @@ func ParseHugo(c *caddy.Controller, root string) (*Config, error) {
|
||||
if err != nil {
|
||||
return conf, err
|
||||
}
|
||||
conf.Styles = string(stylesheet)
|
||||
conf.Styles += string(stylesheet)
|
||||
case "admin":
|
||||
if !c.NextArg() {
|
||||
return nil, c.ArgErr()
|
||||
|
Loading…
Reference in New Issue
Block a user