Skip to content

Commit

Permalink
pyreverse: Add output directory command-line option
Browse files Browse the repository at this point in the history
- Use the formatting of `black` pre-commit hook

Issue: pylint-dev#4159
  • Loading branch information
mbyrnepr2 committed Mar 7, 2021
1 parent cf41819 commit 0315e8f
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions pylint/pyreverse/writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ def write(self, diadefs):
basename = diagram.title.strip().replace(" ", "_")
file_name = f"{basename}.{self.config.output_format}"
if os.path.exists(self.config.output_directory):
file_name = os.path.join(
self.config.output_directory,
file_name)
file_name = os.path.join(self.config.output_directory, file_name)
self.set_printer(file_name, basename)
if diagram.TYPE == "class":
self.write_classes(diagram)
Expand Down

0 comments on commit 0315e8f

Please sign in to comment.