gitea: Index | Files

package public

import ""


Package Files

dynamic.go public.go


var KnownPublicEntries = []string{

KnownPublicEntries list all direct children in the `public` directory

func Custom Uses

func Custom(opts *Options) macaron.Handler

Custom implements the macaron static handler for serving custom assets.

func GenerateETag Uses

func GenerateETag(fileSize, fileName, modTime string) string

GenerateETag generates an ETag based on size, filename and file modification time

func Static Uses

func Static(opts *Options) macaron.Handler

Static implements the macaron static handler for serving assets.

func StaticHandler Uses

func StaticHandler(dir string, opts *Options) macaron.Handler

StaticHandler sets up a new middleware for serving static files in the

type Options Uses

type Options struct {
    Directory   string
    IndexFile   string
    SkipLogging bool
    // if set to true, will enable caching. Expires header will also be set to
    // expire after the defined time.
    ExpiresAfter time.Duration
    FileSystem   http.FileSystem
    Prefix       string

Options represents the available options to configure the macaron handler.

Package public imports 9 packages (graph) and is imported by 25 packages. Updated 2020-07-28. Refresh now. Tools for package owners.