读书人

强力的lua patch支持lua终端代码揭示

发布时间: 2012-09-04 14:19:30 作者: rapoo

强力的lua patch,支持lua终端代码提示

地址:http://lua-users.org/wiki/LuaPowerPatchesAdvanced readline support (5.2, 5.1, 5.0)

This patch adds the following features to the existing readline support in Lua 5.x:

?

Completion of keywords and global variable names.Recursive and metatable-aware completion of variable names.Context sensitive delimiter completion.Save/restore the history to/from a file (LUA_HISTORY?env variable).Set a limit for the size of the history (LUA_HISTSIZE?env variable).Set the app name to allow for?$if lua ... $endif?in?~/.inputrc.

After applying the patch start Lua and try these (replace?~?with the TAB key):

~~fu~foo() ret~fa~end<CR>io~~~s~~~o~~~w~"foo\n")<CR>

读书人网 >编程

热点推荐