EvandroLG / pegasus.lua

:rocket: Pegasus.lua is an http server to work with web applications written in Lua language.
http://evandrolg.github.io/pegasus.lua/
MIT License
418 stars 36 forks source link

refactor(files) move serving files into a plugin #130

Closed Tieske closed 7 months ago

Tieske commented 1 year ago

This builds on top of #127

this reduces the 'handler' to primary task of running plugins

EvandroLG commented 1 year ago

I think we should add more unit tests here. We have entire new modules without any tests.

Tieske commented 10 months ago

Finally had some time to write the tests for the 2 new files; test for the json lib, and the files-plugin.

Tieske commented 8 months ago

@EvandroLG I rebased the PR, afetr some of the commits were merged via other PR's. What's left is hard to simplify due to conflicts that would arise.

Please have another look.

Tieske commented 7 months ago

@EvandroLG anything I can do to get this moving?

EvandroLG commented 7 months ago

Super nice stuff, @Tieske! Thanks! :) Can you update the Native Plugins section with an example of how to use the File plugin? We also need to update the rockspec and add the new plugin. Can you please do that?

Tieske commented 7 months ago

Added the requested docs. Accidentally also pushed the router plugin, but removed that commit again. The files plugin was already in the rockspec.

So all changed as requested.

EvandroLG commented 7 months ago

Looks great, @Tieske! Thanks!