FISH\_INDENT(1) fish-shell FISH\_INDENT(1)

# [NAME](#NAME)

fish\_indent - indenter and prettifier

# [SYNOPSIS](#SYNOPSIS)

```
fish_indent [OPTIONS] [FILE ...]
```

# [DESCRIPTION](#DESCRIPTION)

**fish\_indent** is used to indent a piece of fish code. **fish\_indent** reads commands from standard input or the given filenames and outputs them to standard output or a specified file (if **-w** is given).

The following options are available:

[**-w** or **--write**](#w)

Indents a specified file and immediately writes to that file.

[**-i** or **--no-indent**](#i)

Do not indent commands; only reformat to one job per line.

[**--only-indent**](#only)

Do not reformat, only indent each line.

[**--only-unindent**](#only~2)

Do not reformat, only unindent each line.

[**-c** or **--check**](#c)

Do not indent, only return 0 if the code is already indented as fish\_indent would, the number of failed files otherwise. Also print the failed filenames if not reading from standard input.

[**-v** or **--version**](#v)

Displays the current **fish** version and then exits.

[**--ansi**](#ansi)

Colorizes the output using ANSI escape sequences using the colors defined in the environment (such as **fish\_color\_command** &lt;#envvar-fish\_color\_command&gt;).

[**--html**](#html)

Outputs HTML, which supports syntax highlighting if the appropriate CSS is defined. The CSS class names are the same as the variable names, such as **fish\_color\_command**.

[**--dump-parse-tree**](#dump)

Dumps information about the parsed statements to standard error. This is likely to be of interest only to people working on the fish source code.

[**-h** or **--help**](#h)

Displays help about using this command.

# [Copyright](#Copyright)

fish-shell developers

October 26, 2026 4.9

---

Document: fish_indent(1) from fish 4.9.3-r4 (Chainguard OS)
Source: https://github.com/fish-shell/fish-shell
