6 Commits

3 changed files with 20 additions and 5 deletions

View File

@@ -14,9 +14,18 @@ go install github.com/onyx-and-iris/xair-cli@latest
- --port/-P: Port of the mixer.
- --kind/-k: The kind of mixer. May be one of (*xair*, *x32*).
- Use this flag to connect to an x32 mixer.
- --loglevel/-L: The application's logging verbosity.
Pass `--host` and any other configuration as flags on the root commmand:
```console
xair-cli --host mixer.local --kind xair --timeout 50ms --help
```
#### Environment Variables
Or you may load them from your environment:
Example .envrc:
```bash
@@ -26,6 +35,7 @@ XAIR_CLI_HOST=mixer.local
XAIR_CLI_PORT=10024
XAIR_CLI_KIND=xair
XAIR_CLI_TIMEOUT=100ms
XAIR_CLI_LOGLEVEL=warn
```
### Use
@@ -114,8 +124,8 @@ Headamp
Snapshot
snapshot list List all snapshots.
snapshot <index> name Get or set the name of a snapshot.
snapshot <index> save Save the current mixer state.
snapshot <index> load Load a mixer state.
snapshot <index> save Save the current mixer state to a snapshot.
snapshot <index> load Load a mixer state from a snapshot.
snapshot <index> delete Delete a snapshot.
Run "xair-cli <command> --help" for more information on a command.
@@ -164,6 +174,11 @@ xair-cli raw /ch/01/config/name 'rode podmic'
xair-cli raw /ch/01/config/name
```
*Save current mixer state to a snapshot*
```console
xair-cli snapshot 20 save 'twitch live'
```
### License

View File

@@ -13,7 +13,7 @@ var x32AddressMap = map[string]string{
"mainmono": "/main/mono",
"strip": "/ch/%02d",
"bus": "/bus/%02d",
"headamp": "/headamp/%02d",
"headamp": "/headamp/%03d",
"snapshot": "/-snap",
}

View File

@@ -7,8 +7,8 @@ type SnapshotCmdGroup struct {
Index struct {
Index int `arg:"" help:"The index of the snapshot."`
Name NameCmd `help:"Get or set the name of a snapshot." cmd:"name"`
Save SaveCmd `help:"Save the current mixer state." cmd:"save"`
Load LoadCmd `help:"Load a mixer state." cmd:"load"`
Save SaveCmd `help:"Save the current mixer state to a snapshot." cmd:"save"`
Load LoadCmd `help:"Load a mixer state from a snapshot." cmd:"load"`
Delete DeleteCmd `help:"Delete a snapshot." cmd:"delete"`
} `help:"The index of the snapshot." arg:""`
}