15 Commits

Author SHA1 Message Date
github-actions[bot]
32e2646a3d chore: auto-update Go modules 2026-04-13 00:09:15 +00:00
github-actions[bot]
3960b1969f chore: auto-update Go modules 2026-04-06 00:07:35 +00:00
github-actions[bot]
49138e397c chore: auto-update Go modules 2026-03-30 00:07:20 +00:00
68b8ab2018 add flag tags to Config flags 2026-03-27 13:34:57 +00:00
6ec3c55383 improve consistency of tags 2026-03-27 13:23:46 +00:00
847dffd842 increase the column count for the generated help output 2026-03-27 07:38:16 +00:00
283511b94d add ToC to README
add Shell Completion section to README
2026-03-24 00:56:03 +00:00
github-actions[bot]
a1c27a3f1b chore: auto-update Go modules 2026-03-23 00:05:49 +00:00
828d7cc248 add go mod tidy hook 2026-03-21 13:57:22 +00:00
5fa2aabecb upd generate help script 2026-03-21 11:08:41 +00:00
ac8a677f99 add generate task
run it from pre-commit
2026-03-21 10:46:16 +00:00
e0c15f3ba5 remove duplicate taskfiles 2026-03-20 20:06:37 +00:00
1f4b261fc4 remove duplicate taskfile 2026-03-20 19:53:55 +00:00
739ce44288 add generate-readme task
add generate_help.go

update pre-commit hook
2026-03-20 19:49:36 +00:00
1b9cc1f66a add man command to both CLIs
add man Taskfiles
2026-03-20 19:20:29 +00:00
29 changed files with 462 additions and 428 deletions

6
.gitignore vendored
View File

@@ -38,4 +38,8 @@ go.work.sum
# End of ignr # End of ignr
update_readme.py # Man pages
xair-cli.1
x32-cli.1
update_readme.py

View File

@@ -3,6 +3,11 @@ repos:
hooks: hooks:
- id: update-readme - id: update-readme
name: update-readme name: update-readme
entry: python update_readme.py entry: task generate
language: python language: system
pass_filenames: false pass_filenames: false
- repo: https://github.com/tekwizely/pre-commit-golang
rev: v1.0.0-rc.4
hooks:
- id: go-mod-tidy

View File

@@ -1,5 +1,15 @@
# xair-cli # xair-cli
---
## Table of Contents
- [Installation](#installation)
- [Configuration](#configuration)
- [Use](#use)
- [Shell Completion](#shell-completion)
- [License](#license)
### Installation ### Installation
*xair-cli* *xair-cli*
@@ -60,8 +70,8 @@ export X32_CLI_LOGLEVEL=warn
For each command/subcommand in the tree there exists a `--help` flag, use it to print usage information. For each command/subcommand in the tree there exists a `--help` flag, use it to print usage information.
- [xair-cli](./xair-help.md) - [xair-cli](./tools/xair-help.md)
- [x32-cli](./x32-help.md) - [x32-cli](./tools/x32-help.md)
### Examples ### Examples
@@ -113,6 +123,34 @@ xair-cli snapshot 20 save 'twitch live'
--- ---
## Shell Completion
- completion:
*optional*
- args: Shell
- If no shell is passed completion will attempt to detect the current login shell.
*xair-cli*
```console
xair-cli completion
xair-cli completion bash
```
*x32-cli*
```console
x32-cli completion
x32-cli completion bash
```
Currently supported shells: *bash* *zsh* *fish*.
---
### License ### License
`xair-cli` is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license. `xair-cli` is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license.

View File

@@ -1,22 +0,0 @@
version: '3'
vars:
WINDOWS: '{{.BIN_DIR}}/{{.PROGRAM}}_windows_amd64.exe'
LINUX: '{{.BIN_DIR}}/{{.PROGRAM}}_linux_amd64'
MACOS: '{{.BIN_DIR}}/{{.PROGRAM}}_darwin_amd64'
tasks:
windows-amd64:
desc: Build the xair-cli project for Windows
cmds:
- GOOS=windows GOARCH=amd64 go build -o {{.WINDOWS}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}}
linux-amd64:
desc: Build the xair-cli project for Linux
cmds:
- GOOS=linux GOARCH=amd64 go build -o {{.LINUX}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}}
darwin-amd64:
desc: Build the xair-cli project for macOS
cmds:
- GOOS=darwin GOARCH=amd64 go build -o {{.MACOS}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}}

View File

@@ -7,16 +7,16 @@ vars:
tasks: tasks:
windows-amd64: windows-amd64:
desc: Build the x32-cli project for Windows desc: Build the project for Windows
cmds: cmds:
- GOOS=windows GOARCH=amd64 go build -o {{.WINDOWS}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}} - GOOS=windows GOARCH=amd64 go build -o {{.WINDOWS}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}}
linux-amd64: linux-amd64:
desc: Build the x32-cli project for Linux desc: Build the project for Linux
cmds: cmds:
- GOOS=linux GOARCH=amd64 go build -o {{.LINUX}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}} - GOOS=linux GOARCH=amd64 go build -o {{.LINUX}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}}
darwin-amd64: darwin-amd64:
desc: Build the x32-cli project for macOS desc: Build the project for macOS
cmds: cmds:
- GOOS=darwin GOARCH=amd64 go build -o {{.MACOS}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}} - GOOS=darwin GOARCH=amd64 go build -o {{.MACOS}} -ldflags="-X main.version={{.VERSION}}" ./cmd/{{.PROGRAM}}

17
Taskfile.man.yml Normal file
View File

@@ -0,0 +1,17 @@
version: '3'
tasks:
default:
desc: View man page
cmds:
- task: view
view:
desc: View man page
cmds:
- go run ./cmd/{{.PROGRAM}} --man | man -l -
generate:
desc: Generate man page
cmds:
- go run ./cmd/{{.PROGRAM}} --man > {{.PROGRAM}}.1

View File

@@ -2,15 +2,23 @@ version: '3'
includes: includes:
build-xair: build-xair:
taskfile: ./Taskfile.build-xair.yml taskfile: ./Taskfile.build.yml
internal: true internal: true
vars: vars:
PROGRAM: xair-cli PROGRAM: xair-cli
build-x32: build-x32:
taskfile: ./Taskfile.build-x32.yml taskfile: ./Taskfile.build.yml
internal: true internal: true
vars: vars:
PROGRAM: x32-cli PROGRAM: x32-cli
man-xair:
taskfile: ./Taskfile.man.yml
vars:
PROGRAM: xair-cli
man-x32:
taskfile: ./Taskfile.man.yml
vars:
PROGRAM: x32-cli
vars: vars:
SHELL: '{{if eq .OS "Windows_NT"}}powershell{{end}}' SHELL: '{{if eq .OS "Windows_NT"}}powershell{{end}}'
@@ -54,3 +62,8 @@ tasks:
desc: Clean the build artifacts desc: Clean the build artifacts
cmds: cmds:
- '{{.SHELL}} rm -r {{.BIN_DIR}}' - '{{.SHELL}} rm -r {{.BIN_DIR}}'
generate:
desc: Run code generation
cmds:
- COLUMNS=120 go generate ./...

View File

