MegaBedder / my-awesome-lua

My list of quality Lua packages and resources.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

My Awesome Lua List Awesome

A curated list of quality Lua packages and resources.

Inspired by the list LewisJEllis/awesome-lua and forhappy/awesome-lua.

Main

Packages

Projects

Resources


Implementations, Interpreters, and Bindings

  • Lua - Lua's original ANSI C interpreter.
    • Lua Repo - The official Lua repo, as seen by the Lua team, mirrored to GitHub.

Dialects, flavors and implementations

  • Terra - a low-level system programming language that is embedded in and meta-programmed by the Lua programming language.
  • SquiLu - A mix between Squirrel 3.0.4 and Lua 5.1.5, trying to get the best of both. Squirrel scripting language modified with lua libraries
  • Céu - a reactive language that aims to offer a higher-level and safer alternative to C. “Structured Synchronous Reactive Programming”
  • Lua Implementations - Reimplementations of Lua compilers and interpreters.

Lua 5.1

  • LuaJIT - High-performance Just-In-Time compiler for Lua.
    • LuaJIT 2 - OpenResty's Branch of LuaJIT 2 (fork)
    • RaptorJIT - A dynamic language for system programming (LuaJIT fork for Linux/x86-64 server applications)
    • Moonjit - JIT Compiler for the Lua. Fork of LuaJIT to continue development
    • LuaVela [BLOG] - an implementation of Lua 5.1 based on LuaJIT 2.0, for Linux x86-64 only.
    • LjTools - LuaJIT Assembler/Disassembler - Tool to study LuaJIT 2.0 Bytecode with GUI
  • Shine - a general purpose, dynamic, multi-paradigm programming language which is based on a modified version of the LuaJIT VM with features geared more to programming in the large.
  • Metalua - a compiler for a superset of the Lua 5.1 language, which supports compile-time metaprogramming.
  • Typed Lua (PhD Thesis) - An Optional Type System for Lua
  • Idle - At the core of Idle sits a tweaked and significantly enhanced version of Lua 5.1. Includes a GUI module, built from scratch; usable ("good enough") to create simple GUIs and dialog boxes.
  • Agena - based on Lua 5.1 C source, but has significant syntax differences
  • GSL Shell - an interactive command line interface that gives easy access to a collection of numeric algorithms and functions based on the GNU Scientific Library (GSL).
  • Firth [BLOG] - A simple Forth-like language intended for DSL creation, implemented in Lua.

Lua 5.2

  • Killa: a scripting language based in Lua 5.2 with a JavaScript-like syntax

Lua 5.3

  • Titan [Slides] - a system programming language, designed to be a statically-typed, ahead-of-time (AOT) compiled sister language to Lua, focused on performance. It is designed to seemlessly interoperate with Lua.
    • Pallene [Paper] [Slides] - a statically typed, ahead-of-time (AOT) compiled sister language to Lua, with a focus on performance. Pallene is also designed to seamlessly interoperate with Lua.
  • Ravi [Slides] [Video] - a derivative of Lua 5.3 with limited optional static typing and features LLVM and Eclipse OMR powered JIT compilers.
  • golua - A Lua 5.3 engine implemented in Go by Azure
  • DCLua - A Lua 5.3 VM and compiler written in Go.
  • Jual - an embeddable Virtual Machine (VM) that implements the JualScript language (a subset of ECMA Script or JavaScript). The implementation is derived from Lua 5.3.

Compiles to Lua

  • MoonScript - A programmer friendly language that compiles to Lua 5.1.
  • Fennel - a programming language that brings together the speed, simplicity, and reach of Lua with the flexibility of a lisp syntax and macro system.
  • Urn - a Lisp dialect with a focus on minimalism which compiles to Lua.

Lua VM in Lua

  • LuLu - a Lua 5.1 VM implementation in Lua language itself. Implements a VM interpreter and coroutine library, but reuses the host Lua environment for data types and standard library functions.
  • Yueliang - Lua 5 in Lua 5 (5.0 and 5.1). The focus is on the front end of Lua, i.e. the lexical analyzer, the parser and the code generator, in order to generate binary chunks.
  • LuaVM - Lua Virtual Machine (and various tools) for Lua
  • LuaJIT Language Toolkit - an implementation of the Lua programming language written in Lua itself, as a starting point to implement a programming language that targets the LuaJIT virtual machine.

