diff --git a/pyproject.toml b/pyproject.toml index 75e46a3..e5ba115 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "vban-cli" -version = "0.12.2" +version = "0.12.3" description = "A command-line interface for Voicemeeter leveraging VBAN." readme = "README.md" license = { text = "LICENSE" } diff --git a/src/vban_cli/strip.py b/src/vban_cli/strip.py index c2041b6..abe13b8 100644 --- a/src/vban_cli/strip.py +++ b/src/vban_cli/strip.py @@ -270,3 +270,23 @@ def b3( app.console.print(ctx.client.strip[index].B3) return ctx.client.strip[index].B3 = new_value + + +@app.command(name='label') +def label( + new_value: Annotated[Optional[str], Argument()] = None, + *, + index: Annotated[int, Parameter(parse=False)], + ctx: Annotated[Context, Parameter(parse=False)], +): + """Get or set the label of the specified strip. + + Parameters + ---------- + new_value : str, optional + If provided, sets the label to this value. If not provided, the current label is printed. + """ + if new_value is None: + app.console.print(ctx.client.strip[index].label) + return + ctx.client.strip[index].label = new_value diff --git a/uv.lock b/uv.lock index 0796979..9077b5e 100644 --- a/uv.lock +++ b/uv.lock @@ -124,7 +124,7 @@ wheels = [ [[package]] name = "vban-cli" -version = "0.12.2" +version = "0.12.3" source = { editable = "." } dependencies = [ { name = "cyclopts" },