rpmlua(1)

rpmlua1

Rpm lua interpreter

Usage

rpmlua [options] [LUA_SCRIPT] [-- ARG ...]

Overview

Run RPM internal Lua interpreter.

Note: indexes start at 1 in Lua, so the program name is at arg[1] instead of the more customary index zero.

Arguments

LUA SCRIPT

A Lua script.

ARG

Options and arguments to be passed to SCRIPT_FILE. rpmlua stops processing at --.

Options

-i, --interactive

Run an interactive session after executing optional script or statement.

--opts=OPTSTRING

Perform getopt(3) option processing on the passed arguments according to OPTSTRING.

-e "STATEMENT", --execute "STATEMENT"

Execute a Lua statement before executing optional script.

Exit status

On success, 0 is returned, a nonzero failure code otherwise.

Examples

rpmlua test.lua

Execute test.lua script file.

rpmlua --opts=ab:c args.lua -- 1 2 3 -c -b5

Execute args.lua script file with option processing.

rpmlua -e "print(rpm.ver('1.0') < rpm.ver('2.0'))"

Execute single statement to compare rpm versions.

rpmlua -i

Run an interactive session.

From rpm-tools 6.0.1-2 in Arch Linux 2026-11-01. Parsed by carta from the page's man source.