codjo3/run_in_roblox
Luau port of the run-in-roblox Rojo tool.
run-in-roblox (Luau)
A Luau port of rojo-rbx/run-in-roblox, built for Lune and distributed via pesde.
run-in-roblox opens a place file in Roblox Studio, runs a script inside it, and pipes all output back to your terminal — enabling traditional automation tools to work alongside Roblox.
Installation
With pesde
pesde add codjo3/run_in_roblox
Requirements
- pesde with Lune support
- Roblox Studio installed on your machine
Platform support
| OS | Supported | Notes |
|---|---|---|
| Windows | ✅ | Native Studio install |
| macOS | ✅ | Native Studio install |
| Linux | ⚠️ | Via Vinegar, Grapejuice, or Sober |
Usage
pesde x codjo3/run_in_roblox -- --place MyPlace.rbxlx --script my-script.luau
This opens MyPlace.rbxlx in Roblox Studio, runs my-script.luau until it completes, then exits.
--script and --place are both required.
Output
Output from inside Studio is forwarded to your terminal with color coding:
| Level | Colour |
|---|---|
print | White |
info | Cyan |
warn | Yellow |
error | Red |
Any error-level message sets the exit code to 1, making it straightforward to use run-in-roblox in CI pipelines.
How it works
- Your place file is copied to a temp directory to prevent Studio
.lockfile conflicts - A
.rbxmxplugin file is written to Studio's plugins folder containing:- A
Scriptthat connects toLogService, contacts the local server, and manages the run lifecycle - A
ModuleScriptchild (Main) containing your script wrapped in a function
- A
- A local HTTP server starts on port
50312 - Roblox Studio is launched with the temp place file
- The plugin verifies it's connected to the correct server via a unique session ID, then runs your script and streams output back as JSON over HTTP
- Once your script finishes, Studio is killed and all temp files (including the
.lockfile) are cleaned up
Differences from the original
This port is functionally equivalent to the original Rust tool with a few notes:
- Distributed via pesde instead of GitHub Releases, Foreman, or crates.io
- Linux support added for Vinegar, Grapejuice, and Sober compatibility layers
- No binary place support —
.rbxl/.rbxlxplace files are supported; binary.rbxlformat is not currently handled differently (Studio opens both fine) - The plugin template is embedded directly in the source rather than as a separate file
License
run-in-roblox (Luau) is available under the MIT License. See LICENSE.txt for details.
Original tool by Lucien Greathouse and the Rojo contributors.