log

log discovers or opens log files, reads a bounded head or tail and filters lines without loading a growing log into memory all at once.

DiagnosticsVersion 1.2.2Stable
lil-terminal

Overview

Use log for focused operational reading: find the relevant file, choose the first or last lines, then filter literal text when needed. The command never edits the log.

Reduce the log before reading it

Operational logs grow continuously and often contain far more data than one diagnosis needs. log keeps the task small: locate the file, take a bounded window and filter it. This is safer and faster on shared hosting than opening a large log in an editor.

Syntax

lil-terminal
log [file] [options]

Reference

log

show the last 10 lines of the newest detected log

log <file>

show the last 10 lines of the selected log file

-h

show the first lines instead of the last lines

-n <lines>

set the number of displayed lines from 1 to 50000

-g <text>

show only lines containing <text>

-i

search <text> without case sensitivity

-l

list detected log files

Detection

-l keeps modification date and size together on the left, with the log path in the flexible final column.

Reading and filtering

Tail mode is the default. -h switches to the beginning, -n controls the number of matching lines, -g applies a literal text filter, and -i makes that filter case-insensitive. Large files are streamed and output is bounded to keep the browser responsive.

Safety

log never writes to the selected file. Binary files are rejected and every path still passes through the normal lil-terminal filesystem resolver.

Interactive sandbox preview

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.

Find logs and read a short tail

Install and manage

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.

Base package

Install the complete package with local command reference and every published mode.

install log
Minimum package

Install the reduced package. Local reference is omitted; help <cmd> -i opens the current server reference.

install log -m
Exact public version

Install exactly this published version.

install log -v 1.2.2
Check or update

Ask upgrade to check compatibility and replace the installed block only when needed.

upgrade log
Remove module

Remove the extension block while leaving the core and unrelated modules intact.

install log -u

Examples

Examples are copyable command lines, not actions executed by this website. Review paths, permissions and destructive flags before running them on a real project.

Find logs and read a short tail
cd \sandbox | log -l | log logs/app.log -n 2
2026-08-08 20:53:40    219 B    ~/logs/errors.log
2026-08-07 12:00:00     96 B    ~/logs/app.log

2026-08-07 12:00:02 INFO request completed
2026-08-07 12:00:03 DEBUG cache hit
Show the last 10 lines of the selected log file
log sandbox/logs/app.log
File: sandbox/logs/app.log

2026-01-01T00:00:00Z INFO sandbox initialized
2026-01-01T00:00:01Z DEBUG sample event completed
Show the first lines instead of the last lines
log sandbox/logs/app.log -h
File: sandbox/logs/app.log

2026-01-01T00:00:00Z INFO sandbox initialized
2026-01-01T00:00:01Z DEBUG sample event completed
Set the number of displayed lines from 1 to 50000
log sandbox/logs/app.log -n 1
File: sandbox/logs/app.log

2026-01-01T00:00:01Z DEBUG sample event completed
Show only lines containing <text>
log sandbox/logs/app.log -g DEBUG
File: sandbox/logs/app.log
Filter: DEBUG

2026-01-01T00:00:01Z DEBUG sample event completed
Search <text> without case sensitivity
log sandbox/logs/app.log -g debug -i
File: sandbox/logs/app.log
Filter: debug

2026-01-01T00:00:01Z DEBUG sample event completed
List detected log files
log -l
sandbox/logs/errors.log              2026-08-08 16:20:57  219 B
sandbox/logs/app.log                 2026-08-04 23:53:00   96 B
Handle a missing log file
log sandbox/logs/missing.log
Log file not found

File used in this example: sandbox/logs/app.log

The example uses a file or directory from the protected /sandbox/ documentation workspace.

2026-01-01T00:00:00Z INFO sandbox initialized
2026-01-01T00:00:01Z DEBUG sample event completed

Related documentation

Current public release

v1.2.22026-08-10

Aligned log inventory

log -l now places date, size and path together from left to right, with options grouped compactly.