From 26f4cd96d4a1d6cf8f98164317f0dd1bee9067e3 Mon Sep 17 00:00:00 2001 From: yrriban Date: Mon, 9 Jun 2025 22:22:59 -0400 Subject: [PATCH] Correctly handle an unknown target for ls. --- dcc/ls.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dcc/ls.py b/dcc/ls.py index 7d78610..9fb1a81 100644 --- a/dcc/ls.py +++ b/dcc/ls.py @@ -17,7 +17,9 @@ class List(dcc.config.Base): case "demos": self.list(x.name for x in os.scandir(self.demos.joinpath(parsed_args.wad)) if x.name.endswith(".lmp")) case "videos": - self.list(x.name for x in os.scandir(self.output.joinpath(parsed_args.wad)) if x.name.endswith(".mp4")) + self.list(x.name for x in os.scandir(self.fabricate.joinpath(parsed_args.wad)) if x.name.endswith(".mp4")) + case _: + raise Exception(f"unknown target {parsed_args.target}") def list(self, gen): # TODO: fancy text?