Skip to content

visbot/webvsc-cli

Repository files navigation

@visbot/webvsc-cli

License Version Build

Description

CLI tool to batch-convert Winamp AVS presets into native Webvs JSON format.

Installation

Use your preferred NodeJS package manager to install the CLI globally

$ npm install --global @visbot/webvsc-cli

To use the tool without installation, you can use the npx command:

$ npx @visbot/webvsc-cli

Usage

CLI

Once setup, you can run webvsc --help to list available options:

Usage: webvsc [options] [command]

Options:
  -h, --help                          display help for command

Commands:
  convert [options] <file...>         convert presets to JSON format, supports glob patterns
  info [options] <file...>            show info about AVS presets, supports glob patterns
  diff [options] <preset1> <preset2>  approximates similarity between two AVS presets
  help [command]                      display help for command

Refer to the help for each sub-command to list its options.

convert

Converts presets to Webvs JSON format

Example:

$ webvsc convert ./Plugins/avs/**/*.avs

info

Show list of effects and assets used by a preset

Example:

$ webvsc info example.avs
$ webvsc info ./Plugins/avs/**/*.avs --summary

diff

Approximates the difference between two presets

Example:

$ webvsc diff -mld preset1.avs preset2.avs

⚠️ This command requires additional flags to be set, see webvsc diff --help for details.

Troubleshooting

When trying to convert a large number of files, you might run into an EMFILE error. This is a well-documented issue that occurs whenever the number of maximum open files exceeds its limit. In such a case, you can use the following as workaround.

Linux/macOS

$ for dir in avs/*; do echo $dir; webvsc convert "$dir/**/*.avs" --quiet; done

Windows

$ Get-ChildItem -Path .\avs\ -Recurse | ForEach-Object { webvsc convert $_.FullName --quiet }

License

All code is licensed under The MIT License