moving assets into a dir

pull/8/head
Stephen Searles 8 years ago
parent d100cebfbe
commit e959b41f2c
  1. 2
      assets/assets.go
  2. 4
      assets/bindata.go
  3. 0
      assets/simplemde/.eslintrc
  4. 0
      assets/simplemde/.gitignore
  5. 0
      assets/simplemde/.travis.yml
  6. 0
      assets/simplemde/CONTRIBUTING.md
  7. 0
      assets/simplemde/LICENSE
  8. 0
      assets/simplemde/README.md
  9. 0
      assets/simplemde/bower.json
  10. 0
      assets/simplemde/debug/simplemde.css
  11. 0
      assets/simplemde/debug/simplemde.debug.js
  12. 0
      assets/simplemde/debug/simplemde.js
  13. 0
      assets/simplemde/dist/simplemde.min.css
  14. 0
      assets/simplemde/dist/simplemde.min.js
  15. 0
      assets/simplemde/gulpfile.js
  16. 0
      assets/simplemde/package.json
  17. 0
      assets/simplemde/src/css/simplemde.css
  18. 0
      assets/simplemde/src/js/codemirror/tablist.js
  19. 0
      assets/simplemde/src/js/simplemde.js
  20. 6
      caddyhugo.go

@ -0,0 +1,2 @@
//go:generate go-bindata -pkg assets simplemde/dist/... simplemde/debug/...
package assets

@ -8,7 +8,7 @@
// require.js // require.js
// DO NOT EDIT! // DO NOT EDIT!
package caddyhugo package assets
import ( import (
"bytes" "bytes"
@ -292,6 +292,7 @@ type bintree struct {
Func func() (*asset, error) Func func() (*asset, error)
Children map[string]*bintree Children map[string]*bintree
} }
var _bintree = &bintree{nil, map[string]*bintree{ var _bintree = &bintree{nil, map[string]*bintree{
"require.js": &bintree{requireJs, map[string]*bintree{}}, "require.js": &bintree{requireJs, map[string]*bintree{}},
"simplemde": &bintree{nil, map[string]*bintree{ "simplemde": &bintree{nil, map[string]*bintree{
@ -353,4 +354,3 @@ func _filePath(dir, name string) string {
cannonicalName := strings.Replace(name, "\\", "/", -1) cannonicalName := strings.Replace(name, "\\", "/", -1)
return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...) return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...)
} }

@ -1,4 +1,3 @@
//go:generate go-bindata -pkg caddyhugo simplemde/dist/... simplemde/debug/...
package caddyhugo package caddyhugo
import ( import (
@ -18,6 +17,7 @@ import (
"time" "time"
"git.stephensearles.com/stephen/acedoc" "git.stephensearles.com/stephen/acedoc"
"git.stephensearles.com/stephen/caddy-hugo2/assets"
"github.com/gorilla/websocket" "github.com/gorilla/websocket"
"github.com/mholt/caddy" "github.com/mholt/caddy"
@ -146,11 +146,11 @@ func (ch *CaddyHugo) ServeHTTPWithNext(next httpserver.Handler, c *caddy.Control
return http.StatusFound, nil return http.StatusFound, nil
} }
if strings.HasPrefix(r.URL.Path, "/hugo/simplemde.css") { if strings.HasPrefix(r.URL.Path, "/hugo/simplemde.css") {
w.Write(MustAsset("simplemde/dist/simplemde.min.css")) w.Write(assets.MustAsset("simplemde/dist/simplemde.min.css"))
return http.StatusOK, nil return http.StatusOK, nil
} }
if strings.HasPrefix(r.URL.Path, "/hugo/simplemde.js") { if strings.HasPrefix(r.URL.Path, "/hugo/simplemde.js") {
w.Write(MustAsset("simplemde/debug/simplemde.js")) w.Write(assets.MustAsset("simplemde/debug/simplemde.js"))
return http.StatusOK, nil return http.StatusOK, nil
} }
if strings.HasPrefix(r.URL.Path, "/hugo/admin") { if strings.HasPrefix(r.URL.Path, "/hugo/admin") {

Loading…
Cancel
Save