You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

static.go 668B

1234567891011121314151617181920212223242526272829
  1. // +build bindata
  2. // Copyright 2016 The Gitea Authors. All rights reserved.
  3. // Use of this source code is governed by a MIT-style
  4. // license that can be found in the LICENSE file.
  5. package public
  6. import (
  7. "github.com/go-macaron/bindata"
  8. "gopkg.in/macaron.v1"
  9. )
  10. // Static implements the macaron static handler for serving assets.
  11. func Static(opts *Options) macaron.Handler {
  12. return macaron.Static(
  13. opts.Directory,
  14. macaron.StaticOptions{
  15. SkipLogging: opts.SkipLogging,
  16. FileSystem: bindata.Static(bindata.Options{
  17. Asset: Asset,
  18. AssetDir: AssetDir,
  19. AssetInfo: AssetInfo,
  20. AssetNames: AssetNames,
  21. Prefix: "",
  22. }),
  23. },
  24. )
  25. }