Compiles to JS, asm.js or WebAssembly for Browser

  • Brozula - a LuaJIT bytecode interpreter that generates ES5 JavaScript.
  • Fengari - Lua VM for the browser. A viable approach to using Lua in the browser and interacting with the DOM.
  • glua - a Lua VM written in Go, to Javascript.
  • ljs [fork] - Lua VM implemented in Javascript
  • Lua.js - a project that can convert lua code to javascript. lua.js is fully written by javascript
  • lua.vm.js - Compile Lua via emscripten to asm.js. Originally by kripken (author of emscripten).
  • lua5.1.js - Lua 5.1, built with emscripten, with low-level API
  • LuaJS - Lua VM running in Javascript (using emscripten)
  • Luwa - Lua WASM JIT, a Lua runtime on top of WASM
  • Moonshine - A lightweight Lua VM for the browser
  • wasm_lua - Lua VM running in a WASM environment

Transpiler Lua to JS and vice versa

  • js2lua - Javascript to Lua translator, using LuaJIT
  • lua.js - Translate Lua code into Javascript.
  • Starlight - A Lua to ECMAScript 6 transpiler.

Distribution

  • Lua Binaries - a distribution of the Lua libraries and executables compiled for several platforms.
  • LuaWiMix - A Lua distribution similar to LuaForWindows without anything but ilua, but with support for Lua 5.1 5.2 and 5.3 including optional luarocks and a switching mechanism.

Package Managers

  • LuaRocks - De-facto tool for installing Lua modules as packages called "rocks", public rock repository and website.
  • LuaDist - a multi-platform package management system that aims to provide both source and binary repository of modules for Lua.
  • LuaPlus - Full LuaPlus distribution (fork of Lua 5.1) for Windows
  • ULua - Universal Lua Distribution
  • LuaPower - the LuaJIT distribution for Windows, Linux and OS X
  • Lit [web] - Toolkit for the Luvit ecosystem

Batteries Included

  • Lua for Windows - a 'batteries included environment' for the Lua scripting language on Windows.
  • UFO - Un Finished Object - a portable distribution of LuaJIT with precompiled binaries, libraries and FFI bindings
  • NekoLua - A distribution of Lua customized
  • Omnia - Compile Lua, Fennel and MoonScript source code into standalone executables. Using luastatic.

Build Tools and Standalone Makers

  • srlua - A tool for building self-running Lua programs.
  • luastatic - Build a standalone executable from a Lua program.
  • omnia - A batteries-included creator of standalone executables, built on top of luastatic.
  • Lake - A build engine written in Lua, similar to Ruby's rake.
  • Luabuild - A Custom Lua 5.2 Builder (tool to build a static Lua with bundled libraries)
  • slua - A static build of Lua 5.3 for Linux, with a few extension libraries.
  • Luapak - a command-line tool, multi-platform, adjustable, all-in-one (yet modular) solution for building a standalone, zero-dependencies, possibly statically linked (only on Linux) executable for (almost) any Lua program.

IDE, Plugins and text editor

  • ZeroBrane Studio - a lightweight Lua IDE with code completion, syntax highlighting, live coding, code analyzer, and debugging support for Lua 5.x, LuaJIT, and other Lua engines.
  • Lua Development Tools (LDT) - project provides plug-ins that implement a Lua IDE supporting the development of Lua scripts and applications. It adds a dedicated Lua perspective to the Eclipse Workbench, which, together with features such as syntax highlighting, scope-aware code completion, code folding, etc.
  • Lua for IDEA - IntelliJ IDEA plugin which, among other things, provides code completion, smart highlighting, and experimental debugging.
  • vscode-lua - VSCode intellisense and linting.
  • Textadept - A fast, minimalist, and remarkably extensible cross-platform text editor
  • Howl Editor - A general purpose, fast and lightweight editor with a keyboard-centric minimalistic user interface. Built on LuaJIT and fully programmable using Lua or Moonscript.
  • SciTE - a SCIntilla based Text Editor, with embedded Lua interpreter.

Data structures

Tables in Lua are not a data structure; they are the data structure.

  • Tuple - Tuple of Values for Lua.
  • array.lua - A small library with useful methods to handle Lua's table when it's working like an Array
  • binarystream - Lua library to work with binary data (needs ffi support)
  • lua-users: Data Structures - Here are implementations of various data structures in Lua or related discussions.

Programming Paradigms

  • Object-oriented programming (OOP)
    • 30log - a small class system for OOP in Lua
    • middleclass - A simple OOP library for Lua. It has inheritance, metamethods (operators), class variables and weak mixin support.
    • LOOP - Class Models for Lua
    • PLoop - a C# like style object-oriented program system for lua.
    • Aspect-oriented programming (AOP)
  • Event-driven programming
  • Functional programming
    • Lua Fun - a high-performance functional programming library for Lua
    • Moses - Utility library for functional programming in Lua
    • lamda - A functional programming library for Lua, inspired by Ramda.
  • Reactive programming
    • FRLua - Functional Reactive programming capabilities in Lua.
    • RxLua - Reactive Extensions for Lua
  • Defensive programming
    • Safer - Paranoid Lua programming

I/O

  • lunary - A binary format I/O framework for Lua.
  • lua-nixio [fork] - a multi-platform library for IPv4, IPv6 and UNIX networking, POSIX user/group management, TLS support. System, Networking and I/O library for Lua.
  • LuaSys - a portable Lua library providing access to system and networking functions.
  • lcurses - curses Terminal Screen Control
  • Readline - Interface to the readline library
  • linenoise - A small self-contained alternative to readline and libedit.
  • ljlinenoise - a pure LuaJIT port of linenoise, a small alternative to readline and libedit.
  • LTUI - A cross-platform terminal ui library based on Lua

GUI

  • Yue - A library for creating native cross-platform GUI apps.
  • wxLua - a wrapper around the wxWidgets cross-platform C++ GUI library.

Debugging

  • MobDebug - Remote debugger for Lua.
  • clidebugger - A simple command line interface debugger for Lua 5.1 written in pure Lua.
  • inspect.lua - Human-readable representation of Lua tables
  • chrome-devtools-client - Chrome DevTools client for Lua
  • lovebird - a Browser-based debug console. Originally made for LÖVE, but works in any project with LuaSocket support.
  • Profiling & Tracing
    • 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.

Testing

  • busted - BDD-style unit testing framework with great docs and Moonscript support.
  • LuaUnit - a popular unit-testing framework for Lua, with an interface typical of xUnit libraries.
  • luassert - Assertion library extending Lua's built-in assertions.
  • Luacheck - A tool for linting and static analysis of Lua code.
  • LuaInspect - a tool that does Lua code analysis, with plugins for HTML and SciTE.
  • lualint - lua linter and static analysis of global variable

Cryptographic

  • lua-argon2 - the Argon2 password hashing function. Compatible with Lua 5.x and LuaJIT.
  • PLC (Pure Lua Crypto) - A small collection of crpytographic functions, and related utilities, implemented in pure Lua (version 5.3 or above)
  • Luazen - a small library with various encoding, compression and cryptographic functions. All the functions work on strings, there is no stream or chunked more complex interfaces.
  • luatweetnacl - Lua binding to the NaCl ("Tweet" version) crypto library

File System

  • luafilesystem - LuaFileSystem complements the set of file system functions offered by the standard Lua distribution.

