TOMLLINT(1)
π TOMLLINT(1) π
okay so bestie, welcome to tomllint β the little utility that checks your TOML files for syntax errors and is genuinely so chill about it. let's get into it β¨
π SYNOPSIS π
tomllint [-h] [-v|--verbose] toml_file [toml_file...]
yes that's the whole vibe. one flag family, then as many files as your heart desires. π«Ά
πΈ DESCRIPTION πΈ
tomllint checks one or more files for TOML syntax errors, and it does it using Python's built-in TOML parser. no extra deps, no drama, just the parser that was already sitting there. π
It writes its diagnostics to standard error, and it's silent when every single input is valid β like, unless you turn on verbose mode, a clean run says absolutely nothing. which is iconic of it actually. quiet queen behavior. π
Now here's the part you need to remember, because it's lowkey the whole personality of this tool: when the sole toml_file operand is -, tomllint reads TOML from standard input and uses <stdin> as the diagnostic filename. but β and this is the catch β when - is supplied alongside other operands, it's treated as a literal filename. literally a file named -. no stdin magic. just a dash. π iykyk.
β¨ OPTIONS β¨
-h,--helpβ shows you a usage summary and then dips out. that's it, that's the whole job. π-v,--verboseβ writes an informational diagnostic for each input that passes validation. so instead of silence, you get receipts that everything was fine. π
π EXIT STATUS π
0β every input contains valid TOML, or help was requested. (help counts as a win, bestie π₯³)1β at least one input contains invalid TOML, or could not be opened. someone's not slaying today.2β the command line is invalid, such as when no input is supplied. you gotta give it something to chew on. π
π¦ DIAGNOSTICS π¦
TOML syntax errors use the following form:
filename:line:column: error: message
Files that cannot be opened use line and column zero:
filename:0:0: error: reason
With --verbose, successful inputs produce:
filename:1:1: info: linted successfully
see how the line and column are just vibing at 1:1 for a clean file? cute. the errors get the real coordinates though. π₯
π§ EXAMPLES π§
Check one file:
tomllint pyproject.toml
Check multiple files:
tomllint pyproject.toml config.toml
Check standard input:
tomllint -
Report successful validation:
tomllint --verbose pyproject.toml
π SEE ALSO π
real talk though: this is just a friendly wrapper around Python's built-in TOML parser, so if you want the deep lore, that's where you go. π
and that's the whole page bestie!! this was tomllint from the TOMLLINT(1) manual, dated 2026-07-31. go forth, lint your TOML, and remember: if the run is silent, you ate. π
β¨π¦πΈππ
π¦ where this page comes from
- fedora 44: python3-tomllint 0.3.6-1.fc44 Β· MIT-0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms