Install the complete package with local command reference and every published mode.
install runrun.lil workflows with variables, conditions, captured results, nested scripts, previews and packed files through the same lil-terminal command path used interactively. It never invokes an operating-system shell.
Put recurring maintenance commands in a .lil file.
Each executable statement is resolved as a normal lil-terminal command. Dependencies must be installed beforehand, @command is rejected inside workflows, -n previews expanded commands without executing them, and -x is required for privileged non-interactive commands such as
run <file.lil|[script]> [-n|-v|-k|-x] · run -p <source.lil> [target.lil]run task.lilexecute a plain or packed .lil script
run [md backup | copy public backup/public]execute an inline script; an unquoted | separates statements
run <script> -nvalidate and show expanded commands without executing them
run <script> -vshow complete command output
run <script> -kcontinue after failures; the default stops on the first failure
run <script> -xallow privileged non-interactive commands such as php and ses
run -p <source.lil> [target.lil]create a checksum-protected packed script
lil <script>alias for
plain .lilUTF-8 text with one statement per line
packed .lil@LIL1 header with SHA-256 and DEFLATE data
setup.lilautoload.lil@<command>automatic installation is interactive-only and is rejected in scripts
#lil filecore-linear script: ordinary terminal commands only;
run workflowuse
If you repeat a maintenance task, save the terminal commands in a .lil text file and execute them with
Start with | separates script statements.
Put one statement per line. set saves a variable, capture stores command output, if and else choose a branch, and if file ${source} checks the file before proceeding.
-v shows every command output. Execution normally stops on the first error; -k continues subsequent steps, but the workflow still reports Stopped when a failure occurred. A preview cannot guarantee later success.
A file beginning with #lil runs as a simple linear sequence directly through Base Core. Full
setup.lil next to lil.php runs after authorization and is removed only after success; autoload.lil runs once per authorized session. -p packs into @LIL1 using SHA-256 and DEFLATE, but **does not encrypt** the script.
Scripts
The supported conditions are ok, fail, exists, file, dir, empty, eq, ne and command. Prefix a condition with not to invert it.
A packed file starts with @LIL1, the original byte length and a SHA-256 checksum. The remaining payload is URL-safe base64 over raw DEFLATE data. Packing is not encryption and is not a security boundary.
setup.lil is checked beside lil.php after authorization and is removed only after every statement succeeds. autoload.lil is checked beside lil.php once per session and is not removed.
The @command convenience belongs to the interactive core, not to the automation language. A .lil script that starts a command with @ is rejected. Install script dependencies explicitly before automation so a workflow never changes its executable module set implicitly.
Startup files must be regular readable .lil files beside lil.php; symlinks are rejected. Plain content is limited to 256 KiB, packed input to 384 KiB, scripts to 1000 statements, nesting to 10 levels and execution to 60 seconds. Interactive commands are blocked. php and ses require -x.
A file beginning with #lil is intentionally simpler than a | separators are executed from left to right, and processing stops after the first failure. < file.lil. Use
A workflow, including all nested scripts, is limited to 1000 non-comment statements. Preview mode (-n) reports Stopped instead of Checked when validation fails; preview never executes commands.
Run the prepared examples directly on the page. Their results are prebuilt and shown in the browser; no terminal command is executed on the server.
Install the current compatible version. Choose Base for the complete feature set or Minimum for the reduced package; use upgrade to update a module that is already installed.
Base and Minimum are two packages of the same current module release, not separate command versions.
Install the complete package with local command reference and every published mode.
install runInstall the reduced package. Local reference is omitted;
install run -mInstall exactly this published version.
install run -v 1.2.4Ask upgrade to check compatibility and replace the installed block only when needed.
upgrade runRemove the extension block while leaving the core and unrelated modules intact.
install run -uExamples are copyable command lines, not actions executed by this website. Review paths, permissions and destructive flags before running them on a real project.
run sandbox/scripts/workflow.lil001 + pwd
002 + pwd
Completed: 2run sandbox/scripts/workflow.lil -v001 + pwd
sandbox
002 + pwd
sandbox
Completed: 2run sandbox/scripts/workflow.lil -n001 · pwd
002 · pwd
Checked: 2run sandbox/scripts/workflow.lil -n -v001 · pwd
002 · pwd
Checked: 2lil sandbox/scripts/workflow.lil001 + pwd
002 + pwd
Completed: 2.lil workflows and pasted automation use the same command execution path.
run [pwd | pwd]001 + pwd
002 + pwd
Completed: 2run [set name demo | if eq demo demo | pwd | else | stop mismatch | end]001 + pwd
Completed: 1run [if file sandbox/data/sample.txt | pwd | end]001 + pwd
Completed: 1run [if not exists sandbox/missing.txt | pwd | end]001 + pwd
Completed: 1run [capture location pwd | pwd] -v001 + pwd
sandbox
002 + pwd
sandbox
Completed: 2run sandbox/scripts/nested.lil -v001 + pwd
sandbox
002 + pwd
sandbox
Completed: 2run [upload | pwd]001 – upload
Command is not allowed in scripts
Stopped: 1run [upload | pwd] -k001 – upload
Command is not allowed in scripts
002 + pwd
Stopped: 2run [stop maintenance]Line 001 – maintenance
Stopped: 0run [pwd | php -v]001 + pwd
002 – php -v
Command is not allowed in scripts
Stopped: 2run [pwd | php -v] -x -v001 + pwd
sandbox
002 + php -v
PHP 8.4.24
Completed: 2run sandbox/scripts/privileged.lil001 – php -v
Command is not allowed in scripts
Stopped: 1run sandbox/scripts/privileged.lil -x -v001 + php -v
PHP 8.4.24
Completed: 1run sandbox/scripts/invalid.lil -n001 · pwd
Line 003 – Missing end
Stopped: 1run sandbox/scripts/recursive.lilRecursive script detected
Stopped: 0run sandbox/scripts/blocked.lil001 – @install find
Automatic installation is not allowed in scripts
Stopped: 1run sandbox/scripts/recover.lil -k001 – upload
Command is not allowed in scripts
002 + pwd
Stopped: 2run -p sandbox/scripts/workflow.lil sandbox/scripts/workflow.export.lilPacked workflow.lil > sandbox/scripts/workflow.export.lil
182 B > 256 Brun sandbox/scripts/workflow.packed.lil001 + pwd
002 + pwd
Completed: 2run sandbox/scripts/workflow.packed.lil -n001 · pwd
002 · pwd
Checked: 2run [@install find]001 – @install find
Automatic installation is not allowed in scripts
Stopped: 1run [upload]001 – upload
Command is not allowed in scripts
Stopped: 1run sandbox/scripts/missing.lilScript file not foundrun sandbox/data/sample.txtScript must use the .lil extensionrun sandbox/scripts/workflow.lil -zUnknown run option: -zrun [pwdInline script is missing ]run?sandbox/scripts/demo.lilThe example uses a file or directory from the protected /sandbox/ documentation workspace.
# lil-sandbox workflow
pwd
dir 1 sandbox
echo sandbox/data/sample.txt
Current stable release of