Lua
Contents_Index
- IMPLEMENTATIONS, INTERPRETERS, AND BINDINGS12
- PACKAGE MANAGERS1
- BUILD TOOLS AND STANDALONE MAKERS4
- DEBUGGING AND PROFILING5
- IDES AND PLUGINS6
- UTILITY BELTS7
- GAME ENGINES6
- GAME DEVELOPMENT3
- LOGGING3
- WEB/NETWORKING PLATFORMS4
- OPENRESTY1
- COMMAND-LINE UTILITIES4
- CONCURRENCY AND MULTITHREADING2
- TEMPLATING3
- DOCUMENTATION3
- OBJECT-ORIENTED PROGRAMMING2
- FILE SYSTEM AND OS4
- TIME AND DATE3
- IMAGE MANIPULATION1
- DIGITAL SIGNAL PROCESSING2
- HARDWARE AND EMBEDDED SYSTEMS1
- MATH AND SCIENTIFIC COMPUTING3
- PARSING AND SERIALIZATION4
- HUMANIZE5
- COMPRESSION2
- CRYPTOGRAPHY4
- NETWORK4
- DATA STORES4
- MESSAGE BROKERS4
- TESTING4
- FOREIGN FUNCTION INTERFACES2
- ANALYSIS TOOLS AND ASTS8
- EXPERIMENTAL, ETC3
- SCRIPTABLE BY LUA7
- MISCELLANEOUS2
- COMMUNITY4
- REFERENCES3
- GLOSSARIES1
- STYLE GUIDES2
- TUTORIALS6
- ARTICLES3
- TALKS & SLIDES2
- BOOKS4
- OTHER LISTS3
Implementations, Interpreters, and Bindings
12_ENTRIESNote: From LuaJIT to Lua to lua.vm.js to Moonshine, a basic benchmark sees performance drop by roughly a factor of 6 with each hop.
- LuaJIT
High-performance Just-In-Time compiler for Lua.
- LLVM-Lua
Compiles Lua to LLVM.
- lua.vm.js
Lua VM on the web; a direct port of the C interpreter via LLVM, emscripten, and asm.js.
- Moonshine
A Lua VM implemented in JavaScript. Slower than lua.vm.js, but with better docs, examples, and JS interfacing.
- Fengari
The Lua VM rewritten in Javascript with seamless JS and DOM interoperability.
- MoonSharp
A Lua interpreter written entirely in C# for the .NET, Mono and Unity platforms.
- UniLua
A pure C# implementation of Lua 5.2, focused on compatibility with the Unity game engine.
- lupa
Python bindings to LuaJIT2.
- golua
Golang bindings to the Lua C API.
- GopherLua
Lua 5.1 VM and compiler implemented in Go with Go APIs.
- LuaBridge
A lightweight library for mapping data, functions, and classes back and forth between C++ and Lua.
Package Managers
1_ENTRIES- LuaRocks
De-facto tool for installing Lua modules as packages called "rocks", plus public rock repository and website. Much like npm or pip.
Build Tools and Standalone Makers
4_ENTRIESDebugging and Profiling
5_ENTRIES- ProFi
Simple profiler that works with LuaJIT and produces a report file.
- luatrace
Toolset for tracing/analyzing/profiling script execution and generating detailed reports.
- StackTracePlus
Drop-in upgrade to Lua's stack traces which adds local context and improves readability.
- MobDebug
Powerful remote debugger with breakpoints and stack inspection. Used by ZeroBraneStudio.
- lovebird
Browser-based debug console. Originally made for LÖVE, but works in any project with LuaSocket support.
IDEs and Plugins
6_ENTRIES- Lua Development Tools
Eclipse plugin which provides code completion, debugging, and more. Built on Metalua.
- Lua for IDEA
IntelliJ IDEA plugin which, among other things, provides code completion, smart highlighting, and experimental debugging.
- ZeroBraneStudio
Lightweight, customizable, cross-platform Lua-dedicated IDE with code completion and analysis, written in Lua. Has broad debugging support for numerous Lua engines.
- BabeLua
Lua editor/debugger extension for VS2012-13 with highlighting, auto-completion, linting, and formatting capabilities.
- lua-mode
Emacs major mode for editing Lua.
- vscode-lua
VSCode intellisense and linting.
Utility Belts
7_ENTRIES- Lua Fun
High-performance functional programming library designed for LuaJIT.
- Moses
Functional programming utility belt, inspired by Underscore.js.
- Penlight
Broad, heavyweight utility library, inspired by Python's standard libs. Provides the batteries that Lua doesn't.
- lua-stdlib
Middle-weight standard library extension; adds some useful data structures, utility functions, and basic functional stuff.
- Microlight
A little library of useful Lua functions; the 'extra light' version of Penlight.
- compat53
Compatibility module providing Lua-5.3-style APIs for Lua 5.2 and 5.1.
- RxLua
Reactive Extensions, Observables, etc.
Game Engines
6_ENTRIES- LÖVE 2D
Desktop game development platform. Cross-platform, feature-complete, well-adopted.
- Corona SDK
Development platform for iOS and Android. Proprietary, but used by numerous top games and apps, totaling over 150 million downloads.
- MOAI
Open source, cross-platform, mobile game development framework. Minimalist C++ engine powered by Lua scripting.
- Drystal
Open source, games can run on Linux or on any platform with a recent web browser.
- Amulet
Open source, audio/visual toolkit suitable for small games and experimentation. It runs on Windows, Mac, Linux, HTML5 and iOS.
- LÖVR
3D framework for creating virtual reality experiences, inspired by LÖVE 2D.
Game Development
3_ENTRIES-
CoronaCoronium - Simple cloud platform supporting analytics, data objects, user management, and more.
-
LÖVEawesome-love2d - A list like this one, but focused on game dev and the LÖVE platform.lurker - Shortens the iteration cycle by auto-swapping changed Lua files in a running LÖVE project.HUMP - A set of lightweight helpers for LÖVE; a game-oriented utility belt.
-
MOAImoaifiddle - Edit and share short scripts for the MOAI game engine and run them in the browser using WebGL.
-
Collision detectionbump.lua - Minimal rectangle-based collision detection which handles tunnelling and basic collision resolution.HardonCollider - Detect collisions between arbitrarily positioned and rotated shapes of any type.
-
Twe…
Logging
3_ENTRIES- lua-log
Asynchronous logging library with pluggable writers for file system, network, ZeroMQ, and more.
- LuaLogging
Log4j-inspired logging library supporting various appenders.
- luasyslog
Log to syslog, based on LuaLogging.
Web/Networking Platforms
4_ENTRIES- OpenResty
A fast and scalable web application platform created by extending Nginx with Lua. Today's de-facto Lua web platform, used heavily by Cloudflare, Taobao, Tencent, and others.
- turbo
Event-driven, non-blocking, LuaJIT-based networking suite and framework, inspired by Tornado.
- Kepler Project
A collection of web-oriented projects using a common set of standards and components.
- Pegasus.lua
Pegasus.lua is a http server to work with web applications written in Lua language.
OpenResty
1_ENTRIES-
Core platformngx_lua - The core piece of OpenResty. Embeds Lua in Nginx and exposes, among other things, the cosocket API for non-blocking sockets (compatible with LuaSocket's API).OpenResty GitHub Organization - Home of the repositories for ngx_lua, ngx_openresty, and many related modules.
-
Third-party moduleslua-resty-http - Lua HTTP client driver, built on the cosocket API.
-
Frameworks & toolsLapis - Full-stack framework for Lua and OpenResty. Like the Django or Rails of Lua. Supports Moonscript.ledge - Lua module providing scriptable, RFC-compliant HTTP cache functionality.Sailor — An MVC web framework compatible with OpenResty, Apache and other webservers.Kong - Microservice & API Management Layer.
Search …
- awesome-resty
A list like this one, but focused on OpenResty.
Command-line Utilities
4_ENTRIES- ansicolors
Simple function for printing to the console in color.
- cliargs
A simple command-line argument parsing module.
- lua-term
Terminal operations and manipulations.
- argparse
A feature-rich command line parser inspired by argparse for Python.
Concurrency and Multithreading
2_ENTRIESFor more on the differences (particularly between lanes and luaproc), see this comparison of options; somewhat dated, but covers how each one works and the significant differences.
- Coroutine-based multitasking
Coroutine-based multitasking:Lumen - Simple concurrent task scheduling.ConcurrentLua - Implements an Erlang-style message-passing concurrency model.cqueues - Library for managing sockets, signals, and threads based on an event loop with coroutines.
- Multithreading
Multithreading:llthreads - A simple wrapper for low-level pthreads & WIN32 threads.llthreads2 - Newer rewrite of llthreads.lanes - Library implementing a message passing model with one OS thread per Lua thread.luaproc - Message-passing model which allows multiple threads per OS thread and easily generalizes across a network. See al…
Templating
3_ENTRIES- lustache
Mustache template implementation.
- etlua
Embedded Lua templates, ERB-style.
- lua-resty-template
Lua-oriented template engine for OpenResty, somewhat Jinja-like.
Documentation
3_ENTRIES- docroc
Parse comments into a Lua table to generate documentation.
Object-oriented Programming
2_ENTRIES- 30log
Minimalist OOP library with basic classes, inheritance, and mixins in 30 lines.
- middleclass
Simple but robust OOP library with inheritance, methods, metamethods, class variables and mixins.
File system and OS
4_ENTRIES- LuaFileSystem
Extends and complements Lua's built-in set of file system functions.
- luaposix
Bindings for POSIX APIs, including curses.
- lunix
Bindings to common Unix system APIs, striving for thread-safety.
- lua-path
File system path manipulation library.
Time and Date
3_ENTRIESImage Manipulation
1_ENTRIES- magick
Lua bindings to ImageMagick for LuaJIT using FFI.
Digital Signal Processing
2_ENTRIESHardware and Embedded Systems
1_ENTRIES- eLua
Lua, extended with optimizations and specific features for efficient and portable embedded software development.
Math and Scientific Computing
3_ENTRIES- SciLua
Numerical/scientific computing framework built on LuaJIT, with an interface to R.
- Torch7
Scientific computing framework with wide support for machine learning algorithms, used by Facebook, Google, and more.
- lhf's Lua Tools
Assorted libraries and tools, many math- or data-related.
Parsing and Serialization
4_ENTRIES-
JSONlua-cjson - Blazing fast JSON encoding/decoding implemented in C and exposed to Lua.luajson - JSON encoder/decoder implemented in Lua on top of LPeg.dkjson - JSON encoder/decoder implemented in pure Lua.json.lua - A fast and tiny JSON library in pure Lua.
-
XMLLuaExpat - SAX XML parser via binding to the Expat library.SLAXML - Pure Lua SAX-like streaming XML parser.
-
MessagePacklua-MessagePack - Pure Lua implementation of MessagePack.lua-cmsgpack - A MessagePack C implementation with Lua bindings, as used by Redis.=
-
LPegLPeg - A pattern-matching library for Lua, based on Parsing Expression Grammars.[lpeg_patt…
Humanize
5_ENTRIES- i18n.lua
Internationalization library with locales, formatting, and pluralization.
- inspect.lua
Human-readable representation of Lua tables.
- serpent
Serializer and pretty printer.
- Ser
Dead simple serializer with good performance.
- say
Simple string key-value store for i18n.
Compression
2_ENTRIESCryptography
4_ENTRIES- LuaCrypto
Lua bindings to OpenSSL.
- lua-lockbox
A collection of cryptographic primitives written in pure Lua.
- luatweetnacl
Bindings to tweetnacl, modern high-security cryptographic library.
- luaossl
"Most comprehensive OpenSSL module in the Lua universe" - used by lapis, kong, and lua-http.
Network
4_ENTRIES- LuaSocket
Networking extension which provides a socket API for TCP and UDP, and implements HTTP, FTP, and SMTP.
- lua-websockets
WebSocket client and server modules. Webserver-agnostic, implemented in Lua on top of LuaSocket.
- lua-cURLv3
Lua binding to libcurl.
- lua-http
Asynchronous HTTP and WebSocket library with client and server APIs, TLS, and HTTP/2; based on cqueues.
Data Stores
4_ENTRIES- Redisredis-lua - Pure Lua client library for Redis.lua-resty-redis - Lua Redis client driver for OpenResty.lredis - Asynchronous Redis client with pipelining and Pub/Sub support; based on cqueues.
- LuaSQL
Simple interface for connecting to ODBC, ADO, Oracle, MySQL, SQLite and PostgreSQL.
- pgmoon
Lua PostgreSQL driver for OpenResty, LuaSocket, and cqueues.
- lua-resty-mysql
Lua MySQL driver for OpenResty.
- lua-resty-cassandra
Lua Cassandra client driver for OpenResty and others.
Message Brokers
4_ENTRIES- lua-zmq
Lua bindings to ZeroMQ.
- lzmq
A newer Lua binding to ZeroMQ.
- lua-resty-kafka
Kafka client driver based on OpenResty cosockets.
- lua-resty-rabbitmqstomp
RabbitMQ client library based on OpenResty cosockets.
Testing
4_ENTRIESForeign Function Interfaces
2_ENTRIES- LuaJIT FFI
LuaJIT's mechanism for calling external C functions and using C data structures from pure Lua code.
- luaffi
Standalone FFI library, compatible with the LuaJIT FFI interface.
Analysis Tools and ASTs
8_ENTRIES- luadec51
Lua Decompiler for Lua version 5.1.
- luacov
Simple coverage analyzer, used by busted and telescope for checking test coverage.luacov-coveralls - LuaCov reporter for coveralls.io.
- luacheck
Simple static analyzer which detects accidental globals and undefined or shadowed locals.
- Metalua
Pure Lua parser and compiler, used for generating ASTs. A number of other tools make use of the Metalua parser in this way.
- LuaInspect
Lua's most powerful code analysis and linting tool, built on Metalua. Used by ZeroBraneStudio, among others.
- LuaMinify
Minifier which also brings its own static analysis tools, lexer, and parser.
- Typed Lua
A typed superset of Lua that compiles to plain Lua.
- lua-parser
A Lua 5.3 parser written using LPegLabel, with improved error messages.
Experimental, etc
3_ENTRIES- punchdrunk.js
Moonshine + LÖVE API reimplementation = run LÖVE games in the browser.
- luvit
Node.js's underlying architecture (libUV) with Lua on top instead of JavaScript.
- graphql-lua
Lua implementation of GraphQL.
Scriptable by Lua
7_ENTRIES- luakit
Fast, small, webkit based browser framework extensible by Lua.
- Hammerspoon
A powerful, extensible OS X automation tool. A community-maintained fork of Mjolnir.
- kpie
A scripting utility to juggle windows.
- lumail
A console-based mail client, with extensive scripting capabilities.
- AwesomeWM
A highly configurable and extensible window manager for X, scripted and configured by Lua.
- Textadept
Extremely lightweight, customizable, cross-platform editor, written (mostly) in (and scripted by) Lua.
- KoReader
An ebook reader application supports PDF, DJVU, EPUB, FB2 and much more, running on Kindle, Kobo, PocketBook and Android devices.
Miscellaneous
2_ENTRIES- MoonScript
Moonscript is a dynamic scripting language that compiles to Lua. It reduces verbosity and provides a rich set of features like comprehensions and classes. Its author calls it 'CoffeeScript for Lua'.
- sitegen
A static site generator which uses MoonScript and supports HTML and Markdown, page grouping, and plugins.
Community
4_ENTRIES- Conferences/MeetupsLua Workshop - Annual 2-day meeting of the Lua community, in rotating locations.Lua Conf - Annual 1-day Lua conference in Brazil.FOSDEM - Annual 2-day gathering of F/OSS developers in Brussels which sometimes has a "Lua devroom".
- lua-l
The official Lua mailing list, and one of the focal points of the Lua community.
- Lua.Space
The Lua community blog.
- Lua Users Foundation
An association of individuals with the mission of supporting and promoting Lua and its community and ecosystems.
- lua-users.org
A site for and by users of Lua, featuring an IRC channel, a web archive of lua-l, and a large wiki.
References
3_ENTRIES- Reference Manual
The official definition of the Lua language.
- lua-users wiki
A large community-maintained collection of Lua information and resources, supplementing the official website.
- Lua Unofficial FAQ
Answers all sorts of Lua-related questions, including many of the form 'How to ___?'.
Glossaries
1_ENTRIES- Lua 5.3 Glossary
A glossary of some essential Lua terms.
Style Guides
2_ENTRIES- Lua-users style guide
A general, high-level style guide; unopinionated, easily agreed on.
- Olivine style guide
A more opinionated and specific, and therefore more rigorous, guide.
Tutorials
6_ENTRIES- Lua Crash Course
Short crash course readover, or reference for when you forget the basics.
- Learn Lua in 15 Minutes
A well-commented example file which covers the basics.
- Learning Lua from JS
An overview of the similarities and differences between Lua and JS; a great start for JavaScript folks looking to pick up Lua.
- lua-users tutorial
In-depth collection of tutorials aimed at newcomers.
- Lua Missions
A series of 'Missions' to work through which are designed to teach aspects of Lua along the way.
- Creating an Image Server
Walks through setting up and using OpenResty to build a simple image processing server; a great starting point for playing with OpenResty.
Articles
3_ENTRIES- Embedding Lua in C
An introductory walkthrough of embedding Lua in a C program. A bit dated, but still a great walkthrough.
- Lua: Good, bad, and ugly parts
A thorough summary of the good, different, bad, and ugly aspects of Lua, including many subtle quirks, by the author of ZeroBraneStudio.
- Lua states, libraries, coroutines and memory
Diagrams and explains some more advanced concepts of the Lua VM, particularly when interfacing with C.
Talks & Slides
2_ENTRIES- Roberto's Talks
History of talks given by Lua's chief architect, with slides for each.
- Lua Workshop Talks
High-quality talks are given at each ~annual Lua Workshop, and a history of them is online, slides included.
Books
4_ENTRIES- Programming in Lua
The authoritative intro to all aspects of Lua programming, written by Lua's chief architect. Three editions released; first edition available online.
- Lua Quick Reference
A quick reference on how to program in and embed Lua 5.1 through 5.3, by the creator of Textadept.
- Programming Gems
A collection of articles covering existing wisdom and practices on programming well in Lua, in a broad variety of use cases.
- Lua Programming
A shorter overview of the language, up to date for Lua 5.2, and available online.
Other Lists
3_ENTRIES- awesome-resty
A list like this one, but focused on OpenResty.
- awesome-love2d
A list like this one, but focused on game dev and the LÖVE platform.
- Where Lua is Used
A comprehensive list of stand-alone programs written in or extensible using Lua.