Network

  • lua-http [Video] - HTTP Library for Lua. Supports HTTP(S) 1.0, 1.1 and 2.0; client and server.
  • lua-httpclient - a unified wrapper around a openresty/ngx.location.capture or luasocket and luasec as drivers.
  • lua-websockets - This project provides Lua modules for Websocket Version 13 conformant clients and servers.
  • Lua-cURLv3 - Lua binding to libcurl
  • Ratchet - The purpose of the ratchet library is to provide in Lua an asynchronous socket control mechanism for large numbers of sockets without using OS-level threads or losing the ease of synchronous socket programming.
  • Turbo - a asynchronous networking suite and framework built for LuaJIT 2 to building fast and scalable network applications. It uses a event-driven, non-blocking, threadless design.
  • lua-handlers - Provides a set of async. callback based handlers for working with raw TCP/UDP socket, ZeroMQ sockets, or HTTP client/server. You can get node.js style non-blocking IO with lua-handlers.
  • LuaSocket [Doc] - Network support for the Lua language
  • lsocket - simple and easy socket support for lua.
  • llsocket - low-level socket module [this module is under heavy development]
  • lua-resty-socket - A module offering interoperability between the LuaSocket and cosocket APIs
  • lua-net - Lua networking library that wraps around lua-socket to make networking easy.
  • dromozoa-socks - Toolkit for network and I/O programming

Message broker / queues

  • lua-zmq - a library which extends the standard socket interfaces with an abstraction of asynchronous message queues. Lua bindings to ZeroMQ version 2.1, 2.2 or 3.2.
  • lzmq - Lua binding to ZeroMQ version 3.2 or 4.x library. This library has C and FFI version of binding.

Database drivers

  • File systems (CVS, JSON formatted data, Flat-file database)

    For a small database. The file is simple. A flat file can be a plain text file, or a binary file. Records follow a uniform format, and there are no structures for indexing or recognizing relationships between records. Relationships can be inferred from the data in the database.

  • Relational databases

    for features that provide consistency and reliability.

    • LuaSQL - a simple interface from Lua to various DBMS. Connect to ODBC, ADO, Oracle, MySQL, SQLite, Firebird and PostgreSQL databases.
    • LuaDBI - Multi-backend SQL database interface library for Lua. It is designed to provide a RDBMS agnostic API. Supports DB2, Oracle, MySQL, PostgreSQL and SQLite databases with native database drivers.
    • LuaSQLite3 - a Lua wrapper for the SQLite3 library.
    • PL/Lua - an implementation of Lua as a loadable procedural language for PostgreSQL.
    • pgmoon - a PostgreSQL client library written in Lua for OpenResty
  • NoSQL databases

    for high performance, high scalability and ease of access

    • Tarantool - is an in-memory database and application server.
    • Redis - A Lua client library for the Redis key value storage system.
    • lredis - a Redis (in-memory data structure store) client library for Lua

Multitasking

Native OS threads:

Threads use preemptive multitasking.

  • lua-llthreads - Low-Level threads (pthreads and WIN32 threads) for Lua.
  • lua-llthreads2 - drop-in replacement for lua-llthreads library with several additional functionality.
  • luaproc [paper] - multi-threading library. Message-passing model which allows multiple threads per OS thread.
  • Lua Lanes - a lightweight, native, lazy evaluating multithreading library for Lua 5.1 to 5.4. Library implementing a message passing model with one OS thread per Lua thread.
  • ltask - lua multi task library, use n os thread for m lua states.
  • Effil [slideshow] - Multithreading support for Lua. It allows to spawn native threads and safe data exchange.

Coroutine-based multitasking:

Lua uses coroutines, non-preempted form of concurrency known as cooperative multitasking. This means that coroutines provide concurrency but not parallelism.

  • Copas - Dispatcher based on coroutines that can be used for asynchronous networking. (It uses LuaSocket for TCP/IP stack and LuaSec for SSL support)
  • Lumen - Simple concurrent task scheduling.
  • Continuation Queues: cqueues - Embeddable asynchronous networking, threading, and notification framework for Lua on Unix. Library for managing sockets, signals, and threads based on an event loop with coroutines.
  • Coil - A tiny cooperative threading module for Lua.

See this comparison of options for more on the differences (particularly between lanes and luaproc).

See this lua-users: MultiTasking for links related to multitasking / multithreading / parallelization in Lua.

Native OS APIs

  • POSIX

    • luaposix - Lua bindings for POSIX APIs.
  • Windows-specific

    • winapi - Minimal Windows API
    • lua-win32lib - Small lib exposing some Win32 API to lua
    • w32wrappers - Wrappers for Win32 API functions & constants.
    • win32_api_luajit - Cosmin's win32 api for luajit (with adjustments)
    • luapower/winapi - Windows, common controls and dialogs, message loop and system APIs for LuaJIT.
  • UNIX

    • ljsyscall - Unix system calls for LuaJIT
    • minisock - a minimal Lua socket library for unix / tcp / udp connections. The API is very close to the standard Unix system calls.
    • lunix - Bindings to common Unix system APIs, striving for thread-safety.
    • luaunix - A Lua Binding for Selected Unix functions and System Calls
    • dromozoa-unix - Lua bindings for UNIX system interface

Libraries

  • LuaWebDriver [Blog] - a browser automation library using WebDriver API.
  • LuaCS [Blog] - a CSS Selectors parser library for Lua
  • XMLua [Blog] - An user-friendly XML/HTML processing library for Lua based on libxml2
  • luaexpat [Doc] - a SAX XML parser based on the Expat (a stream-oriented XML parser) library.
  • luapower/expat - A ffi binding for the Expat XML parser.
  • lua-cjson - Lua CJSON is a fast JSON encoding/parsing module for Lua
  • neturl - A Robust URL Parser (with the ability to parse querystrings) and Builder for Lua.
  • lucihttp - HTTP utility library with Lua binding9
  • LPeg - a new pattern-matching library for Lua, based on Parsing Expression Grammars (PEGs). [1] [2]
    • LPegLabel - a conservative extension of the LPeg library that provides an implementation of Parsing Expression Grammars (PEGs) with labeled failures.
    • lpeg_patterns - A collection of LPEG patterns
  • lualinq - Lightweight library which allows functional querying and transformation of lua arrays and objects
  • luatz - Time, Date and Timezone library for lua
  • Libraries And Bindings - a list of libraries implemented in Lua or implemented in another language (e.g. C) but having a Lua interface.

Utilities

  • Allen - An utility library to manipulate strings, which provides a set of helpers for strings operations for Lua.
  • Strictness - a small module to track access and assignment to undefined variables in Lua
  • Serpent - Lua serializer and pretty printer.
  • lua-marshal - fast table serialization for Lua
  • base2base - A pure Lua base-to-base converter
  • LuaTools - tools for use with Lua. Some of these tools written in Lua.

Miscellaneous

  • Luno - General purpose libraries for Lua.
  • lua-stdlib - General Lua libraries
  • Penlight - A set of pure Lua libraries focusing on input data handling, functional programming, and OS path management. Inspired by the Python standard libraries.
  • Microlight - A little library of useful Lua functions, intended as the 'light' version of Penlight
  • Carbon - a full suite intended to make Lua more semantic, expressive, and powerful. It aims to provide a set of functionality comparable to .NET, and runs on Lua 5.1 and LuaJIT on any platform.
  • lua-ext - Standard library / extensions for Lua. math, operator functions, execution platform, Set implementation for Lua, I/O on strings; instead of files.
  • lua-apr - Apache Portable Runtime binding for Lua. APR powers software and makes the APR operating system interfaces available to Lua, serving as an extended standard library, focus in Threads, Processes, Directories.
  • lua-glib [Doc] - Yet another Lua-to-glib binding. This package wraps the GLib library fairly thinly. It is meant to be a portability and utility library.
  • LGI - Dynamic Lua binding to GObject-based libraries using GObject-Instrospection. Allows using GObject-based libraries directly from Lua.
  • lgob - lgob provides bindings of GObject-based libraries (like GTK+ and WebKitGTK+), for Lua 5.1 / 5.2 / LuaJIT. It consists of a compiler that parses GObject-Instrospection gir files and generates Lua modules.

Projects

Asynchronous I/O

  • Luvit - Lua + libUV + jIT = pure awesomesauce
    • Luver - a luvit without lit.
  • LuaNode - Asynchronous I/O for Lua, using the Reactor pattern like Node.js, EventMachine or Twisted.
  • node-lua - a runtime environment and server engine for lua-based scripting that runs on multi-core machines in a multi-threaded manner.
  • Node.lua - a Lua runtime environment that uses an event-driven, non-blocking I/O model like Node.js
  • Lua Corovel - Asynchronous, event-loop development environment for Lua

Web Browser

  • Luakit - A fast, extensible, and customizable web browser based on the WebKit web content engine and the GTK+ toolkit.

Web Plataforms

  • OpenResty - Turning Nginx into a Full-Fledged Scriptable Web Platform
    • VeryNginx - a very powerful and friendly nginx which provide WAF, Control Panel, and Dashboards.
    • Orange - A Gateway based on OpenResty (Nginx+lua) for API Monitoring and Management.
    • OpenStar - Lua WAF, Nginx+Lua, OpenResty, LuaJIT, WAF+, CDN
    • nginx-lua-prometheus - Prometheus metric library for Nginx written in Lua
  • algernon - Small self-contained web server with Lua, Markdown, QUIC, Redis and PostgreSQL support

Web Frameworks

  • Lapis - A web framework for Lua or MoonScript, powered by OpenResty
  • Sailor - A Lua MVC web framework.
  • Ophal - The highly scalable Lua CMS/CMF and web platform
  • Orbit - an MVC web framework for Lua, based on WSAPI. [1]
  • Lor Framework - a fast, minimalist Web & API framework for lua based on OpenResty
  • Vanilla - An OpenResty Lua MVC Web Framework

Game Framework

  • Skynet - a lightweight online game framework which can be used in many other fields.
  • NoobHub - Network multiplayer and messaging for CoronaSDK, Moai, Gideros, LÖVE & Defold

Scientific Computing

  • Torch - a scientific computing framework with wide support for machine learning algorithms that puts GPUs first.
  • SciLua - A complete framework for numerical computing based on LuaJIT

Digital Signal processing

  • LuaRadio - a lightweight, embeddable flow graph signal processing framework for software-defined radio. It provides a suite of source, sink, and processing blocks, with a simple API for defining flow graphs, running flow graphs, creating blocks, and creating data types.

Miscellaneous

  • Kong - a cloud-native, fast, scalable, and distributed Microservice Abstraction Layer (also known as an API Gateway, API Middleware or in some cases Service Mesh).
  • Snabb Switch - a simple and fast packet networking toolkit.
  • Telize - a High performance REST API built on Nginx and Lua allowing to get a visitor IP address and to query location information (IP Geolocation).
  • SILE - a typesetting system; its job is to produce beautiful printed documents. Conceptually, SILE is similar to TeX.
  • MoonGen - a fully scriptable high-speed packet generator built on DPDK and LuaJIT.
  • Prosody IM Server - a server for Jabber/XMPP written in Lua.

Blogs / Sites

Style Guides

Guides / Tutorials

Lua Workshop

Articles

Publications and Researchs

Books

  • Programming in Lua (PiL) - Intro to all aspects of Lua programming, written by Lua's chief architect. The official book first edition was aimed at Lua 5.0, remains largely relevant and available online.
  • Programming Gems - A collection of articles covering existing wisdom and practices on programming well in Lua, in a broad variety of use cases.
  • Lua Quick Reference - This book covers: Object-oriented programming with Lua. Creating and working with Lua and C Modules. Lua's standard library and its C API. Collaborative multi-threading in Lua and C. How to program in and embed Lua 5.1 through 5.3, by the creator of Textadept.
  • Wrox - Beginning Lua Programming - This book is for beginning programmers, game developers, and web site developers who are interested in a introduction to programming.
  • Creating Solid APIs with Lua - Learn how you can build APIs by integrating the Lua and C programming languages.
  • Lua Programming - A shorter overview of the language, up to date for Lua 5.2, and available online.

Lua VM and Bytecode

Glossaries

Frequently Asked Questions (FAQ)

  • Lua FAQ - official Lua FAQ
  • Lua-Users FAQ - unofficial Lua FAQ, it is maintained by the Lua community.
  • uFAQ - Lua Unofficial FAQ

Complementary lists

Contribute

Contributions welcome and wanted! Read the contribution guidelines first.

About

My list of quality Lua packages and resources.

License:The Unlicense