2023-05-19 19:35:05 +02:00
|
|
|
# See https://editorconfig.org for more information
|
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-04-04 08:18:58 +02:00
|
|
|
# Remember to always .gitattributes. lf line-endings are prettier default and
|
|
|
|
# required by doctoc, so enabling either of those breaks on Windows unless lf
|
|
|
|
# is specified here and in .gitattributes
|
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-04-04 08:28:36 +02:00
|
|
|
# Usable in common Braille displays? Line continuation marker and diffing
|
|
|
|
# take two. Prettier default 80. WCAG requirement 80.
|
|
|
|
max_line_length = 78
|
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
|
|
|
|
2024-06-06 19:19:30 +02:00
|
|
|
# https://github.com/jxddk/prettier-plugin-nginx/issues/8
|
|
|
|
[*.nginx]
|
|
|
|
insert_final_newline = unset
|
|
|
|
indent_style = unset
|
|
|
|
|
2023-02-13 16:03:29 +01:00
|
|
|
# *nix, just in case
|
2023-02-12 20:04:17 +01:00
|
|
|
[*.{bash,sh}]
|
2023-04-04 08:18:58 +02:00
|
|
|
# .gitattributes !
|
2023-02-12 20:04:17 +01:00
|
|
|
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-04-04 11:51:57 +02:00
|
|
|
[*.csv]
|
2023-09-13 19:18:13 +02:00
|
|
|
max_line_length = unset
|
2023-04-04 11:51:57 +02:00
|
|
|
|
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
|
2023-03-10 08:57:58 +01:00
|
|
|
[{LICENSE,*.{markdown,md}}]
|
2023-02-13 10:13:55 +01:00
|
|
|
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
|
2024-07-08 08:15:20 +02:00
|
|
|
end_of_line = lf
|
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-10-17 06:46:07 +02: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-09-28 10:10:58 +02:00
|
|
|
# LaTeX with git should be used one sentence per line for maximum efficiency
|
|
|
|
[*.tex]
|
|
|
|
max_line_length = unset
|
|
|
|
|
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-09-13 19:18:13 +02:00
|
|
|
max_line_length = unset
|
2023-02-13 10:13:55 +01:00
|
|
|
|
2023-04-04 08:28:36 +02:00
|
|
|
# RFC 678
|
|
|
|
#[*.txt]
|
|
|
|
#max_line_length = 72
|
|
|
|
|
2023-02-13 16:03:29 +01:00
|
|
|
# Windows line-endings for Windows
|
|
|
|
[*.{reg,bat,ahk}]
|
2023-04-04 08:18:58 +02:00
|
|
|
# Remember the .gitattributes !
|
2023-02-13 16:03:29 +01:00
|
|
|
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
|
2024-07-29 08:22:14 +02:00
|
|
|
[*.{cff,yaml,yml}]
|
2023-02-12 20:04:17 +01:00
|
|
|
indent_style = space
|
|
|
|
indent_size = 2
|