Verified Commit 132fac2e authored by Alberto Miranda's avatar Alberto Miranda ♨️
Browse files

Add .cmake-format

parent dca6f50d
Loading
Loading
Loading
Loading

.cmake-format

0 → 100644
+49 −0
Original line number Diff line number Diff line
# ------------------------------------------------
# Options affecting comment reflow and formatting.
# ------------------------------------------------
with section("markup"):

  # enable comment markup parsing and reflow
  enable_markup = False

# -----------------------------
# Options affecting formatting.
# -----------------------------
with section("format"):

  # Disable formatting entirely, making cmake-format a no-op
  disable = False

  # How wide to allow formatted cmake files
  line_width = 80

  # How many spaces to tab for indent
  tab_size = 2

  # If true, lines are indented using tab characters (utf-8 0x09) instead of
  # <tab_size> space characters (utf-8 0x20). In cases where the layout would
  # require a fractional tab character, the behavior of the  fractional
  # indentation is governed by <fractional_tab_policy>
  use_tabchars = False

  # If true, separate flow control names from their parentheses with a space
  separate_ctrl_name_with_space = False

  # If true, separate function names from parentheses with a space
  separate_fn_name_with_space = False

  # If a statement is wrapped to more than one line, than dangle the closing
  # parenthesis on its own line.
  dangle_parens = True

#  # If an argument group contains more than this many sub-groups (parg or kwarg
#  # groups) then force it to a vertical layout.
#  max_subgroups_hwrap = 2
#
#  # If a positional argument group contains more than this many arguments, then
#  # force it to a vertical layout.
#  max_pargs_hwrap = 2
#
#  # If a cmdline positional group consumes more than this many lines without
#  # nesting, then invalidate the layout (and nest)
#  max_rows_cmdline = 2