id = "gnu-indent" name = "GNU indent" homepage = "https://www.gnu.org/software/indent/" description = "A program for formatting C source code." executables = ["gindent"] platforms = ["macos", "linux"] [dotfiles] # GNU indent searches $HOME/.indent.pro after INDENT_PROFILE and the current # directory profile; Homebrew exposes this formula's binary as gindent. # https://www.gnu.org/software/indent/manual/html_chapter/indent_1.html paths = ["~/.indent.pro"] exclude = [] secret = [] [commands] format = 1 label = "Format C source" description = "Reformat C files with a chosen coding style. Numeric options such as indent level, line length and tab size are left out." quality = "ai-draft" parser = { end_of_options = "--", interleave = "permute", long_equals = false, short_attached = false, short_bundles = false } [[commands.source]] id = "man" kind = "manual" url = "https://manpages.debian.org/bookworm/indent/indent.1.en.html" revision = "2.2.12" evidence = """ indent [options] [input-files] indent [options] [single-input-file] [-o output-file] -gnu, --gnu-style -kr, --k-and-r-style -linux, --linux-style -orig, --original -nut, --no-tabs -ut, --use-tabs -st, --standard-output -npro, --ignore-profile -v, --verbose """ [[commands.field]] id = "files" label = "Input files" type = "path" position = 0 multiple = true path = { kind = "file", role = "input", must_exist = true } sources = ["man"] [[commands.field]] id = "output" label = "Output file" description = "Only valid with a single input file." type = "path" option = ["-o"] path = { kind = "file", role = "output", must_exist = false } effect = "overwrite" sources = ["man"] [[commands.field]] id = "gnu" label = "GNU style" type = "boolean" option = ["--gnu-style", "-gnu"] sources = ["man"] [[commands.field]] id = "kr" label = "K&R style" type = "boolean" option = ["--k-and-r-style", "-kr"] sources = ["man"] [[commands.field]] id = "linux" label = "Linux style" type = "boolean" option = ["--linux-style", "-linux"] sources = ["man"] [[commands.field]] id = "original" label = "Original Berkeley style" type = "boolean" option = ["--original", "-orig"] sources = ["man"] [[commands.field]] id = "no_tabs" label = "Use spaces instead of tabs" type = "boolean" option = ["--no-tabs", "-nut"] sources = ["man"] [[commands.field]] id = "stdout" label = "Write to standard output" description = "Print the result instead of rewriting the files in place." type = "boolean" option = ["--standard-output", "-st"] sources = ["man"] [[commands.field]] id = "ignore_profile" label = "Ignore .indent.pro" type = "boolean" option = ["--ignore-profile", "-npro"] sources = ["man"] [[commands.field]] id = "verbose" label = "Verbose" type = "boolean" option = ["--verbose", "-v"] sources = ["man"] [[commands.task]] id = "preview" label = "Preview to standard output" set = { stdout = [true] } lock = ["stdout"] fields = ["files", "gnu", "kr", "linux", "no_tabs", "stdout"] required = ["files"] [[commands.task]] id = "reformat" label = "Reformat in place" fields = ["files", "gnu", "kr", "linux", "no_tabs"] required = ["files"] [[commands.group]] id = "basic" label = "Basic" fields = ["files", "gnu", "kr", "linux", "original", "no_tabs", "stdout"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["output", "ignore_profile", "verbose"]