lor
v0.3.4
中文 Bahasa Inggris
Kerangka kerja web yang cepat dan minimalis berdasarkan OpenResty.
local lor = require ( " lor.index " )
local app = lor ()
app : get ( " / " , function ( req , res , next )
res : send ( " hello world! " )
end )
app : run ()git clone https://github.com/sumory/lor
cd lor
make install LOR_HOME dan LORD_BIN didukung oleh Makefile , sehingga perintah berikut dapat digunakan untuk menyesuaikan instalasi:
make install LOR_HOME=/path/to/lor LORD_BIN=/path/to/lord
opm install didukung dari V0.2.2.
opm install sumory/lor
lord Cli tidak didukung dengan instalasi ini.
Anda dapat menggunakan homebrew-lor di Mac OSX.
$ brew tap syhily/lor
$ brew install lor
Middleware Cara cepat untuk memulai dengan LOR adalah dengan memanfaatkan alat CLI yang dapat dieksekusi lord untuk menghasilkan aplikasi perancah.
lord dipasang dengan kerangka kerja lor . Sepertinya:
$ lord -h
lor ${version} , a Lua web framework based on OpenResty.
Usage: lord COMMAND [OPTIONS]
Commands:
new [name] Create a new application
start Starts the server
stop Stops the server
restart Restart the server
version Show version of lor
help Show help tipsBuat Aplikasi:
$ lord new lor_demo
Mulai Server:
$ cd lor_demo && lord start
Kunjungi http: // localhost: 8888.
Instal Rusted, lalu Jalankan Tes
busted spec/*
https://github.com/syhily/homebrew-lor dikelola oleh @syhily
Mit