Skip to main content

COMMAND LIST

Syntax

COMMAND LIST [FILTERBY <ACLCAT category | PATTERN pattern | MODULE module>]

Module

admin

Categories

admin slow

Description

Get the list of command names. Allows for filtering by ACL category or glob pattern.

Options

FILTERBY - An optional condition used to filter the response. ACLCAT filters by the provided acl category string. PATTERN filters the response by the provided glob pattern. MODULE filters the response by the provided EchoVault module.

Examples

Get a list of all the loaded commands:

vault, err := echovault.NewEchoVault()
if err != nil {
log.Fatal(err)
}
commands, err := vault.CommandList(echovault.CommandListOptions{})

Get a list of all commands with the "fast" ACL category:

vault, err := echovault.NewEchoVault()
if err != nil {
log.Fatal(err)
}
commands, err := vault.CommandList(echovault.CommandListOptions{ACLCAT: "fast"})

Get a list of all commands which satisfy the "z*" glob pattern:

vault, err := echovault.NewEchoVault()
if err != nil {
log.Fatal(err)
}
commands, err := vault.CommandList(echovault.CommandListOptions{PATTERN: "z*"})

Get a list of all the commands in the "set" module:

vault, err := echovault.NewEchoVault()
if err != nil {
log.Fatal(err)
}
commands, err := vault.CommandList(echovault.CommandListOptions{MODULE: "set"})