2023-02-12 20:04:17 +01:00
|
|
|
# Note: I use this file as ~/.editorconfig when something doesn't specify to
|
|
|
|
# be root before reaching ~, so this contains files not seen in this repo
|
2023-02-12 12:22:30 +01:00
|
|
|
root = true
|
|
|
|
|
2023-02-12 20:04:17 +01:00
|
|
|
# Defaults
|
2023-02-12 12:22:30 +01:00
|
|
|
[*]
|
|
|
|
# Future: https://github.com/editorconfig/editorconfig/issues/89
|
2023-02-12 20:04:17 +01:00
|
|
|
# Linux line endings, this repo/file is unlikely to be used in Windows
|
2023-02-12 12:22:30 +01:00
|
|
|
end_of_line = lf
|
|
|
|
trim_trailing_whitespace = true
|
|
|
|
insert_final_newline = true
|
|
|
|
charset = utf-8
|
2023-02-12 13:19:08 +01:00
|
|
|
# Accessibility reasons. Vim: :%retab! (note also :set ts=4)
|
2023-02-12 12:22:30 +01:00
|
|
|
indent_style = tab
|
2023-02-12 14:52:08 +01:00
|
|
|
indent_size = tab
|
2023-02-12 20:04:17 +01:00
|
|
|
# Opinionated affecting only display, better to not set
|
2023-02-12 14:52:08 +01:00
|
|
|
#tab_width =
|
2023-02-12 12:22:30 +01:00
|
|
|
|
2023-02-13 16:03:29 +01:00
|
|
|
# *nix, just in case
|
2023-02-12 20:04:17 +01:00
|
|
|
[*.{bash,sh}]
|
|
|
|
end_of_line = lf
|
|
|
|
|
2023-02-26 18:34:30 +01:00
|
|
|
# Limnoria/Supybot config files use trailing spaces for empty config files,
|
|
|
|
# let's try to not break them.
|
|
|
|
[*.conf]
|
|
|
|
trim_trailing_whitespace = false
|
|
|
|
|
2023-02-13 16:14:49 +01:00
|
|
|
# Crystal https://crystal-lang.org/reference/1.7/conventions/coding_style.html#indentation
|
|
|
|
[*.cr]
|
|
|
|
indent_style = space
|
|
|
|
indent_size = 2
|
|
|
|
|
2023-02-13 10:13:55 +01:00
|
|
|
# Markdown apparently allows linebreaks by two trailing spaces, while I
|
|
|
|
# never seem to do that, maybe I should accept it
|
|
|
|
[*.{markdown,md}]
|
|
|
|
trim_trailing_whitespace = false
|
2023-02-21 18:32:11 +01:00
|
|
|
# Prettier seems to believe spaces are the only way to markdown
|
|
|
|
indent_style = space
|
|
|
|
indent_size = 2
|
2023-02-13 10:13:55 +01:00
|
|
|
|
2023-02-13 16:14:49 +01:00
|
|
|
# Nim https://nim-lang.org/docs/nep1.html#introduction-spacing-and-whitespace-conventions
|
|
|
|
[*.nim]
|
|
|
|
indent_style = space
|
|
|
|
indent_size = 2
|
|
|
|
max_line_length = 80
|
|
|
|
|
2023-02-13 16:03:29 +01:00
|
|
|
# Python https://peps.python.org/pep-0008/#indentation
|
|
|
|
[*.py]
|
|
|
|
indent_style = space
|
|
|
|
indent_size = 4
|
2023-02-13 16:14:49 +01:00
|
|
|
max_line_length = 79
|
2023-02-13 16:03:29 +01:00
|
|
|
|
|
|
|
# Ruby
|
|
|
|
#[*.rb]
|
|
|
|
# Unofficial Ruby Style guide says two spaces, but Wikipedia says it doesn't
|
|
|
|
# matter so I am going accessibility first and having this commented
|
|
|
|
# https://rubystyle.guide/#spaces-indentation
|
|
|
|
#indent_style = space
|
|
|
|
#indent_size = 2
|
|
|
|
|
2023-02-13 10:13:55 +01:00
|
|
|
# TAB Separated Values
|
|
|
|
[*.{tsv,tab}]
|
|
|
|
indent_style = tab
|
|
|
|
indent_size = tab
|
|
|
|
# empty last columns/fields
|
|
|
|
trim_trailing_whitespace = false
|
|
|
|
|
2023-02-13 16:03:29 +01:00
|
|
|
# Windows line-endings for Windows
|
|
|
|
[*.{reg,bat,ahk}]
|
|
|
|
end_of_line = crlf
|
2023-02-12 20:04:17 +01:00
|
|
|
|
2023-02-14 09:06:20 +01:00
|
|
|
# YAML requires spaces. The GitHub citation files look YAML to me.
|
|
|
|
# https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-citation-files
|
|
|
|
[*.{cff,yaml,yml}]
|
2023-02-12 20:04:17 +01:00
|
|
|
indent_style = space
|
|
|
|
indent_size = 2
|