# 使用 Homebrew, apk, Nix, pacman, scoop 安装 luau

查看 luau 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:luau
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install luau
```

  证据: local Homebrew formula metadata

### Linux

- apk (92%):

```sh
sudo apk add luau
```

  证据: Alpine Linux edge package indexes: luau from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Nix (92%):

```sh
nix profile install nixpkgs#luau
```

  证据: nixpkgs package indexes: pkgs/by-name/lu/luau/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S luau
```

  证据: Arch Linux sync databases: luau from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

### Windows

- Scoop (92%):

```sh
scoop install main/luau
```

  证据: Scoop official bucket manifest trees: bucket/luau.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

## 软件包事实

- **软件包键:** brew:luau
- **软件包管理器:** Homebrew
- **版本:** 0.732
- **来源摘要:** Fast, safe, gradually typed embeddable scripting language derived from Lua
- **主页:** <https://luau.org>
- **仓库:** <https://github.com/luau-lang/luau>
- **最后更新:** 2026-07-31T21:29:20Z
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- luau (别名)
- luau-analyze (别名)
- luau-ast (别名)
- luau-compile (别名)
- luau-reduce (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 0.732
## 项目历史与用法

Luau is Roblox's Lua-derived scripting language: a small, fast, embeddable language with gradual typing, a bytecode compiler, interpreter, optional JIT, type checker, and linter.

### 项目历史

Luau grew out of Roblox's long use of Lua for user-generated gameplay and internal application code. The Luau team says Roblox chose Lua for simplicity, embedding, execution control, and coroutine support, then evolved it to improve performance, ergonomics, safety, and tooling while preserving Lua's design goals.

On November 3, 2021, Roblox announced that Luau was becoming a separate open-source language rather than an inseparable part of Roblox. The announcement made the runtime, compiler, type checker, and linter available under the MIT license and opened the language RFC process to the public.

### 采用历史

Luau's largest adoption base remains Roblox itself: the origins post describes it as powering millions of Roblox experiences and large amounts of Roblox app and Studio functionality. Open-sourcing made it usable outside Roblox, and the project says it has seen increased adoption in other projects and applications.

Package-manager adoption followed the open-source release. The input metadata lists Luau packages in Homebrew, Alpine, Nix, Arch, and Scoop, which makes the command-line compiler and analyzer available to non-Roblox workflows.

### 使用方式

Luau ships command-line tools for running scripts and analyzing code. The getting-started documentation shows luau for execution and luau-analyze for static analysis, type checking, and linting.

For embedders, the language is designed around a small standard library and host-provided APIs. That makes Luau useful both as a Roblox scripting language and as a sandboxable embedded scripting runtime.

### 为什么软件包爱好者会关心

Luau matters to package history because it is a modern, typed Lua-family runtime with a large production origin and standalone package-manager distribution. It is not just a Lua library: it ships a compiler, analyzer, AST tools, and runtime pieces as CLI binaries.

For Lua ecosystem watchers, Luau is one answer to the long-running question of how Lua-like languages can add typing, tooling, and safety without giving up embeddability.

### 时间线

- 2006: Roblox begins using Lua-style scripting for user-generated behaviors.
- 2021: Roblox announces Luau as a separate open-source language on November 3.
- 2022: The Luau team publishes its origins and evolution history.
- 2023: Open-source release binaries add native code generation support compiled in by default.

### Related projects

- Lua 5.1 is the language base Luau started from.
- Roblox Studio is the main application environment for Luau developers.
- LuaJIT is a related high-performance Lua-family runtime, but Luau focuses on gradual typing and Roblox-compatible embedding.

### 来源

- <https://luau.org/>
- <https://luau.org/getting-started/>
- <https://luau.org/library/>
- <https://luau.org/news/2021-11-03-luau-goes-open-source/>
- <https://luau.org/news/2022-11-04-luau-origins-and-evolution/>
- source_facts.package-manager


## 安全说明

generalized runtime or code generation signal.

- **Geiger 风险:** yellow / 中
- generalized runtime or code generation signal

## 其他软件包管理器记录

- Nix - luau: normalized package name match | nixpkgs package indexes: pkgs/by-name/lu/luau/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- apk - luau - 0.729-r0: normalized package name match | Alpine Linux edge package indexes: luau from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | A fast, small, safe, gradually typed embeddable scripting language derived from Lua | https://github.com/luau-lang/luau
- pacman - luau - 1:0.732-1: normalized package name match | Arch Linux sync databases: luau from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A fast, small, safe, gradually typed embeddable scripting language derived from Lua | https://github.com/luau-lang/luau
- Scoop - main/luau: normalized package name match | Scoop official bucket manifest trees: bucket/luau.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1


## Combined YAML source

View the package source record on GitHub. [combined/luau.yml](https://github.com/mxcl/pkgdb/blob/main/combined/luau.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
