diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2019-06-03 05:43:47 +0800 |
---|---|---|
committer | Lauris BH <lauris@nix.lv> | 2019-06-03 00:43:47 +0300 |
commit | 83b90e41999d30e4abb46f6bf0f1c3359cfd4d04 (patch) | |
tree | 4a15e9a42a850534a00346116da84153600a3027 /modules/options/main.go | |
parent | 8eba27c79257c6bc68cefbdffbb36d3596e6d3ee (diff) | |
download | gitea-83b90e41999d30e4abb46f6bf0f1c3359cfd4d04.tar.gz gitea-83b90e41999d30e4abb46f6bf0f1c3359cfd4d04.zip |
Use vfsgen instead of go-bindata (#7080)
* use vfsgen instead of go-bindata
* fix templates
* fix fmt
* vendor vsfgen
Diffstat (limited to 'modules/options/main.go')
-rw-r--r-- | modules/options/main.go | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/modules/options/main.go b/modules/options/main.go new file mode 100644 index 0000000000..0bc6c04e24 --- /dev/null +++ b/modules/options/main.go @@ -0,0 +1,23 @@ +// +build ignore + +package main + +import ( + "log" + "net/http" + + "github.com/shurcooL/vfsgen" +) + +func main() { + var fsTemplates http.FileSystem = http.Dir("../../options") + err := vfsgen.Generate(fsTemplates, vfsgen.Options{ + PackageName: "options", + BuildTags: "bindata", + VariableName: "Assets", + Filename: "bindata.go", + }) + if err != nil { + log.Fatal("%v", err) + } +} |