Skip to content
Snippets Groups Projects
Commit 4d946e01 authored by Tomáš Orviský's avatar Tomáš Orviský
Browse files

Output is now named after input file

parent bdf6c5ab
No related merge requests found
......@@ -35,10 +35,6 @@ class MainScene(MovingCameraScene):
if __name__ == "__main__":
config.output_file = "PlantUML"
config.cairo_path = "media/images/"
config.ffmpeg_path = "media/videos/"
argparser = argparse.ArgumentParser(prog="pyplaml")
argparser.add_argument("file")
......@@ -48,6 +44,15 @@ if __name__ == "__main__":
args = argparser.parse_args()
src_file = Path(args.file)
if not src_file.is_file():
raise Exception("\"{}\" is not a file.".format(args.file))
config.output_file = src_file.stem
config.cairo_path = "media/images/"
config.ffmpeg_path = "media/videos/"
scene = MainScene()
scene.file = args.file
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment