Completed
Pull Request — master (#39)
by Oleg
01:58
created

SdocStyle   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
dl 0
loc 18
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __init__() 0 12 1
1
from cleo import OutputFormatterStyle
2
from cleo.styles import CleoStyle
3
4
5
class SdocStyle(CleoStyle):
6
    """
7
    Output style for SDoc.
8
    """
9
10
    # ------------------------------------------------------------------------------------------------------------------
11
    def __init__(self, input, output):
12
        """
13
        Object constructor.
14
15
        :param cleo.inputs.input.Input input: The input object.
16
        :param cleo.outputs.output.Output output: The output object.
17
        """
18
        CleoStyle.__init__(self, input, output)
19
20
        # Style for file system objects (e.g. file and directory names).
21
        style = OutputFormatterStyle('green', None, ['bold'])
22
        output.get_formatter().set_style('fso', style)
23
24
# ----------------------------------------------------------------------------------------------------------------------
25
26