Modifier
Modifiers change the completion of macros and values. These can be set
- generic
["<macro>", "<value>", "<modifier>"] - specific
["<macro> ||| <modifier> ||| <modifier>"].
The delimiter (
|||) is currently very strict and not trimmed.
chdir
$chdir(<directory>) changes the directory.
["$files", "$chdir(/tmp)"]
The following macros can be passed as well instead of a static directory:
$gitdir.git folder$gitworktreeroot of the working directory for a non-bare repository$nixprofile~/.nix-profile folder$parent(\[file, dir\])first parent directory containing any of the given names/directories$tempdirdefault directory to use for temporary files$usercachedirroot directory to use for user-specific cached data$userconfigdirdefault root directory to use for user-specific configuration data$userhomedircurrent user's home directory$xdgcachehomecache directory (fallback to UserCacheDir)$xdgconfighomehome directory (fallback to UserConfigDir)
["$files", "$chdir($gitdir)"]
filter
$filter([<value>]) filters given values.
["one", "two", "three", "$filter([two])"]
filterargs
$filterargs filters Context.Args.
["$files", "$filterargs"]
list
$list(<delimiter>) creates a list with given divider.
["one", "two", "three", "$list(,)"]
multiparts
$multiparts([<delimiter>]) completes values splitted by given delimiter(s) separately.
["one/two/three", "$multiparts([/])"]
nospace
$nospace(<characters>) disables space suffix for given character(s).
["one", "two/", "three,", "$nospace(/,)"]
prefix
$pefix(<prefix>) adds a prefix to the inserted values.
["$files", "$prefix(file://)"]
retain
$retain([<value>]) retains given values.
["one", "two", "three", "$retain([two])"]
shift
$shift(<n>) shifts positional arguments left n times.
["one", "two", "three", "$filterargs", "$shift(1)"]
split
$split splits Context.Value lexicographically and replaces Context.Args with the tokens.
["one", "two", "three", "$filterargs", "$split"]
splitp
$splitp is like Split but supports pipelines.
["one", "two", "three", "$filterargs", "$splitp"]
suffix
$suffix(<suffix>) adds a suffix to the inserted values.
["apple", "melon", "orange", "$suffix(juice)"]
suppress
$suppress(<regex>) suppresses specific error messages using a regular expression.
["$message(fail)", "$suppress(fail)"]
style
$style(<style>) sets the style for all values.
["one", "two", "three", "$style(underlined)"]
tag
$tag(<tag>) sets the tag for all values.
["one", "two", "three", "$tag(numbers)"]
uniquelist
$uniquelist(<delimiter>) creates a unique list with given divider.
["one", "two", "three", "$uniquelist(,)"]
usage
$usage(<usage>) sets the usage message.
["$usage(custom)"]