@@ -9,6 +9,7 @@ import (
"time" "time"
"github.com/alecthomas/kong" "github.com/alecthomas/kong"
mangokong "github.com/alecthomas/mango-kong"
"github.com/charmbracelet/log" "github.com/charmbracelet/log"
kongcompletion "github.com/jotaen/kong-completion" kongcompletion "github.com/jotaen/kong-completion"
@@ -39,10 +40,10 @@ type context struct {
} }
type Config struct { type Config struct {
Host string `default:"mixer.local" help:"The host of the X32 device." env:"X32_CLI_HOST" short:"H"` Host string `flag:"" default:"mixer.local" help:"The host of the X32 device." env:"X32_CLI_HOST" short:"H"`
Port int `default:"10023" help:"The port of the X32 device." env:"X32_CLI_PORT" short:"P"` Port int `flag:"" default:"10023" help:"The port of the X32 device." env:"X32_CLI_PORT" short:"P"`
Timeout time.Duration `default:"100ms" help:"Timeout for OSC operations." env:"X32_CLI_TIMEOUT" short:"T"` Timeout time.Duration `flag:"" default:"100ms" help:"Timeout for OSC operations." env:"X32_CLI_TIMEOUT" short:"T"`
Loglevel string `default:"warn" help:"Log level for the CLI." env:"X32_CLI_LOGLEVEL" short:"L" enum:"debug,info,warn,error,fatal"` Loglevel string `flag:"" default:"warn" help:"Log level for the CLI." env:"X32_CLI_LOGLEVEL" short:"L" enum:"debug,info,warn,error,fatal"`
} }
// CLI is the main struct for the command-line interface. // CLI is the main struct for the command-line interface.
@@ -50,20 +51,21 @@ type Config struct {
type CLI struct { type CLI struct {
Config `embed:"" prefix:"" help:"The configuration for the CLI."` Config `embed:"" prefix:"" help:"The configuration for the CLI."`
Version VersionFlag `help:"Print x32-cli version information and quit" name:"version" short:"v"` Man mangokong.ManFlag `help:"Print man page."`
Version VersionFlag `help:"Print x32-cli version information and quit" name:"version" short:"v"`
Completion kongcompletion.Completion `help:"Generate shell completion scripts." cmd:""` Completion kongcompletion.Completion `cmd:"" help:"Generate shell completion scripts."`
Info InfoCmd `help:"Print mixer information." cmd:""` Info InfoCmd `cmd:"" help:"Print mixer information."`
Raw RawCmd `help:"Send raw OSC messages to the mixer." cmd:""` Raw RawCmd `cmd:"" help:"Send raw OSC messages to the mixer."`
Main MainCmdGroup `help:"Control the Main L/R output" cmd:"" group:"Main"` Main MainCmdGroup `cmd:"" help:"Control the Main L/R output" group:"Main"`
Mainmono MainMonoCmdGroup `help:"Control the Main Mono output" cmd:"" group:"MainMono"` Mainmono MainMonoCmdGroup `cmd:"" help:"Control the Main Mono output" group:"MainMono"`
Matrix MatrixCmdGroup `help:"Control the matrix outputs." cmd:"" group:"Matrix"` Matrix MatrixCmdGroup `cmd:"" help:"Control the matrix outputs." group:"Matrix"`
Strip StripCmdGroup `help:"Control the strips." cmd:"" group:"Strip"` Strip StripCmdGroup `cmd:"" help:"Control the strips." group:"Strip"`
Bus BusCmdGroup `help:"Control the buses." cmd:"" group:"Bus"` Bus BusCmdGroup `cmd:"" help:"Control the buses." group:"Bus"`
Headamp HeadampCmdGroup `help:"Control input gain and phantom power." cmd:"" group:"Headamp"` Headamp HeadampCmdGroup `cmd:"" help:"Control input gain and phantom power." group:"Headamp"`
Snapshot SnapshotCmdGroup `help:"Save and load mixer states." cmd:"" group:"Snapshot"` Snapshot SnapshotCmdGroup `cmd:"" help:"Save and load mixer states." group:"Snapshot"`
Dca DCACmdGroup `help:"Control DCA groups." cmd:"" group:"DCA"` Dca DCACmdGroup `cmd:"" help:"Control DCA groups." group:"DCA"`
} }
func main() { func main() {

View File

@@ -7,8 +7,8 @@ import (
type DCACmdGroup struct { type DCACmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the DCA group (1-8)."` Index int `arg:"" help:"The index of the DCA group (1-8)."`
Mute DCAMuteCmd `help:"Get or set the mute status of the DCA group." cmd:""` Mute DCAMuteCmd `cmd:"" help:"Get or set the mute status of the DCA group."`
Name DCANameCmd `help:"Get or set the name of the DCA group." cmd:""` Name DCANameCmd `cmd:"" help:"Get or set the name of the DCA group."`
} `arg:"" help:"Control a specific DCA group by its index."` } `arg:"" help:"Control a specific DCA group by its index."`
} }

View File

@@ -11,8 +11,8 @@ import (
type HeadampCmdGroup struct { type HeadampCmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the headamp."` Index int `arg:"" help:"The index of the headamp."`
Gain HeadampGainCmd `help:"Get or set the gain of the headamp." cmd:""` Gain HeadampGainCmd `cmd:"" help:"Get or set the gain of the headamp."`
Phantom HeadampPhantomCmd `help:"Get or set the phantom power state of the headamp." cmd:""` Phantom HeadampPhantomCmd `cmd:"" help:"Get or set the phantom power state of the headamp."`
} `arg:"" help:"Control a specific headamp by index."` } `arg:"" help:"Control a specific headamp by index."`
} }
@@ -99,7 +99,7 @@ func gradualGainAdjust(
// HeadampPhantomCmd defines the command for getting or setting the phantom power state of a headamp, allowing users to specify the desired state as "true"/"on" or "false"/"off". // HeadampPhantomCmd defines the command for getting or setting the phantom power state of a headamp, allowing users to specify the desired state as "true"/"on" or "false"/"off".
type HeadampPhantomCmd struct { type HeadampPhantomCmd struct {
State *string `help:"The phantom power state of the headamp." arg:"" enum:"true,on,false,off" optional:""` State *string `arg:"" help:"The phantom power state of the headamp." enum:"true,on,false,off" optional:""`
} }
// Validate checks if the provided phantom power state is valid and normalises it to "true" or "false". // Validate checks if the provided phantom power state is valid and normalises it to "true" or "false".

View File

@@ -8,14 +8,14 @@ import (
// MainCmdGroup defines the command group for controlling the Main L/R output, including commands for mute state, fader level, and fade-in/fade-out times. // MainCmdGroup defines the command group for controlling the Main L/R output, including commands for mute state, fader level, and fade-in/fade-out times.
type MainCmdGroup struct { type MainCmdGroup struct {
Mute MainMuteCmd `help:"Get or set the mute state of the Main L/R output." cmd:""` Mute MainMuteCmd `cmd:"" help:"Get or set the mute state of the Main L/R output."`
Fader MainFaderCmd `help:"Get or set the fader level of the Main L/R output." cmd:""` Fader MainFaderCmd `cmd:"" help:"Get or set the fader level of the Main L/R output."`
Fadein MainFadeinCmd `help:"Fade in the Main L/R output over a specified duration." cmd:""` Fadein MainFadeinCmd `cmd:"" help:"Fade in the Main L/R output over a specified duration."`
Fadeout MainFadeoutCmd `help:"Fade out the Main L/R output over a specified duration." cmd:""` Fadeout MainFadeoutCmd `cmd:"" help:"Fade out the Main L/R output over a specified duration."`
Eq MainEqCmdGroup `help:"Commands for controlling the equaliser settings of the Main L/R output." cmd:"eq"` Eq MainEqCmdGroup `cmd:"" help:"Commands for controlling the equaliser settings of the Main L/R output."`
Comp MainCompCmdGroup `help:"Commands for controlling the compressor settings of the Main L/R output." cmd:"comp"` Comp MainCompCmdGroup `cmd:"" help:"Commands for controlling the compressor settings of the Main L/R output."`
} }
// MainMuteCmd defines the command for getting or setting the mute state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MainMuteCmd defines the command for getting or setting the mute state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off".
@@ -134,14 +134,14 @@ func (cmd *MainFadeoutCmd) Run(ctx *context) error {
// MainEqCmdGroup defines the command group for controlling the equaliser settings of the Main L/R output, including commands for getting or setting the EQ parameters. // MainEqCmdGroup defines the command group for controlling the equaliser settings of the Main L/R output, including commands for getting or setting the EQ parameters.
type MainEqCmdGroup struct { type MainEqCmdGroup struct {
On MainEqOnCmd `help:"Get or set the EQ on/off state of the Main L/R output." cmd:"on"` On MainEqOnCmd `cmd:"" help:"Get or set the EQ on/off state of the Main L/R output."`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain MainEqBandGainCmd `help:"Get or set the gain of the specified EQ band." cmd:"gain"` Gain MainEqBandGainCmd `cmd:"" help:"Get or set the gain of the specified EQ band." `
Freq MainEqBandFreqCmd `help:"Get or set the frequency of the specified EQ band." cmd:"freq"` Freq MainEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the specified EQ band."`
Q MainEqBandQCmd `help:"Get or set the Q factor of the specified EQ band." cmd:"q"` Q MainEqBandQCmd `cmd:"" help:"Get or set the Q factor of the specified EQ band."`
Type MainEqBandTypeCmd `help:"Get or set the type of the specified EQ band." cmd:"type"` Type MainEqBandTypeCmd `cmd:"" help:"Get or set the type of the specified EQ band."`
} `help:"Commands for controlling individual EQ bands of the Main L/R output." arg:""` } ` help:"Commands for controlling individual EQ bands of the Main L/R output." arg:""`
} }
// Validate checks if the provided EQ band number is within the valid range (1-6) for the Main L/R output. // Validate checks if the provided EQ band number is within the valid range (1-6) for the Main L/R output.
@@ -291,15 +291,15 @@ func (cmd *MainEqBandTypeCmd) Run(ctx *context, mainEq *MainEqCmdGroup) error {
// MainCompCmdGroup defines the command group for controlling the compressor settings of the Main L/R output, including commands for getting or setting the compressor parameters. // MainCompCmdGroup defines the command group for controlling the compressor settings of the Main L/R output, including commands for getting or setting the compressor parameters.
type MainCompCmdGroup struct { type MainCompCmdGroup struct {
On MainCompOnCmd `help:"Get or set the compressor on/off state of the Main L/R output." cmd:"on"` On MainCompOnCmd `cmd:"" help:"Get or set the compressor on/off state of the Main L/R output."`
Mode MainCompModeCmd `help:"Get or set the compressor mode of the Main L/R output." cmd:"mode"` Mode MainCompModeCmd `cmd:"" help:"Get or set the compressor mode of the Main L/R output."`
Threshold MainCompThresholdCmd `help:"Get or set the compressor threshold of the Main L/R output." cmd:"threshold"` Threshold MainCompThresholdCmd `cmd:"" help:"Get or set the compressor threshold of the Main L/R output."`
Ratio MainCompRatioCmd `help:"Get or set the compressor ratio of the Main L/R output." cmd:"ratio"` Ratio MainCompRatioCmd `cmd:"" help:"Get or set the compressor ratio of the Main L/R output."`
Mix MainCompMixCmd `help:"Get or set the compressor mix level of the Main L/R output." cmd:"mix"` Mix MainCompMixCmd `cmd:"" help:"Get or set the compressor mix level of the Main L/R output."`
Makeup MainCompMakeupCmd `help:"Get or set the compressor makeup gain of the Main L/R output." cmd:"makeup"` Makeup MainCompMakeupCmd `cmd:"" help:"Get or set the compressor makeup gain of the Main L/R output."`
Attack MainCompAttackCmd `help:"Get or set the compressor attack time of the Main L/R output." cmd:"attack"` Attack MainCompAttackCmd `cmd:"" help:"Get or set the compressor attack time of the Main L/R output."`
Hold MainCompHoldCmd `help:"Get or set the compressor hold time of the Main L/R output." cmd:"hold"` Hold MainCompHoldCmd `cmd:"" help:"Get or set the compressor hold time of the Main L/R output."`
Release MainCompReleaseCmd `help:"Get or set the compressor release time of the Main L/R output." cmd:"release"` Release MainCompReleaseCmd `cmd:"" help:"Get or set the compressor release time of the Main L/R output."`
} }
// MainCompOnCmd defines the command for getting or setting the compressor on/off state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MainCompOnCmd defines the command for getting or setting the compressor on/off state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off".

View File

@@ -7,14 +7,14 @@ import (
// MainMonoCmdGroup defines the command group for controlling the Main Mono output, including commands for mute state, fader level, and fade-in/fade-out times. // MainMonoCmdGroup defines the command group for controlling the Main Mono output, including commands for mute state, fader level, and fade-in/fade-out times.
type MainMonoCmdGroup struct { type MainMonoCmdGroup struct {
Mute MainMonoMuteCmd `help:"Get or set the mute state of the Main Mono output." cmd:""` Mute MainMonoMuteCmd `cmd:"" help:"Get or set the mute state of the Main Mono output."`
Fader MainMonoFaderCmd `help:"Get or set the fader level of the Main Mono output." cmd:""` Fader MainMonoFaderCmd `cmd:"" help:"Get or set the fader level of the Main Mono output."`
Fadein MainMonoFadeinCmd `help:"Fade in the Main Mono output over a specified duration." cmd:""` Fadein MainMonoFadeinCmd `cmd:"" help:"Fade in the Main Mono output over a specified duration."`
Fadeout MainMonoFadeoutCmd `help:"Fade out the Main Mono output over a specified duration." cmd:""` Fadeout MainMonoFadeoutCmd `cmd:"" help:"Fade out the Main Mono output over a specified duration."`
Eq MainMonoEqCmdGroup `help:"Commands for controlling the equaliser settings of the Main Mono output." cmd:"eq"` Eq MainMonoEqCmdGroup `cmd:"" help:"Commands for controlling the equaliser settings of the Main Mono output."`
Comp MainMonoCompCmdGroup `help:"Commands for controlling the compressor settings of the Main Mono output." cmd:"comp"` Comp MainMonoCompCmdGroup `cmd:"" help:"Commands for controlling the compressor settings of the Main Mono output."`
} }
// MainMonoMuteCmd defines the command for getting or setting the mute state of the Main Mono output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MainMonoMuteCmd defines the command for getting or setting the mute state of the Main Mono output, allowing users to specify the desired state as "true"/"on" or "false"/"off".
@@ -136,10 +136,10 @@ type MainMonoEqCmdGroup struct {
On MainMonoEqOnCmd `help:"Get or set the EQ on/off state of the Main Mono output." cmd:"on"` On MainMonoEqOnCmd `help:"Get or set the EQ on/off state of the Main Mono output." cmd:"on"`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain MainMonoEqBandGainCmd `help:"Get or set the gain of the specified EQ band." cmd:"gain"` Gain MainMonoEqBandGainCmd `cmd:"" help:"Get or set the gain of the specified EQ band."`
Freq MainMonoEqBandFreqCmd `help:"Get or set the frequency of the specified EQ band." cmd:"freq"` Freq MainMonoEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the specified EQ band."`
Q MainMonoEqBandQCmd `help:"Get or set the Q factor of the specified EQ band." cmd:"q"` Q MainMonoEqBandQCmd `cmd:"" help:"Get or set the Q factor of the specified EQ band."`
Type MainMonoEqBandTypeCmd `help:"Get or set the type of the specified EQ band." cmd:"type"` Type MainMonoEqBandTypeCmd `cmd:"" help:"Get or set the type of the specified EQ band."`
} `help:"Commands for controlling individual EQ bands of the Main Mono output." arg:""` } `help:"Commands for controlling individual EQ bands of the Main Mono output." arg:""`
} }
@@ -310,15 +310,15 @@ func (cmd *MainMonoEqBandTypeCmd) Run(
// MainMonoCompCmdGroup defines the command group for controlling the compressor settings of the Main Mono output, including commands for getting or setting the compressor parameters. // MainMonoCompCmdGroup defines the command group for controlling the compressor settings of the Main Mono output, including commands for getting or setting the compressor parameters.
type MainMonoCompCmdGroup struct { type MainMonoCompCmdGroup struct {
On MainMonoCompOnCmd `help:"Get or set the compressor on/off state of the Main Mono output." cmd:"on"` On MainMonoCompOnCmd `cmd:"" help:"Get or set the compressor on/off state of the Main Mono output."`
Mode MainMonoCompModeCmd `help:"Get or set the compressor mode of the Main Mono output." cmd:"mode"` Mode MainMonoCompModeCmd `cmd:"" help:"Get or set the compressor mode of the Main Mono output."`
Threshold MainMonoCompThresholdCmd `help:"Get or set the compressor threshold of the Main Mono output." cmd:"threshold"` Threshold MainMonoCompThresholdCmd `cmd:"" help:"Get or set the compressor threshold of the Main Mono output."`
Ratio MainMonoCompRatioCmd `help:"Get or set the compressor ratio of the Main Mono output." cmd:"ratio"` Ratio MainMonoCompRatioCmd `cmd:"" help:"Get or set the compressor ratio of the Main Mono output."`
Mix MainMonoCompMixCmd `help:"Get or set the compressor mix level of the Main Mono output." cmd:"mix"` Mix MainMonoCompMixCmd `cmd:"" help:"Get or set the compressor mix level of the Main Mono output."`
Makeup MainMonoCompMakeupCmd `help:"Get or set the compressor makeup gain of the Main Mono output." cmd:"makeup"` Makeup MainMonoCompMakeupCmd `cmd:"" help:"Get or set the compressor makeup gain of the Main Mono output."`
Attack MainMonoCompAttackCmd `help:"Get or set the compressor attack time of the Main Mono output." cmd:"attack"` Attack MainMonoCompAttackCmd `cmd:"" help:"Get or set the compressor attack time of the Main Mono output."`
Hold MainMonoCompHoldCmd `help:"Get or set the compressor hold time of the Main Mono output." cmd:"hold"` Hold MainMonoCompHoldCmd `cmd:"" help:"Get or set the compressor hold time of the Main Mono output."`
Release MainMonoCompReleaseCmd `help:"Get or set the compressor release time of the Main Mono output." cmd:"release"` Release MainMonoCompReleaseCmd `cmd:"" help:"Get or set the compressor release time of the Main Mono output."`
} }
// MainMonoCompOnCmd defines the command for getting or setting the compressor on/off state of the Main Mono output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MainMonoCompOnCmd defines the command for getting or setting the compressor on/off state of the Main Mono output, allowing users to specify the desired state as "true"/"on" or "false"/"off".

View File

@@ -9,15 +9,15 @@ import (
type MatrixCmdGroup struct { type MatrixCmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the Matrix output (1-6)."` Index int `arg:"" help:"The index of the Matrix output (1-6)."`
Mute MatrixMuteCmd `help:"Get or set the mute state of the Matrix output." cmd:""` Mute MatrixMuteCmd `cmd:"" help:"Get or set the mute state of the Matrix output."`
Fader MatrixFaderCmd `help:"Get or set the fader level of the Matrix output." cmd:""` Fader MatrixFaderCmd `cmd:"" help:"Get or set the fader level of the Matrix output."`
Fadein MatrixFadeinCmd `help:"Fade in the Matrix output over a specified duration." cmd:""` Fadein MatrixFadeinCmd `cmd:"" help:"Fade in the Matrix output over a specified duration."`
Fadeout MatrixFadeoutCmd `help:"Fade out the Matrix output over a specified duration." cmd:""` Fadeout MatrixFadeoutCmd `cmd:"" help:"Fade out the Matrix output over a specified duration."`
Eq MatrixEqCmdGroup `help:"Commands for controlling the equaliser settings of the Matrix output." cmd:"eq"` Eq MatrixEqCmdGroup `cmd:"" help:"Commands for controlling the equaliser settings of the Matrix output."`
Comp MatrixCompCmdGroup `help:"Commands for controlling the compressor settings of the Matrix output." cmd:"comp"` Comp MatrixCompCmdGroup `cmd:"" help:"Commands for controlling the compressor settings of the Matrix output."`
} `help:"Commands for controlling individual Matrix outputs." arg:""` } `arg:"" help:"Commands for controlling individual Matrix outputs."`
} }
func (cmd *MatrixCmdGroup) Validate() error { func (cmd *MatrixCmdGroup) Validate() error {
@@ -143,14 +143,14 @@ func (cmd *MatrixFadeoutCmd) Run(ctx *context, matrix *MatrixCmdGroup) error {
// MatrixEqCmdGroup defines the command group for controlling the equaliser settings of the Matrix output, including commands for getting or setting the EQ parameters. // MatrixEqCmdGroup defines the command group for controlling the equaliser settings of the Matrix output, including commands for getting or setting the EQ parameters.
type MatrixEqCmdGroup struct { type MatrixEqCmdGroup struct {
On MatrixEqOnCmd `help:"Get or set the EQ on/off state of the Matrix output." cmd:"on"` On MatrixEqOnCmd `cmd:"" help:"Get or set the EQ on/off state of the Matrix output."`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain MatrixEqBandGainCmd `help:"Get or set the gain of the specified EQ band." cmd:"gain"` Gain MatrixEqBandGainCmd `cmd:"" help:"Get or set the gain of the specified EQ band."`
Freq MatrixEqBandFreqCmd `help:"Get or set the frequency of the specified EQ band." cmd:"freq"` Freq MatrixEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the specified EQ band."`
Q MatrixEqBandQCmd `help:"Get or set the Q factor of the specified EQ band." cmd:"q"` Q MatrixEqBandQCmd `cmd:"" help:"Get or set the Q factor of the specified EQ band."`
Type MatrixEqBandTypeCmd `help:"Get or set the type of the specified EQ band." cmd:"type"` Type MatrixEqBandTypeCmd `cmd:"" help:"Get or set the type of the specified EQ band."`
} `help:"Commands for controlling individual EQ bands of the Matrix output." arg:""` } ` help:"Commands for controlling individual EQ bands of the Matrix output." arg:""`
} }
// Validate checks if the provided EQ band number is within the valid range (1-6) for the Matrix output. // Validate checks if the provided EQ band number is within the valid range (1-6) for the Matrix output.
@@ -332,15 +332,15 @@ func (cmd *MatrixEqBandTypeCmd) Run(
// MatrixCompCmdGroup defines the command group for controlling the compressor settings of the Matrix output, including commands for getting or setting the compressor parameters. // MatrixCompCmdGroup defines the command group for controlling the compressor settings of the Matrix output, including commands for getting or setting the compressor parameters.
type MatrixCompCmdGroup struct { type MatrixCompCmdGroup struct {
On MatrixCompOnCmd `help:"Get or set the compressor on/off state of the Matrix output." cmd:"on"` On MatrixCompOnCmd `cmd:"" help:"Get or set the compressor on/off state of the Matrix output."`
Mode MatrixCompModeCmd `help:"Get or set the compressor mode of the Matrix output." cmd:"mode"` Mode MatrixCompModeCmd `cmd:"" help:"Get or set the compressor mode of the Matrix output."`
Threshold MatrixCompThresholdCmd `help:"Get or set the compressor threshold of the Matrix output." cmd:"threshold"` Threshold MatrixCompThresholdCmd `cmd:"" help:"Get or set the compressor threshold of the Matrix output."`
Ratio MatrixCompRatioCmd `help:"Get or set the compressor ratio of the Matrix output." cmd:"ratio"` Ratio MatrixCompRatioCmd `cmd:"" help:"Get or set the compressor ratio of the Matrix output."`
Mix MatrixCompMixCmd `help:"Get or set the compressor mix level of the Matrix output." cmd:"mix"` Mix MatrixCompMixCmd `cmd:"" help:"Get or set the compressor mix level of the Matrix output."`
Makeup MatrixCompMakeupCmd `help:"Get or set the compressor makeup gain of the Matrix output." cmd:"makeup"` Makeup MatrixCompMakeupCmd `cmd:"" help:"Get or set the compressor makeup gain of the Matrix output."`
Attack MatrixCompAttackCmd `help:"Get or set the compressor attack time of the Matrix output." cmd:"attack"` Attack MatrixCompAttackCmd `cmd:"" help:"Get or set the compressor attack time of the Matrix output."`
Hold MatrixCompHoldCmd `help:"Get or set the compressor hold time of the Matrix output." cmd:"hold"` Hold MatrixCompHoldCmd `cmd:"" help:"Get or set the compressor hold time of the Matrix output."`
Release MatrixCompReleaseCmd `help:"Get or set the compressor release time of the Matrix output." cmd:"release"` Release MatrixCompReleaseCmd `cmd:"" help:"Get or set the compressor release time of the Matrix output."`
} }
// MatrixCompOnCmd defines the command for getting or setting the compressor on/off state of the Matrix output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MatrixCompOnCmd defines the command for getting or setting the compressor on/off state of the Matrix output, allowing users to specify the desired state as "true"/"on" or "false"/"off".

View File

@@ -8,8 +8,8 @@ import (
// RawCmd represents the command to send raw OSC messages to the mixer. // RawCmd represents the command to send raw OSC messages to the mixer.
type RawCmd struct { type RawCmd struct {
Address string `help:"The OSC address to send the message to." arg:""` Address string `arg:"" help:"The OSC address to send the message to."`
Args []string `help:"The arguments to include in the OSC message." arg:"" optional:""` Args []string `arg:"" help:"The arguments to include in the OSC message." optional:""`
} }
// Run executes the RawCmd by sending the specified OSC message to the mixer and optionally waiting for a response. // Run executes the RawCmd by sending the specified OSC message to the mixer and optionally waiting for a response.

View File

@@ -3,14 +3,14 @@ package main
import "fmt" import "fmt"
type SnapshotCmdGroup struct { type SnapshotCmdGroup struct {
List ListCmd `help:"List all snapshots." cmd:"list"` List ListCmd `cmd:"" help:"List all snapshots."`
Index struct { Index struct {
Index *int `arg:"" help:"The index of the snapshot." optional:""` Index *int `arg:"" help:"The index of the snapshot." optional:""`
Name NameCmd `help:"Get or set the name of a snapshot." cmd:"name"` Name NameCmd `cmd:"" help:"Get or set the name of a snapshot."`
Save SaveCmd `help:"Save the current mixer state to a snapshot." cmd:"save"` Save SaveCmd `cmd:"" help:"Save the current mixer state to a snapshot."`
Load LoadCmd `help:"Load a mixer state from a snapshot." cmd:"load"` Load LoadCmd `cmd:"" help:"Load a mixer state from a snapshot."`
Delete DeleteCmd `help:"Delete a snapshot." cmd:"delete"` Delete DeleteCmd `cmd:"" help:"Delete a snapshot."`
} `help:"The index of the snapshot." arg:""` } ` help:"The index of the snapshot." arg:""`
} }
// Validate checks if the provided snapshot index is within the valid range (1-64) when any of the subcommands that require an index are used. // Validate checks if the provided snapshot index is within the valid range (1-64) when any of the subcommands that require an index are used.

View File

@@ -9,16 +9,16 @@ import (
type StripCmdGroup struct { type StripCmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the strip. (1-based indexing)"` Index int `arg:"" help:"The index of the strip. (1-based indexing)"`
Mute StripMuteCmd ` help:"Get or set the mute state of the strip." cmd:""` Mute StripMuteCmd `cmd:"" help:"Get or set the mute state of the strip." `
Fader StripFaderCmd ` help:"Get or set the fader level of the strip." cmd:""` Fader StripFaderCmd `cmd:"" help:"Get or set the fader level of the strip."`
Fadein StripFadeinCmd ` help:"Fade in the strip over a specified duration." cmd:""` Fadein StripFadeinCmd `cmd:"" help:"Fade in the strip over a specified duration."`
Fadeout StripFadeoutCmd ` help:"Fade out the strip over a specified duration." cmd:""` Fadeout StripFadeoutCmd `cmd:"" help:"Fade out the strip over a specified duration."`
Send StripSendCmd ` help:"Get or set the send level for a specific bus." cmd:""` Send StripSendCmd `cmd:"" help:"Get or set the send level for a specific bus."`
Name StripNameCmd ` help:"Get or set the name of the strip." cmd:""` Name StripNameCmd `cmd:"" help:"Get or set the name of the strip."`
Gate StripGateCmdGroup ` help:"Commands related to the strip gate." cmd:"gate"` Gate StripGateCmdGroup `cmd:"" help:"Commands related to the strip gate."`
Eq StripEqCmdGroup ` help:"Commands related to the strip EQ." cmd:"eq"` Eq StripEqCmdGroup `cmd:"" help:"Commands related to the strip EQ."`
Comp StripCompCmdGroup ` help:"Commands related to the strip compressor." cmd:"comp"` Comp StripCompCmdGroup `cmd:"" help:"Commands related to the strip compressor."`
} `arg:"" help:"Control a specific strip by index."` } `arg:"" help:"Control a specific strip by index."`
} }
@@ -217,13 +217,13 @@ func (cmd *StripNameCmd) Run(ctx *context, strip *StripCmdGroup) error {
// StripGateCmdGroup defines the command group for controlling the gate settings of a strip, including commands for getting and setting the gate on/off state, mode, threshold, range, attack time, hold time, and release time. // StripGateCmdGroup defines the command group for controlling the gate settings of a strip, including commands for getting and setting the gate on/off state, mode, threshold, range, attack time, hold time, and release time.
type StripGateCmdGroup struct { type StripGateCmdGroup struct {
On StripGateOnCmd `help:"Get or set the gate on/off state of the strip." cmd:""` On StripGateOnCmd `cmd:"" help:"Get or set the gate on/off state of the strip."`
Mode StripGateModeCmd `help:"Get or set the gate mode of the strip." cmd:""` Mode StripGateModeCmd `cmd:"" help:"Get or set the gate mode of the strip."`
Threshold StripGateThresholdCmd `help:"Get or set the gate threshold of the strip." cmd:""` Threshold StripGateThresholdCmd `cmd:"" help:"Get or set the gate threshold of the strip."`
Range StripGateRangeCmd `help:"Get or set the gate range of the strip." cmd:""` Range StripGateRangeCmd `cmd:"" help:"Get or set the gate range of the strip."`
Attack StripGateAttackCmd `help:"Get or set the gate attack time of the strip." cmd:""` Attack StripGateAttackCmd `cmd:"" help:"Get or set the gate attack time of the strip."`
Hold StripGateHoldCmd `help:"Get or set the gate hold time of the strip." cmd:""` Hold StripGateHoldCmd `cmd:"" help:"Get or set the gate hold time of the strip."`
Release StripGateReleaseCmd `help:"Get or set the gate release time of the strip." cmd:""` Release StripGateReleaseCmd `cmd:"" help:"Get or set the gate release time of the strip."`
} }
// StripGateOnCmd defines the command for getting or setting the gate on/off state of a strip, allowing users to enable or disable the gate effect on the strip. // StripGateOnCmd defines the command for getting or setting the gate on/off state of a strip, allowing users to enable or disable the gate effect on the strip.
@@ -404,14 +404,14 @@ func (cmd *StripGateReleaseCmd) Run(ctx *context, strip *StripCmdGroup) error {
// StripEqCmdGroup defines the command group for controlling the EQ settings of a strip, including commands for getting and setting the EQ on/off state and parameters for each EQ band such as gain, frequency, Q factor, and type. // StripEqCmdGroup defines the command group for controlling the EQ settings of a strip, including commands for getting and setting the EQ on/off state and parameters for each EQ band such as gain, frequency, Q factor, and type.
type StripEqCmdGroup struct { type StripEqCmdGroup struct {
On StripEqOnCmd `help:"Get or set the EQ on/off state of the strip." cmd:""` On StripEqOnCmd `cmd:"" help:"Get or set the EQ on/off state of the strip."`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain StripEqBandGainCmd `help:"Get or set the gain of the EQ band." cmd:""` Gain StripEqBandGainCmd `cmd:"" help:"Get or set the gain of the EQ band."`
Freq StripEqBandFreqCmd `help:"Get or set the frequency of the EQ band." cmd:""` Freq StripEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the EQ band."`
Q StripEqBandQCmd `help:"Get or set the Q factor of the EQ band." cmd:""` Q StripEqBandQCmd `cmd:"" help:"Get or set the Q factor of the EQ band."`
Type StripEqBandTypeCmd `help:"Get or set the type of the EQ band." cmd:""` Type StripEqBandTypeCmd `cmd:"" help:"Get or set the type of the EQ band."`
} `help:"Commands for controlling a specific EQ band of the strip." arg:""` } ` help:"Commands for controlling a specific EQ band of the strip." arg:""`
} }
// Validate checks if the provided EQ band number is valid (between 1 and 4) and returns an error if it is not. // Validate checks if the provided EQ band number is valid (between 1 and 4) and returns an error if it is not.
@@ -619,15 +619,15 @@ func (cmd *StripEqBandTypeCmd) Run(
// StripCompCmdGroup defines the command group for controlling the compressor settings of a strip, including commands for getting and setting the compressor on/off state, mode, threshold, ratio, mix, makeup gain, attack time, hold time, and release time. // StripCompCmdGroup defines the command group for controlling the compressor settings of a strip, including commands for getting and setting the compressor on/off state, mode, threshold, ratio, mix, makeup gain, attack time, hold time, and release time.
type StripCompCmdGroup struct { type StripCompCmdGroup struct {
On StripCompOnCmd `help:"Get or set the compressor on/off state of the strip." cmd:""` On StripCompOnCmd `cmd:"" help:"Get or set the compressor on/off state of the strip."`
Mode StripCompModeCmd `help:"Get or set the compressor mode of the strip." cmd:""` Mode StripCompModeCmd `cmd:"" help:"Get or set the compressor mode of the strip."`
Threshold StripCompThresholdCmd `help:"Get or set the compressor threshold of the strip." cmd:""` Threshold StripCompThresholdCmd `cmd:"" help:"Get or set the compressor threshold of the strip."`
Ratio StripCompRatioCmd `help:"Get or set the compressor ratio of the strip." cmd:""` Ratio StripCompRatioCmd `cmd:"" help:"Get or set the compressor ratio of the strip."`
Mix StripCompMixCmd `help:"Get or set the compressor mix of the strip." cmd:""` Mix StripCompMixCmd `cmd:"" help:"Get or set the compressor mix of the strip."`
Makeup StripCompMakeupCmd `help:"Get or set the compressor makeup gain of the strip." cmd:""` Makeup StripCompMakeupCmd `cmd:"" help:"Get or set the compressor makeup gain of the strip."`
Attack StripCompAttackCmd `help:"Get or set the compressor attack time of the strip." cmd:""` Attack StripCompAttackCmd `cmd:"" help:"Get or set the compressor attack time of the strip."`
Hold StripCompHoldCmd `help:"Get or set the compressor hold time of the strip." cmd:""` Hold StripCompHoldCmd `cmd:"" help:"Get or set the compressor hold time of the strip."`
Release StripCompReleaseCmd `help:"Get or set the compressor release time of the strip." cmd:""` Release StripCompReleaseCmd `cmd:"" help:"Get or set the compressor release time of the strip."`
} }
// StripCompOnCmd defines the command for getting or setting the compressor on/off state of a strip, allowing users to enable or disable the compressor effect on the strip. // StripCompOnCmd defines the command for getting or setting the compressor on/off state of a strip, allowing users to enable or disable the compressor effect on the strip.

View File

@@ -9,14 +9,14 @@ import (
type BusCmdGroup struct { type BusCmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the bus. (1-based indexing)"` Index int `arg:"" help:"The index of the bus. (1-based indexing)"`
Mute BusMuteCmd ` help:"Get or set the mute state of the bus." cmd:""` Mute BusMuteCmd `cmd:"" help:"Get or set the mute state of the bus."`
Fader BusFaderCmd ` help:"Get or set the fader level of the bus." cmd:""` Fader BusFaderCmd `cmd:"" help:"Get or set the fader level of the bus."`
Fadein BusFadeinCmd ` help:"Fade in the bus over a specified duration." cmd:""` Fadein BusFadeinCmd `cmd:"" help:"Fade in the bus over a specified duration."`
Fadeout BusFadeoutCmd ` help:"Fade out the bus over a specified duration." cmd:""` Fadeout BusFadeoutCmd `cmd:"" help:"Fade out the bus over a specified duration."`
Name BusNameCmd ` help:"Get or set the name of the bus." cmd:""` Name BusNameCmd `cmd:"" help:"Get or set the name of the bus."`
Eq BusEqCmdGroup ` help:"Commands related to the bus EQ." cmd:"eq"` Eq BusEqCmdGroup `cmd:"" help:"Commands related to the bus EQ."`
Comp BusCompCmdGroup ` help:"Commands related to the bus compressor." cmd:"comp"` Comp BusCompCmdGroup `cmd:"" help:"Commands related to the bus compressor."`
} `arg:"" help:"Control a specific bus by index."` } `arg:"" help:"Control a specific bus by index."`
} }
@@ -179,15 +179,15 @@ func (cmd *BusNameCmd) Run(ctx *context, bus *BusCmdGroup) error {
// BusEqCmdGroup defines the commands related to controlling the EQ of a bus. // BusEqCmdGroup defines the commands related to controlling the EQ of a bus.
type BusEqCmdGroup struct { type BusEqCmdGroup struct {
On BusEqOnCmd `help:"Get or set the EQ on/off state of the bus." cmd:"on"` On BusEqOnCmd `cmd:"" help:"Get or set the EQ on/off state of the bus."`
Mode BusEqModeCmd `help:"Get or set the EQ mode of the bus (peq, geq or teq)." cmd:"mode"` Mode BusEqModeCmd `cmd:"" help:"Get or set the EQ mode of the bus (peq, geq or teq)."`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain BusEqBandGainCmd `help:"Get or set the gain of the EQ band." cmd:"gain"` Gain BusEqBandGainCmd `cmd:"" help:"Get or set the gain of the EQ band."`
Freq BusEqBandFreqCmd `help:"Get or set the frequency of the EQ band." cmd:"freq"` Freq BusEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the EQ band."`
Q BusEqBandQCmd `help:"Get or set the Q factor of the EQ band." cmd:"q"` Q BusEqBandQCmd `cmd:"" help:"Get or set the Q factor of the EQ band."`
Type BusEqBandTypeCmd `help:"Get or set the type of the EQ band (lcut, lshv, peq, veq, hshv, hcut)." cmd:"type"` Type BusEqBandTypeCmd `cmd:"" help:"Get or set the type of the EQ band (lcut, lshv, peq, veq, hshv, hcut)."`
} `help:"Commands for controlling a specific EQ band of the bus." arg:""` } ` help:"Commands for controlling a specific EQ band of the bus." arg:""`
} }
// Validate checks that the provided EQ band number is within the valid range (1-6). // Validate checks that the provided EQ band number is within the valid range (1-6).
@@ -394,15 +394,15 @@ func (cmd *BusEqBandTypeCmd) Run(ctx *context, bus *BusCmdGroup, busEq *BusEqCmd
// BusCompCmdGroup defines the commands related to controlling the compressor of a bus. // BusCompCmdGroup defines the commands related to controlling the compressor of a bus.
type BusCompCmdGroup struct { type BusCompCmdGroup struct {
On BusCompOnCmd `help:"Get or set the compressor on/off state of the bus." cmd:"on"` On BusCompOnCmd `cmd:"" help:"Get or set the compressor on/off state of the bus."`
Mode BusCompModeCmd `help:"Get or set the compressor mode of the bus (comp, exp)." cmd:"mode"` Mode BusCompModeCmd `cmd:"" help:"Get or set the compressor mode of the bus (comp, exp)."`
Threshold BusCompThresholdCmd `help:"Get or set the compressor threshold of the bus (in dB)." cmd:"threshold"` Threshold BusCompThresholdCmd `cmd:"" help:"Get or set the compressor threshold of the bus (in dB)."`
Ratio BusCompRatioCmd `help:"Get or set the compressor ratio of the bus." cmd:"ratio"` Ratio BusCompRatioCmd `cmd:"" help:"Get or set the compressor ratio of the bus."`
Mix BusCompMixCmd `help:"Get or set the compressor mix level of the bus (in %)." cmd:"mix"` Mix BusCompMixCmd `cmd:"" help:"Get or set the compressor mix level of the bus (in %)."`
Makeup BusCompMakeupCmd `help:"Get or set the compressor makeup gain of the bus (in dB)." cmd:"makeup"` Makeup BusCompMakeupCmd `cmd:"" help:"Get or set the compressor makeup gain of the bus (in dB)."`
Attack BusCompAttackCmd `help:"Get or set the compressor attack time of the bus (in ms)." cmd:"attack"` Attack BusCompAttackCmd `cmd:"" help:"Get or set the compressor attack time of the bus (in ms)."`
Hold BusCompHoldCmd `help:"Get or set the compressor hold time of the bus (in ms)." cmd:"hold"` Hold BusCompHoldCmd `cmd:"" help:"Get or set the compressor hold time of the bus (in ms)."`
Release BusCompReleaseCmd `help:"Get or set the compressor release time of the bus (in ms)." cmd:"release"` Release BusCompReleaseCmd `cmd:"" help:"Get or set the compressor release time of the bus (in ms)."`
} }
// BusCompOnCmd defines the command for getting or setting the compressor on/off state of a bus. // BusCompOnCmd defines the command for getting or setting the compressor on/off state of a bus.

View File

@@ -9,6 +9,7 @@ import (
"time" "time"
"github.com/alecthomas/kong" "github.com/alecthomas/kong"
mangokong "github.com/alecthomas/mango-kong"
"github.com/charmbracelet/log" "github.com/charmbracelet/log"
kongcompletion "github.com/jotaen/kong-completion" kongcompletion "github.com/jotaen/kong-completion"
@@ -39,10 +40,10 @@ type context struct {
} }
type Config struct { type Config struct {
Host string `default:"mixer.local" help:"The host of the X-Air device." env:"XAIR_CLI_HOST" short:"H"` Host string `flag:"" default:"mixer.local" help:"The host of the X-Air device." env:"XAIR_CLI_HOST" short:"H"`
Port int `default:"10024" help:"The port of the X-Air device." env:"XAIR_CLI_PORT" short:"P"` Port int `flag:"" default:"10024" help:"The port of the X-Air device." env:"XAIR_CLI_PORT" short:"P"`
Timeout time.Duration `default:"100ms" help:"Timeout for OSC operations." env:"XAIR_CLI_TIMEOUT" short:"T"` Timeout time.Duration `flag:"" default:"100ms" help:"Timeout for OSC operations." env:"XAIR_CLI_TIMEOUT" short:"T"`
Loglevel string `default:"warn" help:"Log level for the CLI." env:"XAIR_CLI_LOGLEVEL" short:"L" enum:"debug,info,warn,error,fatal"` Loglevel string `flag:"" default:"warn" help:"Log level for the CLI." env:"XAIR_CLI_LOGLEVEL" short:"L" enum:"debug,info,warn,error,fatal"`
} }
// CLI is the main struct for the command-line interface. // CLI is the main struct for the command-line interface.
@@ -50,18 +51,19 @@ type Config struct {
type CLI struct { type CLI struct {
Config `embed:"" prefix:"" help:"The configuration for the CLI."` Config `embed:"" prefix:"" help:"The configuration for the CLI."`
Version VersionFlag `help:"Print xair-cli version information and quit" name:"version" short:"v"` Man mangokong.ManFlag `help:"Print man page."`
Version VersionFlag `help:"Print xair-cli version information and quit" name:"version" short:"v"`
Completion kongcompletion.Completion `help:"Generate shell completion scripts." cmd:""` Completion kongcompletion.Completion `cmd:"" help:"Generate shell completion scripts."`
Info InfoCmd `help:"Print mixer information." cmd:""` Info InfoCmd `cmd:"" help:"Print mixer information."`
Raw RawCmd `help:"Send raw OSC messages to the mixer." cmd:""` Raw RawCmd `cmd:"" help:"Send raw OSC messages to the mixer."`
Main MainCmdGroup `help:"Control the Main L/R output" cmd:"" group:"Main"` Main MainCmdGroup `cmd:"" help:"Control the Main L/R output" group:"Main"`
Strip StripCmdGroup `help:"Control the strips." cmd:"" group:"Strip"` Strip StripCmdGroup `cmd:"" help:"Control the strips." group:"Strip"`
Bus BusCmdGroup `help:"Control the buses." cmd:"" group:"Bus"` Bus BusCmdGroup `cmd:"" help:"Control the buses." group:"Bus"`
Headamp HeadampCmdGroup `help:"Control input gain and phantom power." cmd:"" group:"Headamp"` Headamp HeadampCmdGroup `cmd:"" help:"Control input gain and phantom power." group:"Headamp"`
Snapshot SnapshotCmdGroup `help:"Save and load mixer states." cmd:"" group:"Snapshot"` Snapshot SnapshotCmdGroup `cmd:"" help:"Save and load mixer states." group:"Snapshot"`
Dca DCACmdGroup `help:"Control DCA groups." cmd:"" group:"DCA"` Dca DCACmdGroup `cmd:"" help:"Control DCA groups." group:"DCA"`
} }
func main() { func main() {

View File

@@ -8,8 +8,8 @@ import (
type DCACmdGroup struct { type DCACmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the DCA group (1-4)."` Index int `arg:"" help:"The index of the DCA group (1-4)."`
Mute DCAMuteCmd `help:"Get or set the mute status of the DCA group." cmd:""` Mute DCAMuteCmd `cmd:"" help:"Get or set the mute status of the DCA group."`
Name DCANameCmd `help:"Get or set the name of the DCA group." cmd:""` Name DCANameCmd `cmd:"" help:"Get or set the name of the DCA group."`
} `arg:"" help:"Control a specific DCA group by its index."` } `arg:"" help:"Control a specific DCA group by its index."`
} }

View File

@@ -11,15 +11,15 @@ import (
type HeadampCmdGroup struct { type HeadampCmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the headamp."` Index int `arg:"" help:"The index of the headamp."`
Gain HeadampGainCmd `help:"Get or set the gain of the headamp." cmd:""` Gain HeadampGainCmd `cmd:"" help:"Get or set the gain of the headamp."`
Phantom HeadampPhantomCmd `help:"Get or set the phantom power state of the headamp." cmd:""` Phantom HeadampPhantomCmd `cmd:"" help:"Get or set the phantom power state of the headamp."`
} `arg:"" help:"Control a specific headamp by index."` } `arg:"" help:"Control a specific headamp by index."`
} }
// HeadampGainCmd defines the command for getting or setting the gain of a headamp, allowing users to specify the gain in dB and an optional duration for a gradual fade when setting the gain. // HeadampGainCmd defines the command for getting or setting the gain of a headamp, allowing users to specify the gain in dB and an optional duration for a gradual fade when setting the gain.
type HeadampGainCmd struct { type HeadampGainCmd struct {
Duration time.Duration `help:"The duration of the fade in/out when setting the gain." default:"5s"` Duration time.Duration `flag:"" help:"The duration of the fade in/out when setting the gain." default:"5s"`
Gain *float64 `help:"The gain of the headamp in dB." arg:"" optional:""` Gain *float64 ` help:"The gain of the headamp in dB." arg:"" optional:""`
} }
// Run executes the HeadampGainCmd command, either retrieving the current gain of the headamp or setting it based on the provided argument, with an optional fade duration for smooth transitions. // Run executes the HeadampGainCmd command, either retrieving the current gain of the headamp or setting it based on the provided argument, with an optional fade duration for smooth transitions.
@@ -99,7 +99,7 @@ func gradualGainAdjust(
// HeadampPhantomCmd defines the command for getting or setting the phantom power state of a headamp, allowing users to specify the desired state as "true"/"on" or "false"/"off". // HeadampPhantomCmd defines the command for getting or setting the phantom power state of a headamp, allowing users to specify the desired state as "true"/"on" or "false"/"off".
type HeadampPhantomCmd struct { type HeadampPhantomCmd struct {
State *string `help:"The phantom power state of the headamp." arg:"" enum:"true,on,false,off" optional:""` State *string `arg:"" help:"The phantom power state of the headamp." enum:"true,on,false,off" optional:""`
} }
// Validate checks if the provided phantom power state is valid and normalises it to "true" or "false". // Validate checks if the provided phantom power state is valid and normalises it to "true" or "false".

View File

@@ -8,14 +8,14 @@ import (
// MainCmdGroup defines the command group for controlling the Main L/R output, including commands for mute state, fader level, and fade-in/fade-out times. // MainCmdGroup defines the command group for controlling the Main L/R output, including commands for mute state, fader level, and fade-in/fade-out times.
type MainCmdGroup struct { type MainCmdGroup struct {
Mute MainMuteCmd `help:"Get or set the mute state of the Main L/R output." cmd:""` Mute MainMuteCmd `cmd:"" help:"Get or set the mute state of the Main L/R output."`
Fader MainFaderCmd `help:"Get or set the fader level of the Main L/R output." cmd:""` Fader MainFaderCmd `cmd:"" help:"Get or set the fader level of the Main L/R output."`
Fadein MainFadeinCmd `help:"Fade in the Main L/R output over a specified duration." cmd:""` Fadein MainFadeinCmd `cmd:"" help:"Fade in the Main L/R output over a specified duration."`
Fadeout MainFadeoutCmd `help:"Fade out the Main L/R output over a specified duration." cmd:""` Fadeout MainFadeoutCmd `cmd:"" help:"Fade out the Main L/R output over a specified duration."`
Eq MainEqCmdGroup `help:"Commands for controlling the equaliser settings of the Main L/R output." cmd:"eq"` Eq MainEqCmdGroup `cmd:"" help:"Commands for controlling the equaliser settings of the Main L/R output."`
Comp MainCompCmdGroup `help:"Commands for controlling the compressor settings of the Main L/R output." cmd:"comp"` Comp MainCompCmdGroup `cmd:"" help:"Commands for controlling the compressor settings of the Main L/R output."`
} }
// MainMuteCmd defines the command for getting or setting the mute state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MainMuteCmd defines the command for getting or setting the mute state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off".
@@ -134,14 +134,14 @@ func (cmd *MainFadeoutCmd) Run(ctx *context) error {
// MainEqCmdGroup defines the command group for controlling the equaliser settings of the Main L/R output, including commands for getting or setting the EQ parameters. // MainEqCmdGroup defines the command group for controlling the equaliser settings of the Main L/R output, including commands for getting or setting the EQ parameters.
type MainEqCmdGroup struct { type MainEqCmdGroup struct {
On MainEqOnCmd `help:"Get or set the EQ on/off state of the Main L/R output." cmd:"on"` On MainEqOnCmd `cmd:"" help:"Get or set the EQ on/off state of the Main L/R output."`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain MainEqBandGainCmd `help:"Get or set the gain of the specified EQ band." cmd:"gain"` Gain MainEqBandGainCmd `cmd:"" help:"Get or set the gain of the specified EQ band."`
Freq MainEqBandFreqCmd `help:"Get or set the frequency of the specified EQ band." cmd:"freq"` Freq MainEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the specified EQ band."`
Q MainEqBandQCmd `help:"Get or set the Q factor of the specified EQ band." cmd:"q"` Q MainEqBandQCmd `cmd:"" help:"Get or set the Q factor of the specified EQ band."`
Type MainEqBandTypeCmd `help:"Get or set the type of the specified EQ band." cmd:"type"` Type MainEqBandTypeCmd `cmd:"" help:"Get or set the type of the specified EQ band."`
} `help:"Commands for controlling individual EQ bands of the Main L/R output." arg:""` } ` help:"Commands for controlling individual EQ bands of the Main L/R output." arg:""`
} }
// Validate checks if the provided EQ band number is within the valid range (1-6) for the Main L/R output. // Validate checks if the provided EQ band number is within the valid range (1-6) for the Main L/R output.
@@ -291,15 +291,15 @@ func (cmd *MainEqBandTypeCmd) Run(ctx *context, mainEq *MainEqCmdGroup) error {
// MainCompCmdGroup defines the command group for controlling the compressor settings of the Main L/R output, including commands for getting or setting the compressor parameters. // MainCompCmdGroup defines the command group for controlling the compressor settings of the Main L/R output, including commands for getting or setting the compressor parameters.
type MainCompCmdGroup struct { type MainCompCmdGroup struct {
On MainCompOnCmd `help:"Get or set the compressor on/off state of the Main L/R output." cmd:"on"` On MainCompOnCmd `cmd:"on" help:"Get or set the compressor on/off state of the Main L/R output."`
Mode MainCompModeCmd `help:"Get or set the compressor mode of the Main L/R output." cmd:"mode"` Mode MainCompModeCmd `cmd:"mode" help:"Get or set the compressor mode of the Main L/R output."`
Threshold MainCompThresholdCmd `help:"Get or set the compressor threshold of the Main L/R output." cmd:"threshold"` Threshold MainCompThresholdCmd `cmd:"threshold" help:"Get or set the compressor threshold of the Main L/R output."`
Ratio MainCompRatioCmd `help:"Get or set the compressor ratio of the Main L/R output." cmd:"ratio"` Ratio MainCompRatioCmd `cmd:"ratio" help:"Get or set the compressor ratio of the Main L/R output."`
Mix MainCompMixCmd `help:"Get or set the compressor mix level of the Main L/R output." cmd:"mix"` Mix MainCompMixCmd `cmd:"mix" help:"Get or set the compressor mix level of the Main L/R output."`
Makeup MainCompMakeupCmd `help:"Get or set the compressor makeup gain of the Main L/R output." cmd:"makeup"` Makeup MainCompMakeupCmd `cmd:"makeup" help:"Get or set the compressor makeup gain of the Main L/R output."`
Attack MainCompAttackCmd `help:"Get or set the compressor attack time of the Main L/R output." cmd:"attack"` Attack MainCompAttackCmd `cmd:"attack" help:"Get or set the compressor attack time of the Main L/R output."`
Hold MainCompHoldCmd `help:"Get or set the compressor hold time of the Main L/R output." cmd:"hold"` Hold MainCompHoldCmd `cmd:"hold" help:"Get or set the compressor hold time of the Main L/R output."`
Release MainCompReleaseCmd `help:"Get or set the compressor release time of the Main L/R output." cmd:"release"` Release MainCompReleaseCmd `cmd:"release" help:"Get or set the compressor release time of the Main L/R output."`
} }
// MainCompOnCmd defines the command for getting or setting the compressor on/off state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off". // MainCompOnCmd defines the command for getting or setting the compressor on/off state of the Main L/R output, allowing users to specify the desired state as "true"/"on" or "false"/"off".

View File

@@ -8,8 +8,8 @@ import (
// RawCmd represents the command to send raw OSC messages to the mixer. // RawCmd represents the command to send raw OSC messages to the mixer.
type RawCmd struct { type RawCmd struct {
Address string `help:"The OSC address to send the message to." arg:""` Address string `arg:"" help:"The OSC address to send the message to."`
Args []string `help:"The arguments to include in the OSC message." arg:"" optional:""` Args []string `arg:"" help:"The arguments to include in the OSC message." optional:""`
} }
// Run executes the RawCmd by sending the specified OSC message to the mixer and optionally waiting for a response. // Run executes the RawCmd by sending the specified OSC message to the mixer and optionally waiting for a response.

View File

@@ -3,14 +3,14 @@ package main
import "fmt" import "fmt"
type SnapshotCmdGroup struct { type SnapshotCmdGroup struct {
List ListCmd `help:"List all snapshots." cmd:"list"` List ListCmd `cmd:"" help:"List all snapshots."`
Index struct { Index struct {
Index *int `arg:"" help:"The index of the snapshot." optional:""` Index *int `arg:"" help:"The index of the snapshot." optional:""`
Name NameCmd `help:"Get or set the name of a snapshot." cmd:"name"` Name NameCmd `cmd:"" help:"Get or set the name of a snapshot."`
Save SaveCmd `help:"Save the current mixer state to a snapshot." cmd:"save"` Save SaveCmd `cmd:"" help:"Save the current mixer state to a snapshot."`
Load LoadCmd `help:"Load a mixer state from a snapshot." cmd:"load"` Load LoadCmd `cmd:"" help:"Load a mixer state from a snapshot."`
Delete DeleteCmd `help:"Delete a snapshot." cmd:"delete"` Delete DeleteCmd `cmd:"" help:"Delete a snapshot."`
} `help:"The index of the snapshot." arg:""` } ` help:"The index of the snapshot." arg:""`
} }
// Validate checks if the provided snapshot index is within the valid range (1-64) when any of the subcommands that require an index are used. // Validate checks if the provided snapshot index is within the valid range (1-64) when any of the subcommands that require an index are used.

View File

@@ -9,16 +9,16 @@ import (
type StripCmdGroup struct { type StripCmdGroup struct {
Index struct { Index struct {
Index int `arg:"" help:"The index of the strip. (1-based indexing)"` Index int `arg:"" help:"The index of the strip. (1-based indexing)"`
Mute StripMuteCmd ` help:"Get or set the mute state of the strip." cmd:""` Mute StripMuteCmd `cmd:"" help:"Get or set the mute state of the strip."`
Fader StripFaderCmd ` help:"Get or set the fader level of the strip." cmd:""` Fader StripFaderCmd `cmd:"" help:"Get or set the fader level of the strip."`
Fadein StripFadeinCmd ` help:"Fade in the strip over a specified duration." cmd:""` Fadein StripFadeinCmd `cmd:"" help:"Fade in the strip over a specified duration."`
Fadeout StripFadeoutCmd ` help:"Fade out the strip over a specified duration." cmd:""` Fadeout StripFadeoutCmd `cmd:"" help:"Fade out the strip over a specified duration."`
Send StripSendCmd ` help:"Get or set the send level for a specific bus." cmd:""` Send StripSendCmd `cmd:"" help:"Get or set the send level for a specific bus."`
Name StripNameCmd ` help:"Get or set the name of the strip." cmd:""` Name StripNameCmd `cmd:"" help:"Get or set the name of the strip."`
Gate StripGateCmdGroup ` help:"Commands related to the strip gate." cmd:"gate"` Gate StripGateCmdGroup `cmd:"gate" help:"Commands related to the strip gate."`
Eq StripEqCmdGroup ` help:"Commands related to the strip EQ." cmd:"eq"` Eq StripEqCmdGroup `cmd:"eq" help:"Commands related to the strip EQ."`
Comp StripCompCmdGroup ` help:"Commands related to the strip compressor." cmd:"comp"` Comp StripCompCmdGroup `cmd:"comp" help:"Commands related to the strip compressor."`
} `arg:"" help:"Control a specific strip by index."` } `arg:"" help:"Control a specific strip by index."`
} }
@@ -217,13 +217,13 @@ func (cmd *StripNameCmd) Run(ctx *context, strip *StripCmdGroup) error {
// StripGateCmdGroup defines the command group for controlling the gate settings of a strip, including commands for getting and setting the gate on/off state, mode, threshold, range, attack time, hold time, and release time. // StripGateCmdGroup defines the command group for controlling the gate settings of a strip, including commands for getting and setting the gate on/off state, mode, threshold, range, attack time, hold time, and release time.
type StripGateCmdGroup struct { type StripGateCmdGroup struct {
On StripGateOnCmd `help:"Get or set the gate on/off state of the strip." cmd:""` On StripGateOnCmd `cmd:"" help:"Get or set the gate on/off state of the strip."`
Mode StripGateModeCmd `help:"Get or set the gate mode of the strip." cmd:""` Mode StripGateModeCmd `cmd:"" help:"Get or set the gate mode of the strip."`
Threshold StripGateThresholdCmd `help:"Get or set the gate threshold of the strip." cmd:""` Threshold StripGateThresholdCmd `cmd:"" help:"Get or set the gate threshold of the strip."`
Range StripGateRangeCmd `help:"Get or set the gate range of the strip." cmd:""` Range StripGateRangeCmd `cmd:"" help:"Get or set the gate range of the strip."`
Attack StripGateAttackCmd `help:"Get or set the gate attack time of the strip." cmd:""` Attack StripGateAttackCmd `cmd:"" help:"Get or set the gate attack time of the strip."`
Hold StripGateHoldCmd `help:"Get or set the gate hold time of the strip." cmd:""` Hold StripGateHoldCmd `cmd:"" help:"Get or set the gate hold time of the strip."`
Release StripGateReleaseCmd `help:"Get or set the gate release time of the strip." cmd:""` Release StripGateReleaseCmd `cmd:"" help:"Get or set the gate release time of the strip."`
} }
// StripGateOnCmd defines the command for getting or setting the gate on/off state of a strip, allowing users to enable or disable the gate effect on the strip. // StripGateOnCmd defines the command for getting or setting the gate on/off state of a strip, allowing users to enable or disable the gate effect on the strip.
@@ -404,14 +404,14 @@ func (cmd *StripGateReleaseCmd) Run(ctx *context, strip *StripCmdGroup) error {
// StripEqCmdGroup defines the command group for controlling the EQ settings of a strip, including commands for getting and setting the EQ on/off state and parameters for each EQ band such as gain, frequency, Q factor, and type. // StripEqCmdGroup defines the command group for controlling the EQ settings of a strip, including commands for getting and setting the EQ on/off state and parameters for each EQ band such as gain, frequency, Q factor, and type.
type StripEqCmdGroup struct { type StripEqCmdGroup struct {
On StripEqOnCmd `help:"Get or set the EQ on/off state of the strip." cmd:""` On StripEqOnCmd `cmd:"" help:"Get or set the EQ on/off state of the strip."`
Band struct { Band struct {
Band *int `arg:"" help:"The EQ band number." optional:""` Band *int `arg:"" help:"The EQ band number." optional:""`
Gain StripEqBandGainCmd `help:"Get or set the gain of the EQ band." cmd:""` Gain StripEqBandGainCmd `cmd:"" help:"Get or set the gain of the EQ band."`
Freq StripEqBandFreqCmd `help:"Get or set the frequency of the EQ band." cmd:""` Freq StripEqBandFreqCmd `cmd:"" help:"Get or set the frequency of the EQ band."`
Q StripEqBandQCmd `help:"Get or set the Q factor of the EQ band." cmd:""` Q StripEqBandQCmd `cmd:"" help:"Get or set the Q factor of the EQ band."`
Type StripEqBandTypeCmd `help:"Get or set the type of the EQ band." cmd:""` Type StripEqBandTypeCmd `cmd:"" help:"Get or set the type of the EQ band."`
} `help:"Commands for controlling a specific EQ band of the strip." arg:""` } ` help:"Commands for controlling a specific EQ band of the strip." arg:""`
} }
// Validate checks if the provided EQ band number is valid (between 1 and 4) and returns an error if it is not. // Validate checks if the provided EQ band number is valid (between 1 and 4) and returns an error if it is not.
@@ -619,15 +619,15 @@ func (cmd *StripEqBandTypeCmd) Run(
// StripCompCmdGroup defines the command group for controlling the compressor settings of a strip, including commands for getting and setting the compressor on/off state, mode, threshold, ratio, mix, makeup gain, attack time, hold time, and release time. // StripCompCmdGroup defines the command group for controlling the compressor settings of a strip, including commands for getting and setting the compressor on/off state, mode, threshold, ratio, mix, makeup gain, attack time, hold time, and release time.
type StripCompCmdGroup struct { type StripCompCmdGroup struct {
On StripCompOnCmd `help:"Get or set the compressor on/off state of the strip." cmd:""` On StripCompOnCmd `cmd:"" help:"Get or set the compressor on/off state of the strip."`
Mode StripCompModeCmd `help:"Get or set the compressor mode of the strip." cmd:""` Mode StripCompModeCmd `cmd:"" help:"Get or set the compressor mode of the strip."`
Threshold StripCompThresholdCmd `help:"Get or set the compressor threshold of the strip." cmd:""` Threshold StripCompThresholdCmd `cmd:"" help:"Get or set the compressor threshold of the strip."`
Ratio StripCompRatioCmd `help:"Get or set the compressor ratio of the strip." cmd:""` Ratio StripCompRatioCmd `cmd:"" help:"Get or set the compressor ratio of the strip."`
Mix StripCompMixCmd `help:"Get or set the compressor mix of the strip." cmd:""` Mix StripCompMixCmd `cmd:"" help:"Get or set the compressor mix of the strip."`
Makeup StripCompMakeupCmd `help:"Get or set the compressor makeup gain of the strip." cmd:""` Makeup StripCompMakeupCmd `cmd:"" help:"Get or set the compressor makeup gain of the strip."`
Attack StripCompAttackCmd `help:"Get or set the compressor attack time of the strip." cmd:""` Attack StripCompAttackCmd `cmd:"" help:"Get or set the compressor attack time of the strip."`
Hold StripCompHoldCmd `help:"Get or set the compressor hold time of the strip." cmd:""` Hold StripCompHoldCmd `cmd:"" help:"Get or set the compressor hold time of the strip."`
Release StripCompReleaseCmd `help:"Get or set the compressor release time of the strip." cmd:""` Release StripCompReleaseCmd `cmd:"" help:"Get or set the compressor release time of the strip."`
} }
// StripCompOnCmd defines the command for getting or setting the compressor on/off state of a strip, allowing users to enable or disable the compressor effect on the strip. // StripCompOnCmd defines the command for getting or setting the compressor on/off state of a strip, allowing users to enable or disable the compressor effect on the strip.

17
go.mod
View File

@@ -3,10 +3,11 @@ module github.com/onyx-and-iris/xair-cli
go 1.25.0 go 1.25.0
require ( require (
github.com/alecthomas/kong v1.14.0 github.com/alecthomas/kong v1.15.0
github.com/alecthomas/mango-kong v0.1.0
github.com/charmbracelet/log v1.0.0 github.com/charmbracelet/log v1.0.0
github.com/hypebeast/go-osc v0.0.0-20220308234300-cec5a8a1e5f5 github.com/hypebeast/go-osc v0.0.0-20220308234300-cec5a8a1e5f5
github.com/jotaen/kong-completion v0.0.12 github.com/jotaen/kong-completion v0.0.13
) )
require ( require (
@@ -21,14 +22,16 @@ require (
github.com/go-logfmt/logfmt v0.6.1 // indirect github.com/go-logfmt/logfmt v0.6.1 // indirect
github.com/hashicorp/errwrap v1.1.0 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/lucasb-eyer/go-colorful v1.3.0 // indirect github.com/lucasb-eyer/go-colorful v1.4.0 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect github.com/mattn/go-isatty v0.0.21 // indirect
github.com/mattn/go-runewidth v0.0.21 // indirect github.com/mattn/go-runewidth v0.0.23 // indirect
github.com/muesli/mango v0.2.0 // indirect
github.com/muesli/roff v0.1.0 // indirect
github.com/muesli/termenv v0.16.0 // indirect github.com/muesli/termenv v0.16.0 // indirect
github.com/posener/complete v1.2.3 // indirect github.com/posener/complete v1.2.3 // indirect
github.com/rivo/uniseg v0.4.7 // indirect github.com/rivo/uniseg v0.4.7 // indirect
github.com/riywo/loginshell v0.0.0-20200815045211-7d26008be1ab // indirect github.com/riywo/loginshell v0.0.0-20200815045211-7d26008be1ab // indirect
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
golang.org/x/exp v0.0.0-20260312153236-7ab1446f8b90 // indirect golang.org/x/exp v0.0.0-20260410095643-746e56fc9e2f // indirect
golang.org/x/sys v0.42.0 // indirect golang.org/x/sys v0.43.0 // indirect
) )

35
go.sum
View File

@@ -1,7 +1,9 @@
github.com/alecthomas/assert/v2 v2.11.0 h1:2Q9r3ki8+JYXvGsDyBXwH3LcJ+WK5D0gc5E8vS6K3D0= github.com/alecthomas/assert/v2 v2.11.0 h1:2Q9r3ki8+JYXvGsDyBXwH3LcJ+WK5D0gc5E8vS6K3D0=
github.com/alecthomas/assert/v2 v2.11.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k= github.com/alecthomas/assert/v2 v2.11.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k=
github.com/alecthomas/kong v1.14.0 h1:gFgEUZWu2ZmZ+UhyZ1bDhuutbKN1nTtJTwh19Wsn21s= github.com/alecthomas/kong v1.15.0 h1:BVJstKbpO73zKpmIu+m/aLRrNmWwxXPIGTNin9VmLVI=
github.com/alecthomas/kong v1.14.0/go.mod h1:wrlbXem1CWqUV5Vbmss5ISYhsVPkBb1Yo7YKJghju2I= github.com/alecthomas/kong v1.15.0/go.mod h1:wrlbXem1CWqUV5Vbmss5ISYhsVPkBb1Yo7YKJghju2I=
github.com/alecthomas/mango-kong v0.1.0 h1:iFVfP1k1K4qpml3JUQmD5I8MCQYfIvsD9mRdrw7jJC4=
github.com/alecthomas/mango-kong v0.1.0/go.mod h1:t+TYVdsONUolf/BwVcm+15eqcdAj15h4Qe9MMFAwwT4=
github.com/alecthomas/repr v0.5.2 h1:SU73FTI9D1P5UNtvseffFSGmdNci/O6RsqzeXJtP0Qs= github.com/alecthomas/repr v0.5.2 h1:SU73FTI9D1P5UNtvseffFSGmdNci/O6RsqzeXJtP0Qs=
github.com/alecthomas/repr v0.5.2/go.mod h1:Fr0507jx4eOXV7AlPV6AVZLYrLIuIeSOWtW57eE/O/4= github.com/alecthomas/repr v0.5.2/go.mod h1:Fr0507jx4eOXV7AlPV6AVZLYrLIuIeSOWtW57eE/O/4=
github.com/aymanbagabas/go-osc52/v2 v2.0.1 h1:HwpRHbFMcZLEVr42D4p7XBqjyuxQH5SMiErDT4WkJ2k= github.com/aymanbagabas/go-osc52/v2 v2.0.1 h1:HwpRHbFMcZLEVr42D4p7XBqjyuxQH5SMiErDT4WkJ2k=
@@ -39,14 +41,18 @@ github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUq
github.com/hexops/gotextdiff v1.0.3/go.mod h1:pSWU5MAI3yDq+fZBTazCSJysOMbxWL1BSow5/V2vxeg= github.com/hexops/gotextdiff v1.0.3/go.mod h1:pSWU5MAI3yDq+fZBTazCSJysOMbxWL1BSow5/V2vxeg=
github.com/hypebeast/go-osc v0.0.0-20220308234300-cec5a8a1e5f5 h1:fqwINudmUrvGCuw+e3tedZ2UJ0hklSw6t8UPomctKyQ= github.com/hypebeast/go-osc v0.0.0-20220308234300-cec5a8a1e5f5 h1:fqwINudmUrvGCuw+e3tedZ2UJ0hklSw6t8UPomctKyQ=
github.com/hypebeast/go-osc v0.0.0-20220308234300-cec5a8a1e5f5/go.mod h1:lqMjoCs0y0GoRRujSPZRBaGb4c5ER6TfkFKSClxkMbY= github.com/hypebeast/go-osc v0.0.0-20220308234300-cec5a8a1e5f5/go.mod h1:lqMjoCs0y0GoRRujSPZRBaGb4c5ER6TfkFKSClxkMbY=
github.com/jotaen/kong-completion v0.0.12 h1:a9jmSaWgkdAUMQT583UxLIJrO9tfdSmYqcIxrBByjPc= github.com/jotaen/kong-completion v0.0.13 h1:fbbqijMmrCgx8sz6bZz+B5p5yJSEAdwJZALsUZ+Ql3s=
github.com/jotaen/kong-completion v0.0.12/go.mod h1:dyIG20e3qq128SUBtF8jzI7YtkfzjWMlgbqkAJd6xHQ= github.com/jotaen/kong-completion v0.0.13/go.mod h1:dyIG20e3qq128SUBtF8jzI7YtkfzjWMlgbqkAJd6xHQ=
github.com/lucasb-eyer/go-colorful v1.3.0 h1:2/yBRLdWBZKrf7gB40FoiKfAWYQ0lqNcbuQwVHXptag= github.com/lucasb-eyer/go-colorful v1.4.0 h1:UtrWVfLdarDgc44HcS7pYloGHJUjHV/4FwW4TvVgFr4=
github.com/lucasb-eyer/go-colorful v1.3.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= github.com/lucasb-eyer/go-colorful v1.4.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0=
github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.21 h1:xYae+lCNBP7QuW4PUnNG61ffM4hVIfm+zUzDuSzYLGs=
github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-isatty v0.0.21/go.mod h1:ZXfXG4SQHsB/w3ZeOYbR0PrPwLy+n6xiMrJlRFqopa4=
github.com/mattn/go-runewidth v0.0.21 h1:jJKAZiQH+2mIinzCJIaIG9Be1+0NR+5sz/lYEEjdM8w= github.com/mattn/go-runewidth v0.0.23 h1:7ykA0T0jkPpzSvMS5i9uoNn2Xy3R383f9HDx3RybWcw=
github.com/mattn/go-runewidth v0.0.21/go.mod h1:XBkDxAl56ILZc9knddidhrOlY5R/pDhgLpndooCuJAs= github.com/mattn/go-runewidth v0.0.23/go.mod h1:XBkDxAl56ILZc9knddidhrOlY5R/pDhgLpndooCuJAs=
github.com/muesli/mango v0.2.0 h1:iNNc0c5VLQ6fsMgAqGQofByNUBH2Q2nEbD6TaI+5yyQ=
github.com/muesli/mango v0.2.0/go.mod h1:5XFpbC8jY5UUv89YQciiXNlbi+iJgt29VDC5xbzrLL4=
github.com/muesli/roff v0.1.0 h1:YD0lalCotmYuF5HhZliKWlIx7IEhiXeSfq7hNjFqGF8=
github.com/muesli/roff v0.1.0/go.mod h1:pjAHQM9hdUUwm/krAfrLGgJkXJ+YuhtsfZ42kieB2Ig=
github.com/muesli/termenv v0.16.0 h1:S5AlUN9dENB57rsbnkPyfdGuWIlkmzJjbFf0Tf5FWUc= github.com/muesli/termenv v0.16.0 h1:S5AlUN9dENB57rsbnkPyfdGuWIlkmzJjbFf0Tf5FWUc=
github.com/muesli/termenv v0.16.0/go.mod h1:ZRfOIKPFDYQoDFF4Olj7/QJbW60Ol/kL1pU3VfY/Cnk= github.com/muesli/termenv v0.16.0/go.mod h1:ZRfOIKPFDYQoDFF4Olj7/QJbW60Ol/kL1pU3VfY/Cnk=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
@@ -63,11 +69,10 @@ github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu
github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U=
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e h1:JVG44RsyaB9T2KIHavMF/ppJZNG9ZpyihvCd0w101no= github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e h1:JVG44RsyaB9T2KIHavMF/ppJZNG9ZpyihvCd0w101no=
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e/go.mod h1:RbqR21r5mrJuqunuUZ/Dhy/avygyECGrLceyNeo4LiM= github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e/go.mod h1:RbqR21r5mrJuqunuUZ/Dhy/avygyECGrLceyNeo4LiM=
golang.org/x/exp v0.0.0-20260312153236-7ab1446f8b90 h1:jiDhWWeC7jfWqR9c/uplMOqJ0sbNlNWv0UkzE0vX1MA= golang.org/x/exp v0.0.0-20260410095643-746e56fc9e2f h1:W3F4c+6OLc6H2lb//N1q4WpJkhzJCK5J6kUi1NTVXfM=
golang.org/x/exp v0.0.0-20260312153236-7ab1446f8b90/go.mod h1:xE1HEv6b+1SCZ5/uscMRjUBKtIxworgEcEi+/n9NQDQ= golang.org/x/exp v0.0.0-20260410095643-746e56fc9e2f/go.mod h1:J1xhfL/vlindoeF/aINzNzt2Bket5bjo9sdOYzOsU80=
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.43.0 h1:Rlag2XtaFTxp19wS8MXlJwTvoh8ArU6ezoyFsMyCTNI=
golang.org/x/sys v0.42.0 h1:omrd2nAlyT5ESRdCLYdm3+fMfNFE/+Rf4bDIQImRJeo= golang.org/x/sys v0.43.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw=
golang.org/x/sys v0.42.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=

37
tools/generate_help.go Normal file
View File

@@ -0,0 +1,37 @@
//go:generate go run generate_help.go
package main
import (
"log"
"os"
"os/exec"
)
func main() {
clis := []struct {
cmd string
out string
}{
{"./cmd/xair-cli/", "xair-help.md"},
{"./cmd/x32-cli/", "x32-help.md"},
}
for _, cli := range clis {
cmdArgs := []string{"run", cli.cmd, "--help"}
helpCmd := exec.Command("go", cmdArgs...)
helpCmd.Dir = ".."
out, err := helpCmd.Output()
if err != nil {
log.Fatal(err)
}
// Wrap output in markdown console code block
wrapped := append([]byte("```console\n"), out...)
wrapped = append(wrapped, []byte("\n```\n")...)
if err := os.WriteFile(cli.out, wrapped, 0o644); err != nil {
log.Fatal(err)
}
}
}

View File

@@ -9,6 +9,7 @@ Flags:
-P, --port=10023 The port of the X32 device ($X32_CLI_PORT). -P, --port=10023 The port of the X32 device ($X32_CLI_PORT).
-T, --timeout=100ms Timeout for OSC operations ($X32_CLI_TIMEOUT). -T, --timeout=100ms Timeout for OSC operations ($X32_CLI_TIMEOUT).
-L, --loglevel="warn" Log level for the CLI ($X32_CLI_LOGLEVEL). -L, --loglevel="warn" Log level for the CLI ($X32_CLI_LOGLEVEL).
--man Print man page.
-v, --version Print x32-cli version information and quit -v, --version Print x32-cli version information and quit
Commands: Commands:
@@ -26,90 +27,55 @@ Main
main eq <band> freq Get or set the frequency of the specified EQ band. main eq <band> freq Get or set the frequency of the specified EQ band.
main eq <band> q Get or set the Q factor of the specified EQ band. main eq <band> q Get or set the Q factor of the specified EQ band.
main eq <band> type Get or set the type of the specified EQ band. main eq <band> type Get or set the type of the specified EQ band.
main comp on Get or set the compressor on/off state of the Main L/R main comp on Get or set the compressor on/off state of the Main L/R output.
output.
main comp mode Get or set the compressor mode of the Main L/R output. main comp mode Get or set the compressor mode of the Main L/R output.
main comp threshold Get or set the compressor threshold of the Main L/R main comp threshold Get or set the compressor threshold of the Main L/R output.
output.
main comp ratio Get or set the compressor ratio of the Main L/R output. main comp ratio Get or set the compressor ratio of the Main L/R output.
main comp mix Get or set the compressor mix level of the Main L/R main comp mix Get or set the compressor mix level of the Main L/R output.
output. main comp makeup Get or set the compressor makeup gain of the Main L/R output.
main comp makeup Get or set the compressor makeup gain of the Main L/R main comp attack Get or set the compressor attack time of the Main L/R output.
output. main comp hold Get or set the compressor hold time of the Main L/R output.
main comp attack Get or set the compressor attack time of the Main L/R main comp release Get or set the compressor release time of the Main L/R output.
output.
main comp hold Get or set the compressor hold time of the Main L/R
output.
main comp release Get or set the compressor release time of the Main L/R
output.
MainMono MainMono
mainmono mute Get or set the mute state of the Main Mono output. mainmono mute Get or set the mute state of the Main Mono output.
mainmono fader Get or set the fader level of the Main Mono output. mainmono fader Get or set the fader level of the Main Mono output.
mainmono fadein Fade in the Main Mono output over a specified mainmono fadein Fade in the Main Mono output over a specified duration.
duration. mainmono fadeout Fade out the Main Mono output over a specified duration.
mainmono fadeout Fade out the Main Mono output over a specified mainmono eq on Get or set the EQ on/off state of the Main Mono output.
duration.
mainmono eq on Get or set the EQ on/off state of the Main Mono
output.
mainmono eq <band> gain Get or set the gain of the specified EQ band. mainmono eq <band> gain Get or set the gain of the specified EQ band.
mainmono eq <band> freq Get or set the frequency of the specified EQ band. mainmono eq <band> freq Get or set the frequency of the specified EQ band.
mainmono eq <band> q Get or set the Q factor of the specified EQ band. mainmono eq <band> q Get or set the Q factor of the specified EQ band.
mainmono eq <band> type Get or set the type of the specified EQ band. mainmono eq <band> type Get or set the type of the specified EQ band.
mainmono comp on Get or set the compressor on/off state of the Main mainmono comp on Get or set the compressor on/off state of the Main Mono output.
Mono output. mainmono comp mode Get or set the compressor mode of the Main Mono output.
mainmono comp mode Get or set the compressor mode of the Main Mono mainmono comp threshold Get or set the compressor threshold of the Main Mono output.
output. mainmono comp ratio Get or set the compressor ratio of the Main Mono output.
mainmono comp threshold Get or set the compressor threshold of the Main mainmono comp mix Get or set the compressor mix level of the Main Mono output.
Mono output. mainmono comp makeup Get or set the compressor makeup gain of the Main Mono output.
mainmono comp ratio Get or set the compressor ratio of the Main Mono mainmono comp attack Get or set the compressor attack time of the Main Mono output.
output. mainmono comp hold Get or set the compressor hold time of the Main Mono output.
mainmono comp mix Get or set the compressor mix level of the Main mainmono comp release Get or set the compressor release time of the Main Mono output.
Mono output.
mainmono comp makeup Get or set the compressor makeup gain of the Main
Mono output.
mainmono comp attack Get or set the compressor attack time of the Main
Mono output.
mainmono comp hold Get or set the compressor hold time of the Main
Mono output.
mainmono comp release Get or set the compressor release time of the Main
Mono output.
Matrix Matrix
matrix <index> mute Get or set the mute state of the Matrix matrix <index> mute Get or set the mute state of the Matrix output.
output. matrix <index> fader Get or set the fader level of the Matrix output.
matrix <index> fader Get or set the fader level of the Matrix matrix <index> fadein Fade in the Matrix output over a specified duration.
output. matrix <index> fadeout Fade out the Matrix output over a specified duration.
matrix <index> fadein Fade in the Matrix output over a specified matrix <index> eq on Get or set the EQ on/off state of the Matrix output.
duration.
matrix <index> fadeout Fade out the Matrix output over a specified
duration.
matrix <index> eq on Get or set the EQ on/off state of the Matrix
output.
matrix <index> eq <band> gain Get or set the gain of the specified EQ band. matrix <index> eq <band> gain Get or set the gain of the specified EQ band.
matrix <index> eq <band> freq Get or set the frequency of the specified EQ matrix <index> eq <band> freq Get or set the frequency of the specified EQ band.
band. matrix <index> eq <band> q Get or set the Q factor of the specified EQ band.
matrix <index> eq <band> q Get or set the Q factor of the specified EQ
band.
matrix <index> eq <band> type Get or set the type of the specified EQ band. matrix <index> eq <band> type Get or set the type of the specified EQ band.
matrix <index> comp on Get or set the compressor on/off state of the matrix <index> comp on Get or set the compressor on/off state of the Matrix output.
Matrix output. matrix <index> comp mode Get or set the compressor mode of the Matrix output.
matrix <index> comp mode Get or set the compressor mode of the Matrix matrix <index> comp threshold Get or set the compressor threshold of the Matrix output.
output. matrix <index> comp ratio Get or set the compressor ratio of the Matrix output.
matrix <index> comp threshold Get or set the compressor threshold of the matrix <index> comp mix Get or set the compressor mix level of the Matrix output.
Matrix output. matrix <index> comp makeup Get or set the compressor makeup gain of the Matrix output.
matrix <index> comp ratio Get or set the compressor ratio of the Matrix matrix <index> comp attack Get or set the compressor attack time of the Matrix output.
output. matrix <index> comp hold Get or set the compressor hold time of the Matrix output.
matrix <index> comp mix Get or set the compressor mix level of the matrix <index> comp release Get or set the compressor release time of the Matrix output.
Matrix output.
matrix <index> comp makeup Get or set the compressor makeup gain of the
Matrix output.
matrix <index> comp attack Get or set the compressor attack time of the
Matrix output.
matrix <index> comp hold Get or set the compressor hold time of the
Matrix output.
matrix <index> comp release Get or set the compressor release time of the
Matrix output.
Strip Strip
strip <index> mute Get or set the mute state of the strip. strip <index> mute Get or set the mute state of the strip.
@@ -130,21 +96,15 @@ Strip
strip <index> eq <band> freq Get or set the frequency of the EQ band. strip <index> eq <band> freq Get or set the frequency of the EQ band.
strip <index> eq <band> q Get or set the Q factor of the EQ band. strip <index> eq <band> q Get or set the Q factor of the EQ band.
strip <index> eq <band> type Get or set the type of the EQ band. strip <index> eq <band> type Get or set the type of the EQ band.
strip <index> comp on Get or set the compressor on/off state of the strip <index> comp on Get or set the compressor on/off state of the strip.
strip.
strip <index> comp mode Get or set the compressor mode of the strip. strip <index> comp mode Get or set the compressor mode of the strip.
strip <index> comp threshold Get or set the compressor threshold of the strip <index> comp threshold Get or set the compressor threshold of the strip.
strip.
strip <index> comp ratio Get or set the compressor ratio of the strip. strip <index> comp ratio Get or set the compressor ratio of the strip.
strip <index> comp mix Get or set the compressor mix of the strip. strip <index> comp mix Get or set the compressor mix of the strip.
strip <index> comp makeup Get or set the compressor makeup gain of the strip <index> comp makeup Get or set the compressor makeup gain of the strip.
strip. strip <index> comp attack Get or set the compressor attack time of the strip.
strip <index> comp attack Get or set the compressor attack time of the strip <index> comp hold Get or set the compressor hold time of the strip.
strip. strip <index> comp release Get or set the compressor release time of the strip.
strip <index> comp hold Get or set the compressor hold time of the
strip.
strip <index> comp release Get or set the compressor release time of the
strip.
Bus Bus
bus <index> mute Get or set the mute state of the bus. bus <index> mute Get or set the mute state of the bus.
@@ -153,30 +113,20 @@ Bus
bus <index> fadeout Fade out the bus over a specified duration. bus <index> fadeout Fade out the bus over a specified duration.
bus <index> name Get or set the name of the bus. bus <index> name Get or set the name of the bus.
bus <index> eq on Get or set the EQ on/off state of the bus. bus <index> eq on Get or set the EQ on/off state of the bus.
bus <index> eq mode Get or set the EQ mode of the bus (peq, geq or bus <index> eq mode Get or set the EQ mode of the bus (peq, geq or teq).
teq).
bus <index> eq <band> gain Get or set the gain of the EQ band. bus <index> eq <band> gain Get or set the gain of the EQ band.
bus <index> eq <band> freq Get or set the frequency of the EQ band. bus <index> eq <band> freq Get or set the frequency of the EQ band.
bus <index> eq <band> q Get or set the Q factor of the EQ band. bus <index> eq <band> q Get or set the Q factor of the EQ band.
bus <index> eq <band> type Get or set the type of the EQ band (lcut, lshv, bus <index> eq <band> type Get or set the type of the EQ band (lcut, lshv, peq, veq, hshv, hcut).
peq, veq, hshv, hcut). bus <index> comp on Get or set the compressor on/off state of the bus.
bus <index> comp on Get or set the compressor on/off state of the bus <index> comp mode Get or set the compressor mode of the bus (comp, exp).
bus. bus <index> comp threshold Get or set the compressor threshold of the bus (in dB).
bus <index> comp mode Get or set the compressor mode of the bus (comp,
exp).
bus <index> comp threshold Get or set the compressor threshold of the bus
(in dB).
bus <index> comp ratio Get or set the compressor ratio of the bus. bus <index> comp ratio Get or set the compressor ratio of the bus.
bus <index> comp mix Get or set the compressor mix level of the bus bus <index> comp mix Get or set the compressor mix level of the bus (in %).
(in %). bus <index> comp makeup Get or set the compressor makeup gain of the bus (in dB).
bus <index> comp makeup Get or set the compressor makeup gain of the bus bus <index> comp attack Get or set the compressor attack time of the bus (in ms).
(in dB). bus <index> comp hold Get or set the compressor hold time of the bus (in ms).
bus <index> comp attack Get or set the compressor attack time of the bus bus <index> comp release Get or set the compressor release time of the bus (in ms).
(in ms).
bus <index> comp hold Get or set the compressor hold time of the bus
(in ms).
bus <index> comp release Get or set the compressor release time of the
bus (in ms).
Headamp Headamp
headamp <index> gain Get or set the gain of the headamp. headamp <index> gain Get or set the gain of the headamp.
@@ -194,4 +144,5 @@ DCA
dca <index> name Get or set the name of the DCA group. dca <index> name Get or set the name of the DCA group.
Run "x32-cli <command> --help" for more information on a command. Run "x32-cli <command> --help" for more information on a command.
``` ```

View File

@@ -9,6 +9,7 @@ Flags:
-P, --port=10024 The port of the X-Air device ($XAIR_CLI_PORT). -P, --port=10024 The port of the X-Air device ($XAIR_CLI_PORT).
-T, --timeout=100ms Timeout for OSC operations ($XAIR_CLI_TIMEOUT). -T, --timeout=100ms Timeout for OSC operations ($XAIR_CLI_TIMEOUT).
-L, --loglevel="warn" Log level for the CLI ($XAIR_CLI_LOGLEVEL). -L, --loglevel="warn" Log level for the CLI ($XAIR_CLI_LOGLEVEL).
--man Print man page.
-v, --version Print xair-cli version information and quit -v, --version Print xair-cli version information and quit
Commands: Commands:
@@ -26,22 +27,15 @@ Main
main eq <band> freq Get or set the frequency of the specified EQ band. main eq <band> freq Get or set the frequency of the specified EQ band.
main eq <band> q Get or set the Q factor of the specified EQ band. main eq <band> q Get or set the Q factor of the specified EQ band.
main eq <band> type Get or set the type of the specified EQ band. main eq <band> type Get or set the type of the specified EQ band.
main comp on Get or set the compressor on/off state of the Main L/R main comp on Get or set the compressor on/off state of the Main L/R output.
output.
main comp mode Get or set the compressor mode of the Main L/R output. main comp mode Get or set the compressor mode of the Main L/R output.
main comp threshold Get or set the compressor threshold of the Main L/R main comp threshold Get or set the compressor threshold of the Main L/R output.
output.
main comp ratio Get or set the compressor ratio of the Main L/R output. main comp ratio Get or set the compressor ratio of the Main L/R output.
main comp mix Get or set the compressor mix level of the Main L/R main comp mix Get or set the compressor mix level of the Main L/R output.
output. main comp makeup Get or set the compressor makeup gain of the Main L/R output.
main comp makeup Get or set the compressor makeup gain of the Main L/R main comp attack Get or set the compressor attack time of the Main L/R output.
output. main comp hold Get or set the compressor hold time of the Main L/R output.
main comp attack Get or set the compressor attack time of the Main L/R main comp release Get or set the compressor release time of the Main L/R output.
output.
main comp hold Get or set the compressor hold time of the Main L/R
output.
main comp release Get or set the compressor release time of the Main L/R
output.
Strip Strip
strip <index> mute Get or set the mute state of the strip. strip <index> mute Get or set the mute state of the strip.
@@ -62,21 +56,15 @@ Strip
strip <index> eq <band> freq Get or set the frequency of the EQ band. strip <index> eq <band> freq Get or set the frequency of the EQ band.
strip <index> eq <band> q Get or set the Q factor of the EQ band. strip <index> eq <band> q Get or set the Q factor of the EQ band.
strip <index> eq <band> type Get or set the type of the EQ band. strip <index> eq <band> type Get or set the type of the EQ band.
strip <index> comp on Get or set the compressor on/off state of the strip <index> comp on Get or set the compressor on/off state of the strip.
strip.
strip <index> comp mode Get or set the compressor mode of the strip. strip <index> comp mode Get or set the compressor mode of the strip.
strip <index> comp threshold Get or set the compressor threshold of the strip <index> comp threshold Get or set the compressor threshold of the strip.
strip.
strip <index> comp ratio Get or set the compressor ratio of the strip. strip <index> comp ratio Get or set the compressor ratio of the strip.
strip <index> comp mix Get or set the compressor mix of the strip. strip <index> comp mix Get or set the compressor mix of the strip.
strip <index> comp makeup Get or set the compressor makeup gain of the strip <index> comp makeup Get or set the compressor makeup gain of the strip.
strip. strip <index> comp attack Get or set the compressor attack time of the strip.
strip <index> comp attack Get or set the compressor attack time of the strip <index> comp hold Get or set the compressor hold time of the strip.
strip. strip <index> comp release Get or set the compressor release time of the strip.
strip <index> comp hold Get or set the compressor hold time of the
strip.
strip <index> comp release Get or set the compressor release time of the
strip.
Bus Bus
bus <index> mute Get or set the mute state of the bus. bus <index> mute Get or set the mute state of the bus.
@@ -85,30 +73,20 @@ Bus
bus <index> fadeout Fade out the bus over a specified duration. bus <index> fadeout Fade out the bus over a specified duration.
bus <index> name Get or set the name of the bus. bus <index> name Get or set the name of the bus.
bus <index> eq on Get or set the EQ on/off state of the bus. bus <index> eq on Get or set the EQ on/off state of the bus.
bus <index> eq mode Get or set the EQ mode of the bus (peq, geq or bus <index> eq mode Get or set the EQ mode of the bus (peq, geq or teq).
teq).
bus <index> eq <band> gain Get or set the gain of the EQ band. bus <index> eq <band> gain Get or set the gain of the EQ band.
bus <index> eq <band> freq Get or set the frequency of the EQ band. bus <index> eq <band> freq Get or set the frequency of the EQ band.
bus <index> eq <band> q Get or set the Q factor of the EQ band. bus <index> eq <band> q Get or set the Q factor of the EQ band.
bus <index> eq <band> type Get or set the type of the EQ band (lcut, lshv, bus <index> eq <band> type Get or set the type of the EQ band (lcut, lshv, peq, veq, hshv, hcut).
peq, veq, hshv, hcut). bus <index> comp on Get or set the compressor on/off state of the bus.
bus <index> comp on Get or set the compressor on/off state of the bus <index> comp mode Get or set the compressor mode of the bus (comp, exp).
bus. bus <index> comp threshold Get or set the compressor threshold of the bus (in dB).
bus <index> comp mode Get or set the compressor mode of the bus (comp,
exp).
bus <index> comp threshold Get or set the compressor threshold of the bus
(in dB).
bus <index> comp ratio Get or set the compressor ratio of the bus. bus <index> comp ratio Get or set the compressor ratio of the bus.
bus <index> comp mix Get or set the compressor mix level of the bus bus <index> comp mix Get or set the compressor mix level of the bus (in %).
(in %). bus <index> comp makeup Get or set the compressor makeup gain of the bus (in dB).
bus <index> comp makeup Get or set the compressor makeup gain of the bus bus <index> comp attack Get or set the compressor attack time of the bus (in ms).
(in dB). bus <index> comp hold Get or set the compressor hold time of the bus (in ms).
bus <index> comp attack Get or set the compressor attack time of the bus bus <index> comp release Get or set the compressor release time of the bus (in ms).
(in ms).
bus <index> comp hold Get or set the compressor hold time of the bus
(in ms).
bus <index> comp release Get or set the compressor release time of the
bus (in ms).
Headamp Headamp
headamp <index> gain Get or set the gain of the headamp. headamp <index> gain Get or set the gain of the headamp.
@@ -126,4 +104,5 @@ DCA
dca <index> name Get or set the name of the DCA group. dca <index> name Get or set the name of the DCA group.
Run "xair-cli <command> --help" for more information on a command. Run "xair-cli <command> --help" for more information on a command.
``` ```