Ruby / Lua / Perl Formatter — Reindent Three Languages
Reindent only — not a full formatterReindent Ruby, Lua, or Perl source. One tool, three keyword-driven languages.
Cách dùng
- 1 Pick the language: Ruby, Lua, or Perl.
- 2 Paste source code.
- 3 Tune indent size — 2 spaces is idiomatic for Ruby, 2 or 4 for Lua and Perl.
- 4 Copy or download the result.
Vì sao dùng công cụ này
- One tool covers three syntactically similar block-end-keyword languages.
- Per-language openers: <code class="rounded bg-slate-100 px-1 text-xs dark:bg-slate-800">do/end</code> for Ruby, <code class="rounded bg-slate-100 px-1 text-xs dark:bg-slate-800">function/end</code> for Lua, braces for Perl.
- Pure client-side — your code never leaves the browser.
- For canonical output use RuboCop (Ruby), StyLua (Lua), or perltidy (Perl) locally.
Câu hỏi thường gặp
Is this RuboCop-compatible?
No — this is a reindenter only. RuboCop applies hundreds of style cops; we apply indent rules based on block-opening keywords.
Does it understand here-docs and string interpolation?
Indent is computed line-by-line, so here-doc bodies may receive an extra leading space. For files heavy in here-docs, run the language-specific formatter.
Why is one tool for three languages?
Block structure is similar — single keyword opens, <code class="rounded bg-slate-100 px-1 text-xs dark:bg-slate-800">end</code> or <code class="rounded bg-slate-100 px-1 text-xs dark:bg-slate-800">}</code> closes. One rule engine, three keyword sets.
Ruby / Lua / Perl Formatter là gì?
A Ruby / Lua / Perl Formatter is a tool that reindents Ruby, Lua, or Perl source code in the browser. It combines three keyword-driven languages into one formatter, applying consistent indentation based on each language's block structure while running entirely client-side.
Ruby / Lua / Perl Formatter là công cụ lập trình miễn phí của Zerethon Tools. Reindent Ruby, Lua, or Perl source. One tool, three keyword-driven languages. Chạy hoàn toàn trong trình duyệt — không đăng ký, không tải lên.
- Danh mục
- Lập trình
- Giá
- Miễn phí
- Quyền riêng tư
- Chạy trên trình duyệt
- Đăng ký
- Không cần
Quyền riêng tư
Dữ liệu của bạn không bao giờ rời khỏi trình duyệt trừ khi được nêu rõ. Ruby / Lua / Perl Formatter chạy hoàn toàn phía client — không tải lên máy chủ, không ghi log, không theo dõi dữ liệu bạn nhập.
Công cụ liên quan
JSON Formatter
Format, validate, and minify JSON online. Free, no signup — your data never leaves your browser.
Mở công cụSQL Formatter
Format SQL queries online — beautify MySQL, PostgreSQL, SQLite, SQL Server, Oracle, and BigQuery.
Mở công cụUUID Generator
Generate UUIDs online — v1, v4, v7, and Nil. Bulk generation up to 10,000. Free, no signup.
Mở công cụPassword Generator
Generate strong, cryptographically random passwords. Configurable length and character sets — runs in your browser.
Mở công cụBuild, share, and grow on Zerethon Social
Free signup. Earn points, collect achievements, and connect with creators worldwide.