-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Use vfsgen instead of go-bindata #7080
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I personally use gorunpkg to execute scripts from modules instead of adding this kind of run wrapper :) |
Script will be only invoked on mac/linux, but a go wrapper will be called much platforms. |
Codecov Report
@@ Coverage Diff @@
## master #7080 +/- ##
==========================================
- Coverage 41.54% 41.53% -0.01%
==========================================
Files 446 446
Lines 60825 60825
==========================================
- Hits 25267 25261 -6
- Misses 32273 32280 +7
+ Partials 3285 3284 -1
Continue to review full report at Codecov.
|
It's ready to review. |
I noticed that this PR will increase gitea start memory from 64MB to 81MB on macOS. Should I enable some compress? |
@lunny if you think it will help - sometimes compression can actually even speed things up! |
@zeripath yes, for public resouces(except images), we could directly provide compressed bytes to browser. Currently vsfgen will always save compressed bytes on memory with a map. So for a HTTP request, it will be decompress and compress. This will waste some CPUs. I will send another PR to resolve that. |
* use vfsgen instead of go-bindata * fix templates * fix fmt * vendor vsfgen
The embed package
github.com/shurcooL/vfsgen
has been vendored and will be invoke ongo generate ./modules/...
. So gitea build process will not be broken even the embed package API changed or not maintained. This should fix #4250.@lafriks @tboerger maybe you can give some ideas.
@lafriks Just noticed your comment at #4250 (comment) .