Configure Bash script format rules
This commit is contained in:
20
.editorconfig
Normal file
20
.editorconfig
Normal file
@@ -0,0 +1,20 @@
|
||||
[*.sh]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
# --language-variant
|
||||
shell_variant = posix
|
||||
binary_next_line = true
|
||||
# --case-indent
|
||||
switch_case_indent = true
|
||||
space_redirects = true
|
||||
keep_padding = true
|
||||
# --func-next-line
|
||||
function_next_line = true
|
||||
|
||||
# Ignore the entire "third_party" directory when calling shfmt on directories,
|
||||
# such as "shfmt -l -w .". When formatting files directly,
|
||||
# like "shfmt -w third_party/foo.sh" or "shfmt --filename=third_party/foo.sh",
|
||||
# the ignore logic is applied only when the --apply-ignore flag is given.
|
||||
[third_party/**]
|
||||
ignore = true
|
||||
Reference in New Issue
Block a user