Skip to content

Commit ae76ac3

Browse files
Add --no-lint (-nl) option to beet dev
1 parent fd51c5e commit ae76ac3

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

gm4/commands.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,9 @@
3333
@click.option("-r", "--reload", is_flag=True, help="Enable live data pack reloading.")
3434
@click.option("-l", "--link", metavar="WORLD", help="Link the project before watching.")
3535
@click.option("-c", "--clean", is_flag=True, help="Clean the output folder.")
36-
@click.option("--log", default="INFO", type=str, help="Set the logger level")
37-
def dev(ctx: click.Context, project: Project, modules: tuple[str, ...], watch: bool, reload: bool, link: str | None, clean: bool, log: int | str):
36+
@click.option("--log", default="INFO", type=str, help="Set the logger level.")
37+
@click.option("-nl", "--no-lint", is_flag=True, help="Skips the mecha linting step.")
38+
def dev(ctx: click.Context, project: Project, modules: tuple[str, ...], watch: bool, reload: bool, link: str | None, clean: bool, log: int | str, no_lint: bool):
3839
"""Build or watch modules for development."""
3940

4041
module_folders = sorted(glob.glob("gm4_*"))
@@ -79,6 +80,8 @@ def dev(ctx: click.Context, project: Project, modules: tuple[str, ...], watch: b
7980
# command-determined config options
8081
broadcast_config: dict[str, Any] = next((p for p in config["pipeline"] if isinstance(p, dict))) # type: ignore
8182
broadcast_config["broadcast"] = selected_modules
83+
if no_lint:
84+
broadcast_config["require"].insert(0, "gm4.plugins.test.skip_mecha_lint")
8285
if reload:
8386
broadcast_config["require"].insert(0, "beet.contrib.livereload")
8487

0 commit comments

Comments
 (0)