forked from botlabs-gg/yagpdb
-
Notifications
You must be signed in to change notification settings - Fork 0
/
assets_gen.go
278 lines (244 loc) · 8.71 KB
/
assets_gen.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
// Code generated by "esc -o assets_gen.go -pkg commands -ignore .go assets/"; DO NOT EDIT.
package commands
import (
"bytes"
"compress/gzip"
"encoding/base64"
"io/ioutil"
"net/http"
"os"
"path"
"sync"
"time"
)
type _escLocalFS struct{}
var _escLocal _escLocalFS
type _escStaticFS struct{}
var _escStatic _escStaticFS
type _escDirectory struct {
fs http.FileSystem
name string
}
type _escFile struct {
compressed string
size int64
modtime int64
local string
isDir bool
once sync.Once
data []byte
name string
}
func (_escLocalFS) Open(name string) (http.File, error) {
f, present := _escData[path.Clean(name)]
if !present {
return nil, os.ErrNotExist
}
return os.Open(f.local)
}
func (_escStaticFS) prepare(name string) (*_escFile, error) {
f, present := _escData[path.Clean(name)]
if !present {
return nil, os.ErrNotExist
}
var err error
f.once.Do(func() {
f.name = path.Base(name)
if f.size == 0 {
return
}
var gr *gzip.Reader
b64 := base64.NewDecoder(base64.StdEncoding, bytes.NewBufferString(f.compressed))
gr, err = gzip.NewReader(b64)
if err != nil {
return
}
f.data, err = ioutil.ReadAll(gr)
})
if err != nil {
return nil, err
}
return f, nil
}
func (fs _escStaticFS) Open(name string) (http.File, error) {
f, err := fs.prepare(name)
if err != nil {
return nil, err
}
return f.File()
}
func (dir _escDirectory) Open(name string) (http.File, error) {
return dir.fs.Open(dir.name + name)
}
func (f *_escFile) File() (http.File, error) {
type httpFile struct {
*bytes.Reader
*_escFile
}
return &httpFile{
Reader: bytes.NewReader(f.data),
_escFile: f,
}, nil
}
func (f *_escFile) Close() error {
return nil
}
func (f *_escFile) Readdir(count int) ([]os.FileInfo, error) {
return nil, nil
}
func (f *_escFile) Stat() (os.FileInfo, error) {
return f, nil
}
func (f *_escFile) Name() string {
return f.name
}
func (f *_escFile) Size() int64 {
return f.size
}
func (f *_escFile) Mode() os.FileMode {
return 0
}
func (f *_escFile) ModTime() time.Time {
return time.Unix(f.modtime, 0)
}
func (f *_escFile) IsDir() bool {
return f.isDir
}
func (f *_escFile) Sys() interface{} {
return f
}
// FS returns a http.Filesystem for the embedded assets. If useLocal is true,
// the filesystem's contents are instead used.
func FS(useLocal bool) http.FileSystem {
if useLocal {
return _escLocal
}
return _escStatic
}
// Dir returns a http.Filesystem for the embedded assets on a given prefix dir.
// If useLocal is true, the filesystem's contents are instead used.
func Dir(useLocal bool, name string) http.FileSystem {
if useLocal {
return _escDirectory{fs: _escLocal, name: name}
}
return _escDirectory{fs: _escStatic, name: name}
}
// FSByte returns the named file from the embedded assets. If useLocal is
// true, the filesystem's contents are instead used.
func FSByte(useLocal bool, name string) ([]byte, error) {
if useLocal {
f, err := _escLocal.Open(name)
if err != nil {
return nil, err
}
b, err := ioutil.ReadAll(f)
_ = f.Close()
return b, err
}
f, err := _escStatic.prepare(name)
if err != nil {
return nil, err
}
return f.data, nil
}
// FSMustByte is the same as FSByte, but panics if name is not present.
func FSMustByte(useLocal bool, name string) []byte {
b, err := FSByte(useLocal, name)
if err != nil {
panic(err)
}
return b
}
// FSString is the string version of FSByte.
func FSString(useLocal bool, name string) (string, error) {
b, err := FSByte(useLocal, name)
return string(b), err
}
// FSMustString is the string version of FSMustByte.
func FSMustString(useLocal bool, name string) string {
return string(FSMustByte(useLocal, name))
}
var _escData = map[string]*_escFile{
"/assets/commands.html": {
local: "assets/commands.html",
size: 11008,
modtime: 1521566046,
compressed: `
H4sIAAAAAAAC/+xa3Y/buBF/918xVQKcF3eWmuLQh0Y2sN1t06BALrjcS3E4LGhpZLGhSJWkvFkI+t8L
itSXLdnazxS95CFr8WuGvxn+ZoZSWcaYUI7gRflNJLKM8Fh5VbVYlKXGLGdE274USeyBX1WLMKZ7iBhR
au1JcettFgAA/dZIsBXbrd78yfXV/embpjsnO1yZ9VB6m3dMbAmDKysaFGpN+U6FQfqmNznffHIdoIoo
BaJgy0j0mVGlFZiJtynRXGggSYKRBsIY/Ovy3cfrv0KzqzDInapBTPfu5x9WKwj8VmFYrTYL138AAGEo
tXIQ2GlS3NoJiZAZSMFw7ZmfHmSoUxGvvVwo7QGJNBV87QUZ4WSHQVn6l5Gme3xXUBb776+rKmi0DBoE
ghFgO7jnQH44JiccGdT/r2JMSMH0wejRGbWpKN+NjDX/3iFHSVhrueMFO7hPy9mK+G5CyDQIp0Y6UP58
YvjhFGO+1U6KIj8zqZ7IyBYZJEKuvVxiQr94m4/13zCou2YsQXleaNB3Oa49jV+0N9AkElxLwTygcSsC
OMmwe9oTVuDaK0vfnaErwRO6860iVXVu8+PWmdv9ALTpxvf9uFDa9/0woA+SfarrMa5ydH6O5mwLrQV3
BlPFNqOdybaaw1bzVS5pRuRd/Zvt6j9bJqLPHmw+kT3W5PSpJTq74gYAnhCJkeaxJstjlhgMk02MHaXJ
Qyqd5ikz+5cUYWe5Pjrg+qHkI1qwp7E+ASSKhIyp4J5jW022JgR4Q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D2dL
3tla9S/lhkCJ/G6oj1HiSuR3zy05J0rjseiPpvkFC/0ZEWMiJNrA19f/RjhOummzvAmuagJgE/8WDw5p
z3JTMaimH3BfMazGm923177wqhvwgWQmIZhxQfGc9xDDDT/6NuJcnPh2E/E7u4lw/lBnYa2jzbuBaA7N
7/zW4WXqm85UXerSMX3X979WsL9cEQ4DiAwTjuLzrTj/ys57XKIP7POtUH+pQn3sLu2wlj/51n7um/rH
vZ3vXs5HR18jTbykH72R6L8ZDwPDHJuDL4b6SyxCFUma978BCf5N9sS2uk0mBa+/IYK2gLpNib4oW8mR
4Eow9JnYLb2aX00FRhjzfqg/jbpoR75eer73fd3mI4nSZbP2kv4AVGPWW9X8M01+cwbWoGWBb9sBlV23
MvsYKtqr9Q5UfaQCde59rIEVvycSTD23LRJX+K+BF4y9Pex1J3yquybWfl9nAFMtRpZEBvgPhf7629vD
vk7kSKcT2O+xODlR33ttLJ6H2kChX+lvsB4AeQTgmMQegd5LqNvpA6XWAfVe8gx4VtjrZT3K3xO2vJhy
ktaWtv4+NiZNloc2s75wIL7+JHDpfRA6Naetfo+TU2Oit0OakKgLyXv6LJ7Iygdn49Doz2PlcaGd0Z/a
yn2jDi0+ZuIwsMy5OfqENRFCo7RfcC5cPPpvAAAA//9QFn6/ACsAAA==
`,
},
"/assets/help-page.md": {
local: "assets/help-page.md",
size: 4653,
modtime: 1521566046,
compressed: `
H4sIAAAAAAAC/8xX3W/cNhJ/118xhzxkjW7kJEUOBwMHw7XboLjrB5wURt9MUSOJWYqjcqjd7GH/+MOQ
+trNxr5DXxrAWYma+Q35m0++ePEC3qNDr+xVdkttq1wJB7ixRjEyHOCXLhhyysKNr+X9Dll7ExezV+kf
HOCLp3PvWYO2gwP8fHkDB1jpZO0CDvChoR1D/FyRB2UtkAdyCNyhNpXRMEjnmXFbExAOYNx2DWbCu0fu
yDHCzoQGQoNQUIAdFizi1rhNxI7qSrYvUBVN+udQBEGEfDtoZMLXRyLL59m6xz9647Ec2fpT7D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