1
0
Fork 0
forked from forgejo/forgejo

Don't store assets modified time into generated files (#18193)

This commit is contained in:
Lunny Xiao 2022-01-07 10:33:17 +08:00 committed by GitHub
parent 21ed4fd8da
commit a1c12fb0b3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 110 additions and 22 deletions

View file

@ -26,6 +26,10 @@ type Options struct {
// VariableComment is the comment of the http.FileSystem variable in the generated code.
// If left empty, it defaults to "{{.VariableName}} statically implements the virtual filesystem provided to vfsgen.".
VariableComment string
// UseGlobalModTime indicates that not retrieve files' modified time if it's true. Once this
// is true, you have to define a function GlobalModTime(filename string) time.Time in the same package of generated files
UseGlobalModTime bool
}
// fillMissing sets default values for mandatory options that are left empty.