-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: do not align the inside of multiline strings [#123]]
- Loading branch information
Showing
4 changed files
with
33 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,13 @@ | ||
import logging | ||
from io import StringIO | ||
|
||
from snakefmt.formatter import Formatter | ||
from snakefmt.logging import LogConfig | ||
from snakefmt.parser.parser import Snakefile | ||
|
||
|
||
def setup_formatter(snake: str, line_length: int = None, black_config_file=None): | ||
stream = StringIO(snake) | ||
smk = Snakefile(stream) | ||
LogConfig.init(logging.DEBUG) | ||
return Formatter(smk, line_length=line_length, black_config_file=black_config_file) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters