# Copyright (C)  2019-2020  Marco Bresciani.
#
# Copying and distribution of this file, with or without modification,
# are permitted in any medium without royalty provided the copyright
# notice and this notice are preserved. This file is offered as-is,
# without any warranty.
#
# SPDX-FileCopyrightText: 2019-2020 Marco Bresciani
#
# SPDX-License-Identifier: FSFAP


# top-most EditorConfig file
root = true

########################################################################
[*]
# Let's encode the whole world with UTF-8
charset = utf-8

# Windows-style newlines (see RFC 678, RFC 2046, RFC 2646, ...)
end_of_line = crlf

# Due to RFC 678, RFC 2046, RFC 2646, ... the indent style uses spaces.
indent_style = space

# with a newline ending every file (see POSIX standard)
insert_final_newline = true

# Maximum 72 characters per line (see RFC 678, RFC 2046, RFC 2646, ...)
max_line_length = 72

# Hor. tab is set to 8 characters (see RFC 678, RFC 2046, RFC 2646, ...)
tab_width = 8

# Remove all trailing whitespaces from files
trim_trailing_whitespace = true


########################################################################
[*.md]
# Four spaces are defined as the unit of indentation.
indent_size = 4

# Tabs should be 4 spaces for Markdown (see
# https://daringfireball.net/projects/markdown/syntax) but due to RFC
# 678, RFC 2046, RFC 2646, ... I've decided that indent style uses
# spaces and horizontal tab is set to 8 characters

# Property (apparently/possibly) supported by IntelliJ IDEA
continuation_indent_size = 8


########################################################################
[*.{java, groovy}]
# See java Code Conventions at
# https://www.oracle.com/technetwork/java/javase/documentation/codeconventions-136091.html#262

# Four spaces should be used as the unit of indentation. The exact
# construction of the indentation (spaces vs. tabs) is unspecified.
# Tabs must be set exactly every 8 spaces (not 4).
indent_size = 4

# If the above rules lead to confusing code or to code that's squished
# up against the right margin, just indent 8 spaces instead.

# Property (apparently/possibly) supported by IntelliJ IDEA
continuation_indent_size = 8


########################################################################
[*.json]
indent_size = 4

# Property (apparently/possibly) supported by IntelliJ IDEA
continuation_indent_size = 8


########################################################################
# See Code Conventions for the JavaScript Programming Language at
# https://crockford.com/javascript/code.html
[*.js]
indent_size = 4

# Property (apparently/possibly) supported by IntelliJ IDEA
continuation_indent_size = 4


########################################################################
[*.{sh, spec}]
# Unix-style newlines (see RFC 678, RFC 2046, RFC 2646, ...)
end_of_line = lf

# Property (apparently/possibly) supported by IntelliJ IDEA
continuation_indent_size = 4


########################################################################
[*.rb]
indent_size = 2

# Property (apparently/possibly) supported by IntelliJ IDEA
continuation_indent_size = 4
