标签:
一、下载并安装
(1)最新release版下载地址
http://www.lua.org/ftp/lua-5.3.1.tar.gz
(2)编译
Lua is implemented in pure ANSI C and compiles unmodified in all platforms that have an ANSI C compiler. Lua also compiles cleanly as C++.
Lua is very easy to build and install. There are detailed instructions in the package but here is a simple terminal session that downloads the current release of Lua and builds it in Linux:
curl -R -O http://www.lua.org/ftp/lua-5.3.1.tar.gz tar zxf lua-5.3.1.tar.gz cd lua-5.3.1 make linux test
For Mac OS X, use make macosx test
.
正常情况下会出现: src/lua -v
(3)安装
二、使用IDE
1. 安装Sublime
2. 安装Lua编译器
Tools->Build System->New Build System
输入:
{ "cmd": ["/usr/local/bin/lua", "$file"], "file_regex": "^(...*?):([0-9]*):?([0-9]*)", "selector": "source.lua" }
保存为Lua.sublime-build,然后Tools-Build System上就能选择lua来编译脚本了。
3. 使用Sublime编写Lua代码
标签:
原文地址:http://www.cnblogs.com/yeahwell/p/4775018.html