|
| 1 | +# stylish-haskell configuration file |
| 2 | +# ================================== |
| 3 | + |
| 4 | +# The stylish-haskell tool is mainly configured by specifying steps. These steps |
| 5 | +# are a list, so they have an order, and one specific step may appear more than |
| 6 | +# once (if needed). Each file is processed by these steps in the given order. |
| 7 | +steps: |
| 8 | + # Import cleanup |
| 9 | + - imports: |
| 10 | + # There are different ways we can align names and lists. |
| 11 | + # |
| 12 | + # - global: Align the import names and import list throughout the entire |
| 13 | + # file. |
| 14 | + # |
| 15 | + # - file: Like global, but don't add padding when there are no qualified |
| 16 | + # imports in the file. |
| 17 | + # |
| 18 | + # - group: Only align the imports per group (a group is formed by adjacent |
| 19 | + # import lines). |
| 20 | + # |
| 21 | + # - none: Do not perform any alignment. |
| 22 | + # |
| 23 | + # Default: global. |
| 24 | + align: file |
| 25 | + |
| 26 | + # Language pragmas |
| 27 | + - language_pragmas: |
| 28 | + # We can generate different styles of language pragma lists. |
| 29 | + # |
| 30 | + # - vertical: Vertical-spaced language pragmas, one per line. |
| 31 | + # |
| 32 | + # - compact: A more compact style. |
| 33 | + # |
| 34 | + # - compact_line: Similar to compact, but wrap each line with |
| 35 | + # `{-#LANGUAGE #-}'. |
| 36 | + # |
| 37 | + # Default: vertical. |
| 38 | + style: vertical |
| 39 | + |
| 40 | + # stylish-haskell can detect redundancy of some language pragmas. If this |
| 41 | + # is set to true, it will remove those redundant pragmas. Default: true. |
| 42 | + remove_redundant: true |
| 43 | + |
| 44 | + # Replace tabs by spaces. This is disabled by default. |
| 45 | + # - tabs: |
| 46 | + # # Number of spaces to use for each tab. Default: 8, as specified by the |
| 47 | + # # Haskell report. |
| 48 | + # spaces: 8 |
| 49 | + |
| 50 | + # Remove trailing whitespace |
| 51 | + - trailing_whitespace: {} |
| 52 | + |
| 53 | +# A common setting is the number of columns (parts of) code will be wrapped |
| 54 | +# to. Different steps take this into account. Default: 80. |
| 55 | +columns: 94 |
| 56 | + |
| 57 | +# Sometimes, language extensions are specified in a cabal file or from the |
| 58 | +# command line instead of using language pragmas in the file. stylish-haskell |
| 59 | +# needs to be aware of these, so it can parse the file correctly. |
| 60 | +# |
| 61 | +# No language extensions are enabled by default. |
| 62 | +language_extensions: |
| 63 | + - MultiParamTypeClasses |
0 commit comments