name Indentation Rules scope source.go settings decreaseIndentPattern (?x) ^ # start of line (.*\*/)? # skip comments if present ( # three possibilities \s* \} # whitespace and a closing curly brace ( # capture: [^}{"']* \{ # anything other than curly braces or quotes, then open curly )? # (optional) [;\s]*? # any whitespace or semicolons | (?:\s* (case|default).*:) # case statements pop back one indent | (?: \) (?<! \( ) ) # closing braces not preceded by opening braces ) (//.*|/\*.*\*/\s*)? # skip any comments (optional) $ # end of line increaseIndentPattern (?x) ^ (?: .* \*/ )? # skip any comments (?: (.* \{ [^}"'\n]*) # lines containing an open curly but no quotes or close curly | # OR (?:\s* (case|default).*:) # case statements | # OR (.* \( [^)"'\n]*) # lines containing an open brace but no quotes or close brace ) (//.*|/\*.*\*/\s*)? # skip any comments (optional) $ unIndentedLinePattern ^\s*((/\*|\*/|//|import\b.*|package\b.*).*)?$ uuid 160118A4-208D-4422-AFF0-0C21B5B78AAF