其中-l80是每一行最多80个字母,超出会拆行,如果不喜欢可以使用更长的行字数
使用的indent参数 值 含义
–blank-lines-after-declarations
–blank-lines-after-procedures
–blank-lines-before-block-comments
–break-before-boolean-operator
–blank-lines-after-commas
–braces-after-if-line
–brace-indent 0
–braces-after-struct-decl-line
–comment-indentationn
–declaration-comment-columnn
–comment-delimiters-on-blank-lines
–cuddle-do-while
–cuddle-else
–case-indentation 0
–else-endif-columnn
–space-after-cast
–line-comments-indentation n
–break-function-decl-args
–declaration-indentationn
–format-first-column-comments
–format-all-comments
–honour-newlines
–indent-leveln
–parameter-indentationn
–line-length 75
–continue-at-parentheses
–space-after-procedure-calls
–space-after-parentheses
–procnames-start-lines
–space-after-for
–space-after-if
–space-after-while
–start-left-side-of-comments
–swallow-optional-blank-lines
–space-special-semicolon
–tab-size
–use-tabs
例如: indent -kr -i4 -ts8 -sob -l80
发表评论
要发表评论,您必须先登录。