reformat file
This commit is contained in:
parent
94640f9eff
commit
205dc4eeac
1 changed files with 4 additions and 0 deletions
|
@ -106,6 +106,7 @@ class SingleLineMacro(Macro, ABC):
|
||||||
):
|
):
|
||||||
self.chars = chars
|
self.chars = chars
|
||||||
self.strip = strip
|
self.strip = strip
|
||||||
|
|
||||||
def matches(self, line: str) -> bool:
|
def matches(self, line: str) -> bool:
|
||||||
if line.find(self.chars) != -1:
|
if line.find(self.chars) != -1:
|
||||||
if not line.strip(self.strip) == self.chars:
|
if not line.strip(self.strip) == self.chars:
|
||||||
|
@ -114,6 +115,7 @@ class SingleLineMacro(Macro, ABC):
|
||||||
else:
|
else:
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
class ConfigBeginMacro(SingleLineMacro):
|
class ConfigBeginMacro(SingleLineMacro):
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
super(ConfigBeginMacro, self).__init__(FORMATTER_PREFIX + INFILE_CONFIG_BEGIN_CONFIG)
|
super(ConfigBeginMacro, self).__init__(FORMATTER_PREFIX + INFILE_CONFIG_BEGIN_CONFIG)
|
||||||
|
@ -124,6 +126,7 @@ class ConfigBeginMacro(SingleLineMacro):
|
||||||
formatter.mode = FormatterMode.drop
|
formatter.mode = FormatterMode.drop
|
||||||
return []
|
return []
|
||||||
|
|
||||||
|
|
||||||
class ConfigEndMacro(SingleLineMacro):
|
class ConfigEndMacro(SingleLineMacro):
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
super(ConfigEndMacro, self).__init__(FORMATTER_PREFIX + INFILE_CONFIG_END_CONFIG)
|
super(ConfigEndMacro, self).__init__(FORMATTER_PREFIX + INFILE_CONFIG_END_CONFIG)
|
||||||
|
@ -134,6 +137,7 @@ class ConfigEndMacro(SingleLineMacro):
|
||||||
formatter.mode = FormatterMode.normal
|
formatter.mode = FormatterMode.normal
|
||||||
return []
|
return []
|
||||||
|
|
||||||
|
|
||||||
class ArgumentMacro(Macro):
|
class ArgumentMacro(Macro):
|
||||||
def __init__(
|
def __init__(
|
||||||
self,
|
self,
|
||||||
|
|
Loading…
Reference in a new issue