Lua: Difference between revisions

From Chorke Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 29: Line 29:
  ls -lah ~/.luarocks/
  ls -lah ~/.luarocks/
  luarocks list
  luarocks list
|-
| colspan="3" |
----
|-
| valign="top" |
<source lang="bash">
export LUA_PATH=/usr/bin/lua5.4
export LUA_INTERPRETER=/usr/bin/lua5.4
</source>
| valign="top" |
| valign="top" |


|}
|}

Revision as of 15:05, 3 February 2024

sudo apt install lua5.4
sudo apt install luarocks
lua --help
luarocks --help
lua -v
luarocks --version

sudo update-alternatives --config lua-interpreter
sudo update-alternatives --config lua-compiler
sudo mkdir -p /usr/local/lib/luarocks/rocks-5.1
ls -lah       /usr/local/lib/luarocks/
ls -lah ~/.luarocks/
luarocks list

export LUA_PATH=/usr/bin/lua5.4
export LUA_INTERPRETER=/usr/bin/lua5.4

Playground

mkdir -p ~/Documents/lua-playground
cd       ~/Documents/lua-playground
luarocks install moonrocks
luarocks install srlua
luarocks install lua-json
luarocks install luaunit

References