ommand that would be executed, or prints nothing if no file with the specified name could be found in PATH. -h or --help Displays help about using this command. With the -v option, command treats every argument as a separate command to look up and sets the exit status to 0 if any of the specified commands were found, or 127 if no commands could be found. --quiet used with -v prevents commands being printed, like type -q. EXAMPLES command ls executes the ls program, even if an ls function also exists. command -s ls prints the path to the ls program. command -q git; and command git log runs git log only if git exists.`,args:"command [OPTIONS] [COMMANDNAME [ARG ...]]"},commandline:{shortDescription:"set or get the current command line buffer",description:`commandline can be used to set or get the current contents of the command line buffer. With no parameters, commandline returns the current value of the command line. With CMD specified, the command line buffer is erased and replaced with the contents of CMD. The following options are available: -C or --cursor Set or get the current cursor position, not the contents of the buffer. If no argument is given, the current cursor position is printed, otherwise the argument is interpreted as the new cursor position. If one of the options -j, -p or -t is given, the position is relative to the respective substring instead of the entire command line buffer. -B or --selection-start Get current position of the selection start in the buffer. -E or --selection-end Get current position of the selection end in the buffer. -f or --function Causes any additional arguments to be interpreted as input functions, and puts them into the queue, so that they will be read before any additional actual key presses are. This option cannot be combined with any other option. See bind for a list of input functions. -h or --help Displays help about using this command. The following options change the way commandline updates the command line buffer: -a or --append Do not remove the current commandline, append the specified string at the end of it. -i or --insert Do not remove the current commandline, insert the specified string at the current cursor position -r or --replace Remove the current commandline and replace it with the specified string (default) The following options change what part of the commandline is printed or updated: -b or --current-buffer Select the entire commandline, not including any displayed autosuggestion (default). -j or --current-job Select the current job - a job here is one pipeline. Stops at logical operators or terminators (;, &, and newlines). -p or --current-process Select the current process - a process here is one command. Stops at logical operators, terminators, and pipes. -s or --current-selection Selects the current selection -t or --current-token Selects the current token The following options change the way commandline prints the current commandline buffer: -c or --cut-at-cursor Only print selection up until the current cursor position. If combined with --tokenize, this will print up until the last completed token - excluding the token the cursor is in. This is typically what you would want for instance in completions. To get both, use both commandline --cut-at-cursor --tokenize; commandline --cut-at-cursor --current-token, or commandline -co; commandline -ct for short. -o or --tokenize Tokenize the selection and print one string-type token per line. If commandline is called during a call to complete a given string using complete -C STRING, commandline will consider the specified string to be the current contents of the command line. The following options output metadata about the commandline state: -L or --line Print the line that the cursor is on, with the topmost line starting at 1. -S or --search-mode Evaluates to true if the commandline is performing a history search. -P or --paging-mode Evaluates to true if the commandline is showing pager contents, such as tab completions. --paging-full-mode Evaluates to true if the commandline is showing pager contents, such as tab completions and all lines are shown (no " more rows" message). --is-valid Returns true when the commandline is syntactically valid and complete. If it is, it would be executed when the execute bind function is called. If the commandline is incomplete, return 2, if erroneus, return 1. EXAMPLE commandline -j $history[3] replaces the job under the cursor with the third item from the command line history. If the commandline contains > echo $flounder >&2 | less; and echo $catfish (with the cursor on the "o" of "flounder") The echo $flounder >& is the first process, less the second and and echo $catfish the third. echo $flounder >&2 | less is the first job, and echo $catfish the second. $flounder is the current token. The most common use for something like completions is set -l tokens (commandline -opc) which gives the current process (what is being completed), tokenized into separate entries, up to but excluding the currently being completed token If you are then also interested in the in-progress token, add :: set -l current (commandline -ct) Note that this makes it easy to render fish's infix matching moot - if possible it's best if the completions just print all possibilities and leave the matching to the current token up to fish's logic. More examples: > commandline -t $flounder > commandline -ct $fl > commandline -b # or just commandline echo $flounder >&2 | less; and echo $catfish > commandline -p echo $flounder >&2 > commandline -j echo $flounder >&2 | less`,args:"commandline [OPTIONS] [CMD]"},complete:{shortDescription:"edit command-specific tab-completions",description:`complete defines, removes or lists completions for a command. For an introduction to writing your own completions, see Writing your own completions in the fish manual. The following options are available: -c or --command COMMAND Specifies that COMMAND is the name of the command. If there is no -c or -p, one non-option argument will be used as the command. -p or --path COMMAND Specifies that COMMAND is the absolute path of the command (optionally containing wildcards). -e or --erase Deletes the specified completion. -s or --short-option SHORT_OPTION Adds a short option to the completions list. -l or --long-option LONG_OPTION Adds a GNU-style long option to the completions list. -o or --old-option OPTION Adds an old-style short or long option (see below for details). -a or --arguments ARGUMENTS Adds the specified option arguments to the completions list. -k or --keep-order Keeps the order of ARGUMENTS instead of sorting alphabetically. Multiple complete calls with -k result in arguments of the later ones displayed first. -f or --no-files This completion may not be followed by a filename. -F or --force-files This completion may be followed by a filename, even if another applicable complete specified --no-files. -r or --require-parameter This completion must have an option argument, i.e. may not be followed by another option. -x or --exclusive Short for -r and -f. -w or --wraps WRAPPED_COMMAND Causes the specified command to inherit completions from WRAPPED_COMMAND (see below for details). -n or --condition CONDITION This completion should only be used if the CONDITION (a shell command) returns 0. This makes it possible to specify completions that should only be used in some cases. If multiple conditions are specified, fish will try them in the order they are specified until one fails or all succeeded. -C or --do-complete STRING Makes complete try to find all possible completions for the specified string. If there is no STRING, the current commandline is used instead. --escape When used with -C, escape special characters in completions. -h or --help Displays help about using this command. Command-specific tab-completions in fish are based on the notion of options and arguments. An option is a parameter which begins with a hyphen, such as -h, -help or --help. Arguments are parameters that do not begin with a hyphen. Fish recognizes three styles of options, the same styles as the GNU getopt library. These styles are: \u2022 Short options, like -a. Short options are a single character long, are preceded by a single hyphen and can be grouped together (like -la, which is equivalent to -l -a). Option arguments may be specified by appending the option with the value (-w32), or, if --require-parameter is given, in the following parameter (-w 32). \u2022 Old-style options, long like -Wall or -name or even short like -a. Old-style options can be more than one character long, are preceded by a single hyphen and may not be grouped together. Option arguments are specified by default following a space (-foo null) or after = (-foo=null). \u2022 GNU-style long options, like --colors. GNU-style long options can be more than one character long, are preceded by two hyphens, and can't be grouped together. Option arguments may be specified after a = (--quoting-style=shell), or, if --require-parameter is given, in the following parameter (--quoting-style shell). Multiple commands and paths can be given in one call to define the same completions for multiple commands. Multiple command switches and wrapped commands can also be given to define multiple completions in one call. Invoking complete multiple times for the same command adds the new definitions on top of any existing completions defined for the command. When -a or --arguments is specified in conjunction with long, short, or old-style options, the specified arguments are only completed as arguments for any of the specified options. If -a or --arguments is specified without any long, short, or old-style options, the specified arguments are used when completing non-option arguments to the command (except when completing an option argument that was specified with -r or --require-parameter). Command substitutions found in ARGUMENTS should return a newline-separated list of arguments, and each argument may optionally have a tab character followed by the argument description. Description given this way override a description given with -d or --description. Descriptions given with --description are also used to group options given with -s, -o or -l. Options with the same (non-empty) description will be listed as one candidate, and one of them will be picked. If the description is empty or no description was given this is skipped. The -w or --wraps options causes the specified command to inherit completions from another command, "wrapping" the other command. The wrapping command can also have additional completions. A command can wrap multiple commands, and wrapping is transitive: if A wraps B, and B wraps C, then A automatically inherits all of C's completions. Wrapping can be removed using the -e or --erase options. Wrapping only works for completions specified with -c or --command and are ignored when specifying completions with -p or --path. When erasing completions, it is possible to either erase all completions for a specific command by specifying complete -c COMMAND -e, or by specifying a specific completion option to delete. When complete is called without anything that would define or erase completions (options, arguments, wrapping, ...), it shows matching completions instead. So complete without any arguments shows all loaded completions, complete -c foo shows all loaded completions for foo. Since completions are autoloaded, you will have to trigger them first. EXAMPLES The short-style option -o for the gcc command needs a file argument: complete -c gcc -s o -r The short-style option -d for the grep command requires one of read, skip or recurse: complete -c grep -s d -x -a "read skip recurse" The su command takes any username as an argument. Usernames are given as the first colon-separated field in the file /etc/passwd. This can be specified as: complete -x -c su -d "Username" -a "(cat /etc/passwd | cut -d : -f 1)" The rpm command has several different modes. If the -e or --erase flag has been specified, rpm should delete one or more packages, in which case several switches related to deleting packages are valid, like the nodeps switch. This can be written as: complete -c rpm -n "__fish_contains_opt -s e erase" -l nodeps -d "Don't check dependencies" where __fish_contains_opt is a function that checks the command line buffer for the presence of a specified set of options. To implement an alias, use the -w or --wraps option: complete -c hub -w git Now hub inherits all of the completions from git. Note this can also be specified in a function declaration (function thing -w otherthing). complete -c git Shows all completions for git. Any command foo that doesn't support grouping multiple short options in one string (not supporting -xf as short for -x -f) or a short option and its value in one string (not supporting -d9 instead of -d 9) should be specified as a single-character old-style option instead of as a short-style option; for example, complete -c foo -o s; complete -c foo -o v would never suggest foo -ov but rather foo -o -v.`,args:`complete ((-c | --command) | (-p | --path)) COMMAND [OPTIONS] complete (-C | --do-complete) [--escape] STRING`},contains:{shortDescription:"test if a word is present in a list",description:`contains tests whether the set VALUES contains the string KEY. If so, contains exits with code 0; if not, it exits with code 1. The following options are available: -i or --index Print the index (number of the element in the set) of the first matching element. -h or --help Displays help about using this command. Note that contains interprets all arguments starting with a - as an option to contains, until an -- argument is reached. See the examples below. EXAMPLE If animals is a list of animals, the following will test if animals contains "cat": if contains cat $animals echo Your animal list is evil! end This code will add some directories to PATH if they aren't yet included: for i in ~/bin /usr/local/bin if not contains $i $PATH set PATH $PATH $i end end While this will check if function hasargs is being ran with the -q option: function hasargs if contains -- -q $argv echo '$argv contains a -q option' end end The -- here stops contains from treating -q to an option to itself. Instead it treats it as a normal string to check.`,args:"contains [OPTIONS] KEY [VALUES ...]"},continue:{shortDescription:"Skip to the next iteration of a loop",description:"Within a `while` or `for` loop, `continue` skips the remaining commands in the current iteration and proceeds to the next iteration of the loop."},count:{shortDescription:"",description:""},disown:{shortDescription:"remove a process from the list of jobs",description:`disown removes the specified job from the list of jobs. The job itself continues to exist, but fish does not keep track of it any longer. Jobs in the list of jobs are sent a hang-up signal when fish terminates, which usually causes the job to terminate; disown allows these processes to continue regardless. If no process is specified, the most recently-used job is removed (like bg and fg). If one or more PIDs are specified, jobs with the specified process IDs are removed from the job list. Invalid jobs are ignored and a warning is printed. If a job is stopped, it is sent a signal to continue running, and a warning is printed. It is not possible to use the bg builtin to continue a job once it has been disowned. disown returns 0 if all specified jobs were disowned successfully, and 1 if any problems were encountered. The --help or -h option displays help about using this command. EXAMPLE firefox &; disown will start the Firefox web browser in the background and remove it from the job list, meaning it will not be closed when the fish process is closed. disown (jobs -p) removes all jobs from the job list without terminating them.`,args:"disown [PID ...]"},echo:{shortDescription:"",description:""},else:{shortDescription:"Execute commands if the previous condition was false",description:"In an `if` block, the `else` section contains commands that execute if none of the preceding `if` or `else if` conditions were true."},emit:{shortDescription:"emit a generic event",description:`emit emits, or fires, an event. Events are delivered to, or caught by, special functions called event handlers. The arguments are passed to the event handlers as function arguments. The --help or -h option displays help about using this command. EXAMPLE The following code first defines an event handler for the generic event named 'test_event', and then emits an event of that type. function event_test --on-event test_event echo event test: $argv end emit test_event something NOTES Note that events are only sent to the current fish process as there is no way to send events from one fish process to another.`,args:"emit EVENT_NAME [ARGUMENTS ...]"},end:{shortDescription:"Terminate a block of code",description:"Conclude a block of code initiated by constructs like `if`, `switch`, `while`, `for`, or `function`."},eval:{shortDescription:"Execute arguments as a command",description:"Concatenate all arguments into a single command and execute it. This allows for dynamic construction and execution of commands.",args:"COMMAND..."},exec:{shortDescription:"execute command in current process",description:`exec replaces the currently running shell with a new command. On successful completion, exec never returns. exec cannot be used inside a pipeline. The --help or -h option displays help about using this command. EXAMPLE exec emacs starts up the emacs text editor, and exits fish. When emacs exits, the session will terminate.`,args:"exec COMMAND"},exit:{shortDescription:"exit the shell",description:`exit is a special builtin that causes the shell to exit. Either 255 or the CODE supplied is used, whichever is lesser. Otherwise, the exit status will be that of the last command executed. If exit is called while sourcing a file (using the source builtin) the rest of the file will be skipped, but the shell itself will not exit. The --help or -h option displays help about using this command.`,args:"exit [CODE]"},false:{shortDescription:"Return an unsuccessful result",description:"A command that returns a non-zero exit status, indicating failure. It is often used in scripts to represent a false condition."},fg:{shortDescription:"bring job to foreground",description:`The fg builtin brings the specified job to the foreground, resuming it if it is stopped. While a foreground job is executed, fish is suspended. If no job is specified, the last job to be used is put in the foreground. If PID is specified, the job containing a process with the specified process ID is put in the foreground. For compatibility with other shells, job expansion syntax is supported for fg. A PID of the format %1 will foreground job 1. Job numbers can be seen in the output of jobs. The --help or -h option displays help about using this command. EXAMPLE fg will put the last job in the foreground. fg %3 will put job 3 into the foreground.`,args:"fg [PID]"},for:{shortDescription:"perform a set of commands multiple times",description:`for is a loop construct. It will perform the commands specified by COMMANDS multiple times. On each iteration, the local variable specified by VARNAME is assigned a new value from VALUES. If VALUES is empty, COMMANDS will not be executed at all. The VARNAME is visible when the loop terminates and will contain the last value assigned to it. If VARNAME does not already exist it will be set in the local scope. For our purposes if the for block is inside a function there must be a local variable with the same name. If the for block is not nested inside a function then global and universal variables of the same name will be used if they exist. Much like set, for does not modify $status, but the evaluation of its subordinate commands can. The -h or --help option displays help about using this command. EXAMPLE for i in foo bar baz; echo $i; end # would output: foo bar baz NOTES The VARNAME was local to the for block in releases prior to 3.0.0. This means that if you did something like this: for var in a b c if break_from_loop break end end echo $var The last value assigned to var when the loop terminated would not be available outside the loop. What echo $var would write depended on what it was set to before the loop was run. Likely nothing.`,args:"for VARNAME in [VALUES ...]; COMMANDS ...; end"},function:{shortDescription:"create a function",description:`function creates a new function NAME with the body BODY. A function is a list of commands that will be executed when the name of the function is given as a command. The following options are available: -a NAMES or --argument-names NAMES Assigns the value of successive command-line arguments to the names given in NAMES. These are the same arguments given in argv, and are still available there. See also Argument Handling. -d DESCRIPTION or --description DESCRIPTION A description of what the function does, suitable as a completion description. -w WRAPPED_COMMAND or --wraps WRAPPED_COMMAND Inherit completions from the given WRAPPED_COMMAND. See the documentation for complete for more information. -e EVENT_NAME or --on-event EVENT_NAME Run this function when the specified named event is emitted. Fish internally generates named events, for example, when showing the prompt. Custom events can be emitted using the emit command. -v VARIABLE_NAME or --on-variable VARIABLE_NAME Run this function when the variable VARIABLE_NAME changes value. Note that fish makes no guarantees on any particular timing or even that the function will be run for every single set. Rather it will be run when the variable has been set at least once, possibly skipping some values or being run when the variable has been set to the same value (except for universal variables set in other shells - only changes in the value will be picked up for those). -j PID or --on-job-exit PID Run this function when the job containing a child process with the given process identifier PID exits. Instead of a PID, the string 'caller' can be specified. This is only allowed when in a command substitution, and will result in the handler being triggered by the exit of the job which created this command substitution. -p PID or --on-process-exit PID Run this function when the fish child process with process ID PID exits. Instead of a PID, for backward compatibility, "%self" can be specified as an alias for $fish_pid, and the function will be run when the current fish instance exits. -s SIGSPEC or --on-signal SIGSPEC Run this function when the signal SIGSPEC is delivered. SIGSPEC can be a signal number, or the signal name, such as SIGHUP (or just HUP). Note that the signal must have been delivered to fish; for example, Ctrl-C sends SIGINT to the foreground process group, which will not be fish if you are running another command at the time. Observing a signal will prevent fish from exiting in response to that signal. -S or --no-scope-shadowing Allows the function to access the variables of calling functions. Normally, any variables inside the function that have the same name as variables from the calling function are "shadowed", and their contents are independent of the calling function. It's important to note that this does not capture referenced variables or the scope at the time of function declaration! At this time, fish does not have any concept of closures, and variable lifetimes are never extended. In other words, by using --no-scope-shadowing the scope of the function each time it is run is shared with the scope it was called from rather than the scope it was defined in. -V or --inherit-variable NAME Snapshots the value of the variable NAME and defines a local variable with that same name and value when the function is defined. This is similar to a closure in other languages like Python but a bit different. Note the word "snapshot" in the first sentence. If you change the value of the variable after defining the function, even if you do so in the same scope (typically another function) the new value will not be used by the function you just created using this option. See the function notify example below for how this might be used. The event handler switches (on-event, on-variable, on-job-exit, on-process-exit and on-signal) cause a function to run automatically at specific events. New named events for --on-event can be fired using the emit builtin. Fish already generates a few events, see Event handlers for more. Functions may not be named the same as a reserved keyword. These are elements of fish syntax or builtin commands which are essential for the operations of the shell. Current reserved words are [, , and, argparse, begin, break, builtin, case, command, continue, else, end, eval, exec, for, function, if, not, or, read, return, set, status, string, switch, test, time, and while. EXAMPLE function ll ls -l $argv end will run the ls command, using the -l option, while passing on any additional files and switches to ls. function mkdir -d "Create a directory and set CWD" command mkdir $argv if test $status = 0 switch $argv[(count $argv)] case '-*' case '*' cd $argv[(count $argv)] return end end end This will run the mkdir command, and if it is successful, change the current working directory to the one just created. function notify set -l job (jobs -l -g) or begin; echo "There are no jobs" >&2; return 1; end function _notify_job$job --on-job-exit $job --inherit-variable job echo -n \\a # beep functions -e _notify_job$job end end This will beep when the most recent job completes. NOTES Events are only received from the current fish process as there is no way to send events from one fish process to another. SEE MORE For more explanation of how functions fit into fish, see Functions.`,args:"function NAME [OPTIONS]; BODY; end"},functions:{shortDescription:"print or erase functions",description:`functions prints or erases functions. The following options are available: -a or --all Lists all functions, even those whose name starts with an underscore. -c or --copy OLDNAME NEWNAME Creates a new function named NEWNAME, using the definition of the OLDNAME function. -d or --description DESCRIPTION Changes the description of this function. -e or --erase Causes the specified functions to be erased. This also means that it is prevented from autoloading in the current session. Use funcsave to remove the saved copy. -D or --details Reports the path name where the specified function is defined or could be autoloaded, stdin if the function was defined interactively or on the command line or by reading standard input, - if the function was created via source, and n/a if the function isn't available. (Functions created via alias will return -, because alias uses source internally.) If the --verbose option is also specified then five lines are written: \u2022 the pathname as already described, \u2022 autoloaded, not-autoloaded or n/a, \u2022 the line number within the file or zero if not applicable, \u2022 scope-shadowing if the function shadows the vars in the calling function (the normal case if it wasn't defined with --no-scope-shadowing), else no-scope-shadowing, or n/a if the function isn't defined, \u2022 the function description minimally escaped so it is a single line, or n/a if the function isn't defined or has no description. You should not assume that only five lines will be written since we may add additional information to the output in the future. --no-details Turns off function path reporting, so just the definition will be printed. -n or --names Lists the names of all defined functions. -q or --query Tests if the specified functions exist. -v or --verbose Make some output more verbose. -H or --handlers Show all event handlers. -t or --handlers-type TYPE Show all event handlers matching the given TYPE. -h or --help Displays help about using this command. The default behavior of functions, when called with no arguments, is to print the names of all defined functions. Unless the -a option is given, no functions starting with underscores are included in the output. If any non-option parameters are given, the definition of the specified functions are printed. Copying a function using -c copies only the body of the function, and does not attach any event notifications from the original function. Only one function's description can be changed in a single invocation of functions -d. The exit status of functions is the number of functions specified in the argument list that do not exist, which can be used in concert with the -q option. EXAMPLES functions -n # Displays a list of currently-defined functions functions -c foo bar # Copies the 'foo' function to a new function called 'bar' functions -e bar # Erases the function \`\`bar\`\` SEE MORE For more explanation of how functions fit into fish, see Functions.`,args:`functions [-a | --all] [-n | --names] functions [-D | --details] [-v] FUNCTION functions -c OLDNAME NEWNAME functions -d DESCRIPTION FUNCTION functions [-e | -q] FUNCTION ...`},history:{shortDescription:"show and manipulate command history",description:`history is used to search, delete, and otherwise manipulate the history of interactive commands. The following operations (sub-commands) are available: search Returns history items matching the search string. If no search string is provided it returns all history items. This is the default operation if no other operation is specified. You only have to explicitly say history search if you wish to search for one of the subcommands. The --contains search option will be used if you don't specify a different search option. Entries are ordered newest to oldest unless you use the --reverse flag. If stdout is attached to a tty the output will be piped through your pager by the history function. The history builtin simply writes the results to stdout. delete Deletes history items. The --contains search option will be used if you don't specify a different search option. If you don't specify --exact a prompt will be displayed before any items are deleted asking you which entries are to be deleted. You can enter the word "all" to delete all matching entries. You can enter a single ID (the number in square brackets) to delete just that single entry. You can enter more than one ID, or an ID range separated by a space to delete multiple entries. Just press [enter] to not delete anything. Note that the interactive delete behavior is a feature of the history function. The history builtin only supports --exact --case-sensitive deletion. merge Immediately incorporates history changes from other sessions. Ordinarily fish ignores history changes from sessions started after the current one. This command applies those changes immediately. save Immediately writes all changes to the history file. The shell automatically saves the history file; this option is provided for internal use and should not normally need to be used by the user. clear Clears the history file. A prompt is displayed before the history is erased asking you to confirm you really want to clear all history unless builtin history is used. clear-session Clears the history file from all activity of the current session. Note: If history merge or builtin history merge is run in a session, only the history after this will be erased. The following options are available: These flags can appear before or immediately after one of the sub-commands listed above. -C or --case-sensitive Does a case-sensitive search. The default is case-insensitive. Note that prior to fish 2.4.0 the default was case-sensitive. -c or --contains Searches items in the history that contain the specified text string. This is the default for the --search flag. This is not currently supported by the delete subcommand. -e or --exact Searches or deletes items in the history that exactly match the specified text string. This is the default for the delete subcommand. Note that the match is case-insensitive by default. If you really want an exact match, including letter case, you must use the -C or --case-sensitive flag. -p or --prefix Searches items in the history that begin with the specified text string. This is not currently supported by the delete subcommand. -t or --show-time Prepends each history entry with the date and time the entry was recorded. By default it uses the strftime format # %c%n. You can specify another format; e.g., --show-time="%Y-%m-%d %H:%M:%S " or --show-time="%a%I%p". The short option, -t, doesn't accept a strftime format string; it only uses the default format. Any strftime format is allowed, including %s to get the raw UNIX seconds since the epoch. -z or --null Causes history entries written by the search operations to be terminated by a NUL character rather than a newline. This allows the output to be processed by read -z to correctly handle multiline history entries. -*NUMBER* -n NUMBER or --max NUMBER Limits the matched history items to the first NUMBER matching entries. This is only valid for history search. -R or --reverse Causes the history search results to be ordered oldest to newest. Which is the order used by most shells. The default is newest to oldest. -h or --help Displays help for this command. EXAMPLE history clear # Deletes all history items history search --contains "foo" # Outputs a list of all previous commands containing the string "foo". history delete --prefix "foo" # Interactively deletes commands which start with "foo" from the history. # You can select more than one entry by entering their IDs separated by a space. CUSTOMIZING THE NAME OF THE HISTORY FILE By default interactive commands are logged to $XDG_DATA_HOME/fish/fish_history (typically ~/.local/share/fish/fish_history). You can set the fish_history variable to another name for the current shell session. The default value (when the variable is unset) is fish which corresponds to $XDG_DATA_HOME/fish/fish_history. If you set it to e.g. fun, the history would be written to $XDG_DATA_HOME/fish/fun_history. An empty string means history will not be stored at all. This is similar to the private session features in web browsers. You can change fish_history at any time (by using set -x fish_history "session_name") and it will take effect right away. If you set it to "default", it will use the default session name (which is "fish"). Other shells such as bash and zsh use a variable named HISTFILE for a similar purpose. Fish uses a different name to avoid conflicts and signal that the behavior is different (session name instead of a file path). Also, if you set the var to anything other than fish or default it will inhibit importing the bash history. That's because the most common use case for this feature is to avoid leaking private or sensitive history when giving a presentation. NOTES If you specify both --prefix and --contains the last flag seen is used. Note that for backwards compatibility each subcommand can also be specified as a long option. For example, rather than history search you can type history --search. Those long options are deprecated and will be removed in a future release.`,args:`history [search] [--show-time] [--case-sensitive] [--exact | --prefix | --contains] [--max N] [--null] [--reverse] [SEARCH_STRING ...] history delete [--case-sensitive] [--exact | --prefix | --contains] SEARCH_STRING ... history merge history save history clear history clear-session`},if:{shortDescription:"conditionally execute a command",description:`if will execute the command CONDITION. If the condition's exit status is 0, the commands COMMANDS_TRUE will execute. If the exit status is not 0 and else is given, COMMANDS_FALSE will be executed. You can use and or or in the condition. See the second example below. The exit status of the last foreground command to exit can always be accessed using the $status variable. The -h or --help option displays help about using this command. EXAMPLE The following code will print foo.txt exists if the file foo.txt exists and is a regular file, otherwise it will print bar.txt exists if the file bar.txt exists and is a regular file, otherwise it will print foo.txt and bar.txt do not exist. if test -f foo.txt echo foo.txt exists else if test -f bar.txt echo bar.txt exists else echo foo.txt and bar.txt do not exist end The following code will print "foo.txt exists and is readable" if foo.txt is a regular file and readable if test -f foo.txt and test -r foo.txt echo "foo.txt exists and is readable" end`,args:`if CONDITION; COMMANDS_TRUE ...; [else if CONDITION2; COMMANDS_TRUE2 ...;] [else; COMMANDS_FALSE ...;] end`},jobs:{shortDescription:"print currently running jobs",description:`jobs prints a list of the currently running jobs and their status. jobs accepts the following options: -c or --command Prints the command name for each process in jobs. -g or --group Only prints the group ID of each job. -l or --last Prints only the last job to be started. -p or --pid Prints the process ID for each process in all jobs. -q or --query Prints no output for evaluation of jobs by exit status only. For compatibility with old fish versions this is also --quiet (but this is deprecated). -h or --help Displays help about using this command. On systems that support this feature, jobs will print the CPU usage of each job since the last command was executed. The CPU usage is expressed as a percentage of full CPU activity. Note that on multiprocessor systems, the total activity may be more than 100%. Arguments of the form PID or %JOBID restrict the output to jobs with the selected process identifiers or job numbers respectively. If the output of jobs is redirected or if it is part of a command substitution, the column header that is usually printed is omitted, making it easier to parse. The exit status of jobs is 0 if there are running background jobs and 1 otherwise. EXAMPLE jobs outputs a summary of the current jobs, such as two long-running tasks in this example: Job Group State Command 2 26012 running nc -l 55232 < /dev/random & 1 26011 running python tests/test_11.py &`,args:"jobs [OPTIONS] [PID | %JOBID]"},math:{shortDescription:"perform mathematics calculations",description:`math performs mathematical calculations. It supports simple operations such as addition, subtraction, and so on, as well as functions like abs(), sqrt() and ln(). By default, the output shows up to 6 decimal places. To change the number of decimal places, use the --scale option, including --scale=0 for integer output. Trailing zeroes will always be trimmed. Keep in mind that parameter expansion happens before expressions are evaluated. This can be very useful in order to perform calculations involving shell variables or the output of command substitutions, but it also means that parenthesis (()) and the asterisk (*) glob character have to be escaped or quoted. x can also be used to denote multiplication, but it needs to be followed by whitespace to distinguish it from hexadecimal numbers. Parentheses for functions are optional - math sin pi prints 0. However, a comma will bind to the inner function, so math pow sin 3, 5 is an error because it tries to give sin the arguments 3 and 5. When in doubt, use parentheses. math ignores whitespace between arguments and takes its input as multiple arguments (internally joined with a space), so math 2 +2 and math "2 + 2" work the same. math 2 2 is an error. The following options are available: -s N or --scale N Sets the scale of the result. N must be an integer or the word "max" for the maximum scale. A scale of zero causes results to be truncated, not rounded. Any non-integer component is thrown away. So 3/2 returns 1 rather than 2 which 1.5 would normally round to. This is for compatibility with bc which was the basis for this command prior to fish 3.0.0. Scale values greater than zero causes the result to be rounded using the usual rules to the specified number of decimal places. -b BASE or --base BASE Sets the numeric base used for output (math always understands hexadecimal numbers as input). It currently understands "hex" or "16" for hexadecimal and "octal" or "8" for octal and implies a scale of 0 (other scales cause an error), so it will truncate the result down to an integer. This might change in the future. Hex numbers will be printed with a 0x prefix. Octal numbers will have a prefix of 0 but aren't understood by math as input. -h or --help Displays help about using this command. RETURN VALUES If the expression is successfully evaluated and doesn't over/underflow or return NaN the return status is zero (success) else one. SYNTAX math knows some operators, constants, functions and can (obviously) read numbers. For numbers, . is always the radix character regardless of locale - 2.5, not 2,5. Scientific notation (10e5) and hexadecimal (0xFF) are also available. math allows you to use underscores as visual separators for digit grouping. For example, you can write 1_000_000, 0x_89_AB_CD_EF, and 1.234_567_e89. OPERATORS math knows the following operators: + for addition - for subtraction * or x for multiplication. * is the glob character and needs to be quoted or escaped, x needs to be followed by whitespace or it looks like 0x hexadecimal notation. / for division ^ for exponentiation % for modulo ( or ) for grouping. These need to be quoted or escaped because () denotes a command substitution. They are all used in an infix manner - 5 + 2, not + 5 2. CONSTANTS math knows the following constants: e Euler's number pi \u03C0, you know this one. Half of Tau tau Equivalent to 2\u03C0, or the number of radians in a circle Use them without a leading $ - pi - 3 should be about 0. FUNCTIONS math supports the following functions: abs the absolute value, with positive sign acos arc cosine asin arc sine atan arc tangent atan2 arc tangent of two variables bitand, bitor and bitxor perform bitwise operations. These will throw away any non-integer parts and interpret the rest as an int. Note: bitnot and bitnand don't exist. This is because numbers in math don't really have a width in terms of bits, and these operations necessarily care about leading zeroes. If you need to negate a specific number you can do it with an xor with a mask, e.g.: > math --base=hex bitxor 0x0F, 0xFF 0xF0 > math --base=hex bitxor 0x2, 0x3 # Here we mask with 0x3 == 0b111, so our number is 3 bits wide # Only the 1 bit isn't set. 0x1 ceil round number up to the nearest integer cos the cosine cosh hyperbolic cosine exp the base-e exponential function fac factorial - also known as x! (x * (x - 1) * (x - 2) * ... * 1) floor round number down to the nearest integer ln the base-e logarithm log or log10 the base-10 logarithm log2 the base-2 logarithm max returns the largest of the given numbers - this takes an arbitrary number of arguments (but at least one) min returns the smallest of the given numbers - this takes an arbitrary number of arguments (but at least one) ncr "from n choose r" combination function - how many subsets of size r can be taken from n (order doesn't matter) npr the number of subsets of size r that can be taken from a set of n elements (including different order) pow(x,y) returns x to the y (and can be written as x ^ y) round rounds to the nearest integer, away from 0 sin the sine function sinh the hyperbolic sine sqrt the square root - (can also be written as x ^ 0.5) tan the tangent tanh the hyperbolic tangent All of the trigonometric functions use radians (the pi-based scale, not 360\xB0). EXAMPLES math 1+1 outputs 2. math $status - 128 outputs the numerical exit status of the last command minus 128. math 10 / 6 outputs 1.666667. math -s0 10.0 / 6.0 outputs 1. math -s3 10 / 6 outputs 1.666. math "sin(pi)" outputs 0. math 5 \\* 2 or math "5 * 2" or math 5 "*" 2 all output 10. math 0xFF outputs 255, math 0 x 3 outputs 0 (because it computes 0 multiplied by 3). math bitand 0xFE, 0x2e outputs 46. math "bitor(9,2)" outputs 11. math --base=hex 192 prints 0xc0. math 'ncr(49,6)' prints 13983816 - that's the number of possible picks in 6-from-49 lotto. math max 5,2,3,1 prints 5. COMPATIBILITY NOTES Fish 1.x and 2.x releases relied on the bc command for handling math expressions. Starting with fish 3.0.0 fish uses the tinyexpr library and evaluates the expression without the involvement of any external commands. You don't need to use -- before the expression, even if it begins with a minus sign which might otherwise be interpreted as an invalid option. If you do insert -- before the expression, it will cause option scanning to stop just like for every other command and it won't be part of the expression.`,args:"math [(-s | --scale) N] [(-b | --base) BASE] EXPRESSION ..."},not:{shortDescription:"negate the exit status of a job",description:`not negates the exit status of another command. If the exit status is zero, not returns 1. Otherwise, not returns 0. The -h or --help option displays help about using this command. EXAMPLE The following code reports an error and exits if no file named spoon can be found. if not test -f spoon echo There is no spoon exit 1 end`,args:"not COMMAND [OPTIONS ...]"},or:{shortDescription:"conditionally execute a command",description:`or is used to execute a command if the previous command was not successful (returned a status of something other than 0). or statements may be used as part of the condition in an if or while block. or does not change the current exit status itself, but the command it runs most likely will. The exit status of the last foreground command to exit can always be accessed using the $status variable. The -h or --help option displays help about using this command. EXAMPLE The following code runs the make command to build a program. If the build succeeds, the program is installed. If either step fails, make clean is run, which removes the files created by the build process. make; and make install; or make clean SEE ALSO \u2022 and command`,args:"COMMAND1; or COMMAND2"},path:{shortDescription:"manipulate and check paths",description:`path performs operations on paths. PATH arguments are taken from the command line unless standard input is connected to a pipe or a file, in which case they are read from standard input, one PATH per line. It is an error to supply PATH arguments on both the command line and on standard input. Arguments starting with - are normally interpreted as switches; -- causes the following arguments not to be treated as switches even if they begin with -. Switches and required arguments are recognized only on the command line. When a path starts with -, path filter and path normalize will prepend ./ on output to avoid it being interpreted as an option otherwise, so it's safe to pass path's output to other commands that can handle relative paths. All subcommands accept a -q or --quiet switch, which suppresses the usual output but exits with the documented status. In this case these commands will quit early, without reading all of the available input. All subcommands also accept a -Z or --null-out switch, which makes them print output separated with NUL instead of newlines. This is for further processing, e.g. passing to another path, or xargs -0. This is not recommended when the output goes to the terminal or a command substitution. All subcommands also accept a -z or --null-in switch, which makes them accept arguments from stdin separated with NULL-bytes. Since Unix paths can't contain NULL, that makes it possible to handle all possible paths and read input from e.g. find -print0. If arguments are given on the commandline this has no effect. This should mostly be unnecessary since path automatically starts splitting on NULL if one appears in the first PATH_MAX bytes, PATH_MAX being the operating system's maximum length for a path plus a NULL byte. Some subcommands operate on the paths as strings and so work on nonexistent paths, while others need to access the paths themselves and so filter out nonexistent paths. The following subcommands are available. BASENAME SUBCOMMAND path basename [-z | --null-in] [-Z | --null-out] [-q | --quiet] [PATH ...] path basename returns the last path component of the given path, by removing the directory prefix and removing trailing slashes. In other words, it is the part that is not the dirname. For files you might call it the "filename". It returns 0 if there was a basename, i.e. if the path wasn't empty or just slashes. Examples > path basename ./foo.mp4 foo.mp4 > path basename ../banana banana > path basename /usr/bin/ bin > path basename /usr/bin/* # This prints all files in /usr/bin/ # A selection: cp fish grep rm DIRNAME SUBCOMMAND path dirname [-z | --null-in] [-Z | --null-out] [-q | --quiet] [PATH ...] path dirname returns the dirname for the given path. This is the part before the last "/", discounting trailing slashes. In other words, it is the part that is not the basename (discounting superfluous slashes). It returns 0 if there was a dirname, i.e. if the path wasn't empty or just slashes. Examples > path dirname ./foo.mp4 . > path dirname ../banana .. > path dirname /usr/bin/ /usr EXTENSION SUBCOMMAND path extension [-z | --null-in] [-Z | --null-out] [-q | --quiet] [PATH ...] path extension returns the extension of the given path. This is the part after (and including) the last ".", unless that "." followed a "/" or the basename is "." or "..", in which case there is no extension and an empty line is printed. If the filename ends in a ".", only a "." is printed. It returns 0 if there was an extension. Examples > path extension ./foo.mp4 .mp4 > path extension ../banana # an empty line, status 1 > path extension ~/.config # an empty line, status 1 > path extension ~/.config.d .d > path extension ~/.config. . > set -l path (path change-extension '' ./foo.mp4) > set -l extension (path extension ./foo.mp4) > echo $path$extension # reconstructs the original path again. ./foo.mp4 FILTER SUBCOMMAND path filter [-z | --null-in] [-Z | --null-out] [-q | --quiet] \\ [-d] [-f] [-l] [-r] [-w] [-x] \\ [-v | --invert] [(-t | --type) TYPE] [(-p | --perm) PERMISSION] [PATH ...] path filter returns all of the given paths that match the given checks. In all cases, the paths need to exist, nonexistent paths are always filtered. The available filters are: \u2022 -t or --type with the options: "dir", "file", "link", "block", "char", "fifo" and "socket", in which case the path needs to be a directory, file, link, block device, character device, named pipe or socket, respectively. \u2022 -d, -f and -l are short for --type=dir, --type=file and --type=link, respectively. There are no shortcuts for the other types. \u2022 -p or --perm with the options: "read", "write", and "exec", as well as "suid", "sgid", "user" (referring to the path owner) and "group" (referring to the path's group), in which case the path needs to have all of the given permissions for the current user. \u2022 -r, -w and -x are short for --perm=read, --perm=write and --perm=exec, respectively. There are no shortcuts for the other permissions. Note that the path needs to be any of the given types, but have all of the given permissions. This is because having a path that is both writable and executable makes sense, but having a path that is both a directory and a file doesn't. Links will count as the type of the linked-to file, so links to files count as files, links to directories count as directories. The filter options can either be given as multiple options, or comma-separated - path filter -t dir,file or path filter --type dir --type file are equivalent. With --invert, the meaning of the filtering is inverted - any path that wouldn't pass (including by not existing) passes, and any path that would pass fails. When a path starts with -, path filter will prepend ./ to avoid it being interpreted as an option otherwise. It returns 0 if at least one path passed the filter. path is is shorthand for path filter -q, i.e. just checking without producing output, see The is subcommand. Examples > path filter /usr/bin /usr/argagagji # The (hopefully) nonexistent argagagji is filtered implicitly: /usr/bin > path filter --type file /usr/bin /usr/bin/fish # Only fish is a file /usr/bin/fish > path filter --type file,dir --perm exec,write /usr/bin/fish /home/me # fish is a file, which passes, and executable, which passes, # but probably not writable, which fails. # # $HOME is a directory and both writable and executable, typically. # So it passes. /home/me > path filter -fdxw /usr/bin/fish /home/me # This is the same as above: "-f" is "--type=file", "-d" is "--type=dir", # "-x" is short for "--perm=exec" and "-w" short for "--perm=write"! /home/me > path filter -fx $PATH/* # Prints all possible commands - the first entry of each name is what fish would execute! IS SUBCOMMAND path is [-z | --null-in] [-Z | --null-out] [-q | --quiet] \\ [-d] [-f] [-l] [-r] [-w] [-x] \\ [-v | --invert] [(-t | --type) TYPE] [(-p | --perm) PERMISSION] [PATH ...] path is is short for path filter -q. It returns true if any of the given files passes the filter, but does not produce any output. --quiet can still be passed for compatibility but is redundant. The options are the same as for path filter. Examples > path is /usr/bin /usr/argagagji # /usr/bin exists, so this returns a status of 0 (true). It prints nothing. > path is /usr/argagagji # /usr/argagagji does not, so this returns a status of 1 (false). It also prints nothing. > path is -fx /bin/sh # /bin/sh is usually an executable file, so this returns true. MTIME SUBCOMMAND path mtime [-z | --null-in] [-Z | --null-out] [-q | --quiet] [-R | --relative] [PATH ...] path mtime returns the last modification time ("mtime" in unix jargon) of the given paths, in seconds since the unix epoch (the beginning of the 1st of January 1970). With --relative (or -R), it prints the number of seconds since the modification time. It only reads the current time once at start, so in case multiple paths are given the times are all relative to the start of path mtime -R running. If you want to know if a file is newer or older than another file, consider using test -nt instead. See the test documentation. It returns 0 if reading mtime for any path succeeded. Examples > date +%s # This prints the current time as seconds since the epoch 1657217847 > path mtime /etc/ 1657213796 > path mtime -R /etc/ 4078 # So /etc/ on this system was last modified a little over an hour ago # This is the same as > math (date +%s) - (path mtime /etc/) NORMALIZE SUBCOMMAND path normalize [-z | --null-in] [-Z | --null-out] [-q | --quiet] [PATH ...] path normalize returns the normalized versions of all paths. That means it squashes duplicate "/" (except for two leading "//"), collapses "../" with earlier components and removes "." components. Unlike realpath or path resolve, it does not make the paths absolute. It also does not resolve any symlinks. As such it can operate on non-existent paths. Because it operates on paths as strings and doesn't resolve symlinks, it works sort of like pwd -L and cd. E.g. path normalize link/.. will return ., just like cd link; cd .. would return to the current directory. For a physical view of the filesystem, see path resolve. Leading "./" components are usually removed. But when a path starts with -, path normalize will add it instead to avoid confusion with options. It returns 0 if any normalization was done, i.e. any given path wasn't in canonical form. Examples > path normalize /usr/bin//../../etc/fish # The "//" is squashed and the ".." components neutralize the components before /etc/fish > path normalize /bin//bash # The "//" is squashed, but /bin isn't resolved even if your system links it to /usr/bin. /bin/bash > path normalize ./my/subdirs/../sub2 my/sub2 > path normalize -- -/foo ./-/foo RESOLVE SUBCOMMAND path resolve [-z | --null-in] [-Z | --null-out] [-q | --quiet] [PATH ...] path resolve returns the normalized, physical and absolute versions of all paths. That means it resolves symlinks and does what path normalize does: it squashes duplicate "/", collapses "../" with earlier components and removes "." components. Then it turns that path into the absolute path starting from the filesystem root "/". It is similar to realpath, as it creates the "real", canonical version of the path. However, for paths that can't be resolved, e.g. if they don't exist or form a symlink loop, it will resolve as far as it can and normalize the rest. Because it resolves symlinks, it works sort of like pwd -P. E.g. path resolve link/.. will return the parent directory of what the link points to, just like cd link; cd (pwd -P)/.. would go to it. For a logical view of the filesystem, see path normalize. It returns 0 if any normalization or resolution was done, i.e. any given path wasn't in canonical form. Examples > path resolve /bin//sh # The "//" is squashed, and /bin is resolved if your system links it to /usr/bin. # sh here is bash (this is common on linux systems) /usr/bin/bash > path resolve /bin/foo///bar/../baz # Assuming /bin exists and is a symlink to /usr/bin, but /bin/foo doesn't. # This resolves the /bin/ and normalizes the nonexistent rest: /usr/bin/foo/baz CHANGE-EXTENSION SUBCOMMAND path change-extension [-z | --null-in] [-Z | --null-out] \\ [-q | --quiet] EXTENSION [PATH ...] path change-extension returns the given paths, with their extension changed to the given new extension. The extension is the part after (and including) the last ".", unless that "." followed a "/" or the basename is "." or "..", in which case there is no previous extension and the new one is simply added. If the extension is empty, any previous extension is stripped, along with the ".". This is, of course, the inverse of path extension. One leading dot on the extension is ignored, so ".mp3" and "mp3" are treated the same. It returns 0 if it was given any paths. Examples > path change-extension mp4 ./foo.wmv ./foo.mp4 > path change-extension .mp4 ./foo.wmv ./foo.mp4 > path change-extension '' ../banana ../banana # but status 1, because there was no extension. > path change-extension '' ~/.config /home/alfa/.config # status 1 > path change-extension '' ~/.config.d /home/alfa/.config # status 0 > path change-extension '' ~/.config. /home/alfa/.config # status 0 SORT SUBCOMMAND path sort [-z | --null-in] [-Z | --null-out] \\ [-q | --quiet] [-r | --reverse] \\ [--key=basename|dirname|path] [PATH ...] path sort returns the given paths in sorted order. They are sorted in the same order as globs - alphabetically, but with runs of numerical digits compared numerically. With --reverse or -r the sort is reversed. With --key= only the given part of the path is compared, e.g. --key=dirname causes only the dirname to be compared, --key=basename only the basename and --key=path causes the entire path to be compared (this is the default). With --unique or -u the sort is deduplicated, meaning only the first of a run that have the same key is kept. So if you are sorting by basename, then only the first of each basename is used. The sort used is stable, so sorting first by basename and then by dirname works and causes the files to be grouped according to directory. It currently returns 0 if it was given any paths. Examples > path sort 10-foo 2-bar 2-bar 10-foo > path sort --reverse 10-foo 2-bar 10-foo 2-bar > path sort --unique --key=basename $fish_function_path/*.fish # prints a list of all function files fish would use, sorted by name. COMBINING PATH path is meant to be easy to combine with itself, other tools and fish. This is why \u2022 path's output is automatically split by fish if it goes into a command substitution, so just doing (path ...) handles all paths, even those containing newlines, correctly \u2022 path has --null-in to handle null-delimited input (typically automatically detected!), and --null-out to pass on null-delimited output Some examples of combining path: # Expand all paths in the current directory, leave only executable files, and print their resolved path path filter -zZ -xf -- * | path resolve -z # The same thing, but using find (note -maxdepth needs to come first or find will scream) # (this also depends on your particular version of find) # Note the \`-z\` is unnecessary for any sensible version of find - if \`path\` sees a NULL, # it will split on NULL automatically. find . -maxdepth 1 -type f -executable -print0 | path resolve -z set -l paths (path filter -p exec $PATH/fish -Z | path resolve)`,args:`path basename GENERAL_OPTIONS [PATH ...] path dirname GENERAL_OPTIONS [PATH ...] path extension GENERAL_OPTIONS [PATH ...] path filter GENERAL_OPTIONS [-v | --invert] [-d] [-f] [-l] [-r] [-w] [-x] [(-t | --type) TYPE] [(-p | --perm) PERMISSION] [PATH ...] path is GENERAL_OPTIONS [(-v | --invert)] [(-t | --type) TYPE] [-d] [-f] [-l] [-r] [-w] [-x] [(-p | --perm) PERMISSION] [PATH ...] path mtime GENERAL_OPTIONS [(-R | --relative)] [PATH ...] path normalize GENERAL_OPTIONS [PATH ...] path resolve GENERAL_OPTIONS [PATH ...] path change-extension GENERAL_OPTIONS EXTENSION [PATH ...] path sort GENERAL_OPTIONS [-r | --reverse] [-u | --unique] [--key=basename|dirname|path] [PATH ...] GENERAL_OPTIONS [-z | --null-in] [-Z | --null-out] [-q | --quiet]`},printf:{shortDescription:"Display formatted text",description:"The `printf` command formats and prints text according to a specified format string. Unlike `echo`, `printf` does not append a newline unless explicitly included in the format.",args:"FORMAT [ARGUMENT...]"},pwd:{shortDescription:"output the current working directory",description:`NOTE: This page documents the fish builtin pwd. To see the documentation on the pwd command you might have, use command man pwd. pwd outputs (prints) the current working directory. The following options are available: -L or --logical Output the logical working directory, without resolving symlinks (default behavior). -P or --physical Output the physical working directory, with symlinks resolved. -h or --help Displays help about using this command. SEE ALSO Navigate directories using the directory history or the directory stack`,args:`pwd [-P | --physical] pwd [-L | --logical]`},random:{shortDescription:"generate random number",description:`random generates a pseudo-random integer from a uniform distribution. The range (inclusive) depends on the arguments. No arguments indicate a range of 0 to 32767 (inclusive). If one argument is specified, the internal engine will be seeded with the argument for future invocations of random and no output will be produced. Two arguments indicate a range from START to END (both START and END included). Three arguments indicate a range from START to END with a spacing of STEP between possible outputs. random choice will select one random item from the succeeding arguments. The -h or --help option displays help about using this command. Note that seeding the engine will NOT give the same result across different systems. You should not consider random cryptographically secure, or even statistically accurate. EXAMPLE The following code will count down from a random even number between 10 and 20 to 1: for i in (seq (random 10 2 20) -1 1) echo $i end And this will open a random picture from any of the subdirectories: open (random choice **.jpg) Or, to only get even numbers from 2 to 20: random 2 2 20 Or odd numbers from 1 to 3: random 1 2 3 # or 1 2 4`,args:`random random SEED random START END random START STEP END random choice [ITEMS ...]`},read:{shortDescription:"read line of input into variables",description:`read reads from standard input and either writes the result back to standard output (for use in command substitution), or stores the result in one or more shell variables. By default, read reads a single line and splits it into variables on spaces or tabs. Alternatively, a null character or a maximum number of characters can be used to terminate the input, and other delimiters can be given. Unlike other shells, there is no default variable (such as REPLY) for storing the result - instead, it is printed on standard output. The following options are available: -c CMD or --command CMD Sets the initial string in the interactive mode command buffer to CMD. -d or --delimiter DELIMITER Splits on DELIMITER. DELIMITER will be used as an entire string to split on, not a set of characters. -g or --global Makes the variables global. -s or --silent Masks characters written to the terminal, replacing them with asterisks. This is useful for reading things like passwords or other sensitive information. -f or --function Scopes the variable to the currently executing function. It is erased when the function ends. -l or --local Scopes the variable to the currently executing block. It is erased when the block ends. Outside of a block, this is the same as --function. -n or --nchars NCHARS Makes read return after reading NCHARS characters or the end of the line, whichever comes first. -p or --prompt PROMPT_CMD Uses the output of the shell command PROMPT_CMD as the prompt for the interactive mode. The default prompt command is set_color green; echo read; set_color normal; echo "> " -P or --prompt-str PROMPT_STR Uses the PROMPT_STR as the prompt for the interactive mode. It is equivalent to echo $PROMPT_STR and is provided solely to avoid the need to frame the prompt as a command. All special characters in the string are automatically escaped before being passed to the echo command. -R or --right-prompt RIGHT_PROMPT_CMD Uses the output of the shell command RIGHT_PROMPT_CMD as the right prompt for the interactive mode. There is no default right prompt command. -S or --shell Enables syntax highlighting, tab completions and command termination suitable for entering shellscript code in the interactive mode. NOTE: Prior to fish 3.0, the short opt for --shell was -s, but it has been changed for compatibility with bash's -s short opt for --silent. -t -or --tokenize Causes read to split the input into variables by the shell's tokenization rules. This means it will honor quotes and escaping. This option is of course incompatible with other options to control splitting like --delimiter and does not honor IFS (like fish's tokenizer). It saves the tokens in the manner they'd be passed to commands on the commandline, so e.g. a\\ b is stored as a b. Note that currently it leaves command substitutions intact along with the parentheses. -u or --unexport Prevents the variables from being exported to child processes (default behaviour). -U or --universal Causes the specified shell variable to be made universal. -x or --export Exports the variables to child processes. -a or --list Stores the result as a list in a single variable. This option is also available as --array for backwards compatibility. -z or --null Marks the end of the line with the NUL character, instead of newline. This also disables interactive mode. -L or --line Reads each line into successive variables, and stops after each variable has been filled. This cannot be combined with the --delimiter option. Without the --line option, read reads a single line of input from standard input, breaks it into tokens, and then assigns one token to each variable specified in VARIABLES. If there are more tokens than variables, the complete remainder is assigned to the last variable. If no option to determine how to split like --delimiter, --line or --tokenize is given, the variable IFS is used as a list of characters to split on. Relying on the use of IFS is deprecated and this behaviour will be removed in future versions. The default value of IFS contains space, tab and newline characters. As a special case, if IFS is set to the empty string, each character of the input is considered a separate token. With the --line option, read reads a line of input from standard input into each provided variable, stopping when each variable has been filled. The line is not tokenized. If no variable names are provided, read enters a special case that simply provides redirection from standard input to standard output, useful for command substitution. For instance, the fish shell command below can be used to read data that should be provided via a command line argument from the console instead of hardcoding it in the command itself, allowing the command to both be reused as-is in various contexts with different input values and preventing possibly sensitive text from being included in the shell history: mysql -uuser -p(read) When running in this mode, read does not split the input in any way and text is redirected to standard output without any further processing or manipulation. If -a or --array is provided, only one variable name is allowed and the tokens are stored as a list in this variable. See the documentation for set for more details on the scoping rules for variables. When read reaches the end-of-file (EOF) instead of the terminator, the exit status is set to 1. Otherwise, it is set to 0. In order to protect the shell from consuming too many system resources, read will only consume a maximum of 100 MiB (104857600 bytes); if the terminator is not reached before this limit then VARIABLE is set to empty and the exit status is set to 122. This limit can be altered with the fish_read_limit variable. If set to 0 (zero), the limit is removed. EXAMPLE read has a few separate uses. The following code stores the value 'hello' in the shell variable foo. echo hello|read foo The while command is a neat way to handle command output line-by-line: printf '%s\\n' line1 line2 line3 line4 | while read -l foo echo "This is another line: $foo" end Delimiters given via "-d" are taken as one string: echo a==b==c | read -d == -l a b c echo $a # a echo $b # b echo $c # c --tokenize honors quotes and escaping like the shell's argument passing: echo 'a\\ b' | read -t first second echo $first # outputs "a b", $second is empty echo 'a"foo bar"b (command echo wurst)*" "{a,b}' | read -lt -l a b c echo $a # outputs 'afoo barb' (without the quotes) echo $b # outputs '(command echo wurst)* {a,b}' (without the quotes) echo $c # nothing For an example on interactive use, see Querying for user input.`,args:"read [OPTIONS] [VARIABLE ...]"},realpath:{shortDescription:"Resolve and print the absolute path",description:"Convert each provided path to its absolute, canonical form by resolving symbolic links and relative path components.",args:"PATH..."},return:{shortDescription:"stop the current inner function",description:`return halts a currently running function. The exit status is set to N if it is given. If return is invoked outside of a function or dot script it is equivalent to exit. It is often added inside of a conditional block such as an if statement or a switch statement to conditionally stop the executing function and return to the caller; it can also be used to specify the exit status of a function. If at the top level of a script, it exits with the given status, like exit. If at the top level in an interactive session, it will set status, but not exit the shell. The -h or --help option displays help about using this command. EXAMPLE An implementation of the false command as a fish function: function false return 1 end`,args:"return [N]"},set:{shortDescription:"display and change shell variables",description:`set manipulates shell variables. If both NAME and VALUE are provided, set assigns any values to variable NAME. Variables in fish are lists, multiple values are allowed. One or more variable INDEX can be specified including ranges (not for all options.) If no VALUE is given, the variable will be set to the empty list. If set is ran without arguments, it prints the names and values of all shell variables in sorted order. Passing scope or export flags allows filtering this to only matching variables, so set --local would only show local variables. With --erase and optionally a scope flag set will erase the matching variable (or the variable of that name in the smallest possible scope). With --show, set will describe the given variable names, explaining how they have been defined - in which scope with which values and options. The following options control variable scope: -U or --universal Sets a universal variable. The variable will be immediately available to all the user's fish instances on the machine, and will be persisted across restarts of the shell. -f or --function Sets a variable scoped to the executing function. It is erased when the function ends. -l or --local Sets a locally-scoped variable in this block. It is erased when the block ends. Outside of a block, this is the same as --function. -g or --global Sets a globally-scoped variable. Global variables are available to all functions running in the same shell. They can be modified or erased. These options modify how variables operate: --export or -x Causes the specified shell variable to be exported to child processes (making it an "environment variable"). --unexport or -u Causes the specified shell variable to NOT be exported to child processes. --path Treat specified variable as a path variable; variable will be split on colons (:) and will be displayed joined by colons when quoted (echo "$PATH") or exported. --unpath Causes variable to no longer be treated as a path variable. Note: variables ending in "PATH" are automatically path variables. Further options: -a or --append NAME VALUE ... Appends VALUES to the current set of values for variable NAME. Can be used with --prepend to both append and prepend at the same time. This cannot be used when assigning to a variable slice. -p or --prepend NAME VALUE ... Prepends VALUES to the current set of values for variable NAME. This can be used with --append to both append and prepend at the same time. This cannot be used when assigning to a variable slice. -e or --erase NAME*[*INDEX] Causes the specified shell variables to be erased. Supports erasing from multiple scopes at once. Individual items in a variable at INDEX in brackets can be specified. -q or --query NAME*[*INDEX] Test if the specified variable names are defined. If an INDEX is provided, check for items at that slot. Does not output anything, but the shell status is set to the number of variables specified that were not defined, up to a maximum of 255. If no variable was given, it also returns 255. -n or --names List only the names of all defined variables, not their value. The names are guaranteed to be sorted. -S or --show Shows information about the given variables. If no variable names are given then all variables are shown in sorted order. It shows the scopes the given variables are set in, along with the values in each and whether or not it is exported. No other flags can be used with this option. -L or --long Do not abbreviate long values when printing set variables. -h or --help Displays help about using this command. If a variable is set to more than one value, the variable will be a list with the specified elements. If a variable is set to zero elements, it will become a list with zero elements. If the variable name is one or more list elements, such as PATH[1 3 7], only those list elements specified will be changed. If you specify a negative index when expanding or assigning to a list variable, the index will be calculated from the end of the list. For example, the index -1 means the last index of a list. The scoping rules when creating or updating a variable are: \u2022 Variables may be explicitly set as universal, global, function, or local. Variables with the same name but in a different scope will not be changed. \u2022 If the scope of a variable is not explicitly set but a variable by that name has been previously defined, the scope of the existing variable is used. If the variable is already defined in multiple scopes, the variable with the narrowest scope will be updated. \u2022 If a variable's scope is not explicitly set and there is no existing variable by that name, the variable will be local to the currently executing function. Note that this is different from using the -l or --local flag, in which case the variable will be local to the most-inner currently executing block, while without them the variable will be local to the function as a whole. If no function is executing, the variable will be set in the global scope. The exporting rules when creating or updating a variable are identical to the scoping rules for variables: \u2022 Variables may be explicitly set to either exported or not exported. When an exported variable goes out of scope, it is unexported. \u2022 If a variable is not explicitly set to be exported or not exported, but has been previously defined, the previous exporting rule for the variable is kept. \u2022 If a variable is not explicitly set to be either exported or unexported and has never before been defined, the variable will not be exported. In query mode, the scope to be examined can be specified. Whether the variable has to be a path variable or exported can also be specified. In erase mode, if variable indices are specified, only the specified slices of the list variable will be erased. set requires all options to come before any other arguments. For example, set flags -l will have the effect of setting the value of the variable flags to '-l', not making the variable local. EXIT STATUS In assignment mode, set does not modify the exit status, but passes along whatever status was set, including by command substitutions. This allows capturing the output and exit status of a subcommand, like in if set output (command). In query mode, the exit status is the number of variables that were not found. In erase mode, set exits with a zero exit status in case of success, with a non-zero exit status if the commandline was invalid, if any of the variables did not exist or was a special read-only variable. EXAMPLES Print all global, exported variables: > set -gx Set the value of the variable $foo to be 'hi'.: > set foo hi Append the value "there" to the variable $foo: > set -a foo there Remove $smurf from the scope: > set -e smurf Remove $smurf from the global and universal scopes: > set -e -Ug smurf Change the fourth element of the $PATH list to ~/bin: > set PATH[4] ~/bin Outputs the path to Python if type -p returns true: if set python_path (type -p python) echo "Python is at $python_path" end Setting a variable doesn't modify $status; a command substitution still will, though: > echo $status 0 > false > set foo bar > echo $status 1 > true > set foo banana (false) > echo $status 1 VAR=VALUE command sets a variable for just one command, like other shells. This runs fish with a temporary home directory: > HOME=(mktemp -d) fish (which is essentially the same as): > begin; set -lx HOME (mktemp -d); fish; end NOTES \u2022 Fish versions prior to 3.0 supported the syntax set PATH[1] PATH[4] /bin /sbin, which worked like set PATH[1 4] /bin /sbin.`,args:`set set (-f | --function) (-l | local) (-g | --global) (-U | --universal) set [-Uflg] NAME [VALUE ...] set [-Uflg] NAME[[INDEX ...]] [VALUE ...] set (-a | --append) [-flgU] NAME VALUE ... set (-q | --query) (-e | --erase) [-flgU] [NAME][[INDEX]] ...] set (-S | --show) [NAME ...]`},set_color:{shortDescription:"set the terminal color",description:`set_color is used to control the color and styling of text in the terminal. VALUE describes that styling. VALUE can be a reserved color name like red or an RGB color value given as 3 or 6 hexadecimal digits ("F27" or "FF2277"). A special keyword normal resets text formatting to terminal defaults. Valid colors include: \u2022 black, red, green, yellow, blue, magenta, cyan, white \u2022 brblack, brred, brgreen, bryellow, brblue, brmagenta, brcyan, brwhite The br- (as in 'bright') forms are full-brightness variants of the 8 standard-brightness colors on many terminals. brblack has higher brightness than black - towards gray. An RGB value with three or six hex digits, such as A0FF33 or f2f can be used. Fish will choose the closest supported color. A three digit value is equivalent to specifying each digit twice; e.g., set_color 2BC is the same as set_color 22BBCC. Hexadecimal RGB values can be in lower or uppercase. Depending on the capabilities of your terminal (and the level of support set_color has for it) the actual color may be approximated by a nearby matching reserved color name or set_color may not have an effect on color. A second color may be given as a desired fallback color. e.g. set_color 124212 brblue will instruct set_color to use brblue if a terminal is not capable of the exact shade of grey desired. This is very useful when an 8 or 16 color terminal might otherwise not use a color. The following options are available: -b or --background COLOR Sets the background color. -c or --print-colors Prints the given colors or a colored list of the 16 named colors. -o or --bold Sets bold mode. -d or --dim Sets dim mode. -i or --italics Sets italics mode. -r or --reverse Sets reverse mode. -u or --underline Sets underlined mode. -h or --help Displays help about using this command. Using the normal keyword will reset foreground, background, and all formatting back to default. NOTES 1. Using the normal keyword will reset both background and foreground colors to whatever is the default for the terminal. 2. Setting the background color only affects subsequently written characters. Fish provides no way to set the background color for the entire terminal window. Configuring the window background color (and other attributes such as its opacity) has to be done using whatever mechanisms the terminal provides. Look for a config option. 3. Some terminals use the --bold escape sequence to switch to a brighter color set rather than increasing the weight of text. 4. set_color works by printing sequences of characters to standard output. If used in command substitution or a pipe, these characters will also be captured. This may or may not be desirable. Checking the exit status of isatty stdout before using set_color can be useful to decide not to colorize output in a script. EXAMPLES set_color red; echo "Roses are red" set_color blue; echo "Violets are blue" set_color 62A; echo "Eggplants are dark purple" set_color normal; echo "Normal is nice" # Resets the background too TERMINAL CAPABILITY DETECTION Fish uses some heuristics to determine what colors a terminal supports to avoid sending sequences that it won't understand. In particular it will: \u2022 Enable 256 colors if TERM contains "xterm", except for known exceptions (like MacOS 10.6 Terminal.app) \u2022 Enable 24-bit ("true-color") even if the $TERM entry only reports 256 colors. This includes modern xterm, VTE-based terminals like Gnome Terminal, Konsole and iTerm2. \u2022 Detect support for italics, dim, reverse and other modes. If terminfo reports 256 color support for a terminal, 256 color support will always be enabled. To force true-color support on or off, set fish_term24bit to "1" for on and 0 for off - set -g fish_term24bit 1. To debug color palette problems, tput colors may be useful to see the number of colors in terminfo for a terminal. Fish launched as fish -d term_support will include diagnostic messages that indicate the color support mode in use. The set_color command uses the terminfo database to look up how to change terminal colors on whatever terminal is in use. Some systems have old and incomplete terminfo databases, and lack color information for terminals that support it. Fish assumes that all terminals can use the [ANSI X3.64](https://en.wikipedia.org/wiki/ANSI_escape_code) escape sequences if the terminfo definition indicates a color below 16 is not supported.`,args:"set_color [OPTIONS] VALUE"},source:{shortDescription:"evaluate contents of file",description:`source evaluates the commands of the specified FILE in the current shell as a new block of code. This is different from starting a new process to perform the commands (i.e. fish < FILE) since the commands will be evaluated by the current shell, which means that changes in shell variables will affect the current shell. If additional arguments are specified after the file name, they will be inserted into the argv variable. The argv variable will not include the name of the sourced file. fish will search the working directory to resolve relative paths but will not search PATH . If no file is specified and stdin is not the terminal, or if the file name - is used, stdin will be read. The exit status of source is the exit status of the last job to execute. If something goes wrong while opening or reading the file, source exits with a non-zero status. . (a single period) is an alias for the source command. The use of . is deprecated in favour of source, and . will be removed in a future version of fish. source creates a new local scope; set --local within a sourced block will not affect variables in the enclosing scope. The -h or --help option displays help about using this command. EXAMPLE source ~/.config/fish/config.fish # Causes fish to re-read its initialization file. CAVEATS In fish versions prior to 2.3.0, the argv variable would have a single element (the name of the sourced file) if no arguments are present. Otherwise, it would contain arguments without the name of the sourced file. That behavior was very confusing and unlike other shells such as bash and zsh.`,args:`source FILE [ARGUMENTS ...] SOMECOMMAND | source`},status:{shortDescription:"query fish runtime information",description:`With no arguments, status displays a summary of the current login and job control status of the shell. The following operations (subcommands) are available: is-command-substitution, -c or --is-command-substitution Returns 0 if fish is currently executing a command substitution. is-block, -b or --is-block Returns 0 if fish is currently executing a block of code. is-breakpoint Returns 0 if fish is currently showing a prompt in the context of a breakpoint command. See also the fish_breakpoint_prompt function. is-interactive, -i or --is-interactive Returns 0 if fish is interactive - that is, connected to a keyboard. is-login, -l or --is-login Returns 0 if fish is a login shell - that is, if fish should perform login tasks such as setting up PATH. is-full-job-control or --is-full-job-control Returns 0 if full job control is enabled. is-interactive-job-control or --is-interactive-job-control Returns 0 if interactive job control is enabled. is-no-job-control or --is-no-job-control Returns 0 if no job control is enabled. current-command Prints the name of the currently-running function or command, like the deprecated variable. current-commandline Prints the entirety of the currently-running commandline, inclusive of all jobs and operators. filename, current-filename, -f or --current-filename Prints the filename of the currently-running script. If the current script was called via a symlink, this will return the symlink. If the current script was received by piping into source, then this will return -. basename Prints just the filename of the running script, without any path components before. dirname Prints just the path to the running script, without the actual filename itself. This can be relative to PWD (including just "."), depending on how the script was called. This is the same as passing the filename to dirname(3). It's useful if you want to use other files in the current script's directory or similar. fish-path Prints the absolute path to the currently executing instance of fish. This is a best-effort attempt and the exact output is down to what the platform gives fish. In some cases you might only get "fish". function or current-function Prints the name of the currently called function if able, when missing displays "Not a function" (or equivalent translated string). line-number, current-line-number, -n or --current-line-number Prints the line number of the currently running script. stack-trace, print-stack-trace, -t or --print-stack-trace Prints a stack trace of all function calls on the call stack. job-control, -j or --job-control CONTROL_TYPE Sets the job control type to CONTROL_TYPE, which can be none, full, or interactive. features Lists all available feature flags. test-feature FEATURE Returns 0 when FEATURE is enabled, 1 if it is disabled, and 2 if it is not recognized. NOTES For backwards compatibility most subcommands can also be specified as a long or short option. For example, rather than status is-login you can type status --is-login. The flag forms are deprecated and may be removed in a future release (but not before fish 4.0). You can only specify one subcommand per invocation even if you use the flag form of the subcommand.`,args:`status status is-login status is-interactive status is-block status is-breakpoint status is-command-substitution status is-no-job-control status is-full-job-control status is-interactive-job-control status current-command status current-commandline status filename status basename status dirname status fish-path status function status line-number status stack-trace status job-control CONTROL_TYPE status features status test-feature FEATURE`},string:{shortDescription:"manipulate strings",description:`string performs operations on strings. STRING arguments are taken from the command line unless standard input is connected to a pipe or a file, in which case they are read from standard input, one STRING per line. It is an error to supply STRING arguments on the command line and on standard input. Arguments beginning with - are normally interpreted as switches; -- causes the following arguments not to be treated as switches even if they begin with -. Switches and required arguments are recognized only on the command line. Most subcommands accept a -q or --quiet switch, which suppresses the usual output but exits with the documented status. In this case these commands will quit early, without reading all of the available input. The following subcommands are available. COLLECT SUBCOMMAND string collect [-a | --allow-empty] [-N | --no-trim-newlines] [STRING ...] string collect collects its input into a single output argument, without splitting the output when used in a command substitution. This is useful when trying to collect multiline output from another command into a variable. Exit status: 0 if any output argument is non-empty, or 1 otherwise. A command like echo (cmd | string collect) is mostly equivalent to a quoted command substitution (echo "$(cmd)"). The main difference is that the former evaluates to zero or one elements whereas the quoted command substitution always evaluates to one element due to string interpolation. If invoked with multiple arguments instead of input, string collect preserves each argument separately, where the number of output arguments is equal to the number of arguments given to string collect. Any trailing newlines on the input are trimmed, just as with "$(cmd)" substitution. Use --no-trim-newlines to disable this behavior, which may be useful when running a command such as set contents (cat filename | string collect -N). With --allow-empty, string collect always prints one (empty) argument. This can be used to prevent an argument from disappearing. Examples > echo "zero $(echo one\\ntwo\\nthree) four" zero one two three four > echo \\"(echo one\\ntwo\\nthree | string collect)\\" "one two three" > echo \\"(echo one\\ntwo\\nthree | string collect -N)\\" "one two three " > echo foo(true | string collect --allow-empty)bar foobar ESCAPE AND UNESCAPE SUBCOMMANDS string escape [-n | --no-quoted] [--style=] [STRING ...] string unescape [--style=] [STRING ...] string escape escapes each STRING in one of three ways. The first is --style=script. This is the default. It alters the string such that it can be passed back to eval to produce the original argument again. By default, all special characters are escaped, and quotes are used to simplify the output when possible. If -n or --no-quoted is given, the simplifying quoted format is not used. Exit status: 0 if at least one string was escaped, or 1 otherwise. --style=var ensures the string can be used as a variable name by hex encoding any non-alphanumeric characters. The string is first converted to UTF-8 before being encoded. --style=url ensures the string can be used as a URL by hex encoding any character which is not legal in a URL. The string is first converted to UTF-8 before being encoded. --style=regex escapes an input string for literal matching within a regex expression. The string is first converted to UTF-8 before being encoded. string unescape performs the inverse of the string escape command. If the string to be unescaped is not properly formatted it is ignored. For example, doing string unescape --style=var (string escape --style=var $str) will return the original string. There is no support for unescaping --style=regex. Examples > echo \\x07 | string escape \\cg > string escape --style=var 'a1 b2'\\u6161 a1_20_b2_E6_85_A1 JOIN AND JOIN0 SUBCOMMANDS string join [-q | --quiet] SEP [STRING ...] string join0 [-q | --quiet] [STRING ...] string join joins its STRING arguments into a single string separated by SEP, which can be an empty string. Exit status: 0 if at least one join was performed, or 1 otherwise. If -n or --no-empty is specified, empty strings are excluded from consideration (e.g. string join -n + a b "" c would expand to a+b+c not a+b++c). string join0 joins its STRING arguments into a single string separated by the zero byte (NUL), and adds a trailing NUL. This is most useful in conjunction with tools that accept NUL-delimited input, such as sort -z. Exit status: 0 if at least one join was performed, or 1 otherwise. Because Unix uses NUL as the string terminator, passing the output of string join0 as an argument to a command (via a command substitution) won't actually work. Fish will pass the correct bytes along, but the command won't be able to tell where the argument ends. This is a limitation of Unix' argument passing. Examples > seq 3 | string join ... 1...2...3 # Give a list of NUL-separated filenames to du (this is a GNU extension) > string join0 file1 file2 file\\nwith\\nmultiple\\nlines | du --files0-from=- # Just put the strings together without a separator > string join '' a b c abc LENGTH SUBCOMMAND string length [-q | --quiet] [-V | --visible] [STRING ...] string length reports the length of each string argument in characters. Exit status: 0 if at least one non-empty STRING was given, or 1 otherwise. With -V or --visible, it uses the visible width of the arguments. That means it will discount escape sequences fish knows about, account for $fish_emoji_width and $fish_ambiguous_width. It will also count each line (separated by \\n) on its own, and with a carriage return (\\r) count only the widest stretch on a line. The intent is to measure the number of columns the STRING would occupy in the current terminal. Examples > string length 'hello, world' 12 > set str foo > string length -q $str; echo $status 0 # Equivalent to test -n "$str" > string length --visible (set_color red)foobar # the set_color is discounted, so this is the width of "foobar" 6 > string length --visible \u{1F41F}\u{1F41F}\u{1F41F}\u{1F41F} # depending on $fish_emoji_width, this is either 4 or 8 # in new terminals it should be 8 > string length --visible abcdef\\r123 # this displays as "123def", so the width is 6 6 > string length --visible a\\nbc # counts "a" and "bc" as separate lines, so it prints width for each 1 2 LOWER SUBCOMMAND string lower [-q | --quiet] [STRING ...] string lower converts each string argument to lowercase. Exit status: 0 if at least one string was converted to lowercase, else 1. This means that in conjunction with the -q flag you can readily test whether a string is already lowercase. MATCH SUBCOMMAND string match [-a | --all] [-e | --entire] [-i | --ignore-case] [-g | --groups-only] [-r | --regex] [-n | --index] [-q | --quiet] [-v | --invert] PATTERN [STRING ...] string match tests each STRING against PATTERN and prints matching substrings. Only the first match for each STRING is reported unless -a or --all is given, in which case all matches are reported. If you specify the -e or --entire then each matching string is printed including any prefix or suffix not matched by the pattern (equivalent to grep without the -o flag). You can, obviously, achieve the same result by prepending and appending * or .* depending on whether or not you have specified the --regex flag. The --entire flag is simply a way to avoid having to complicate the pattern in that fashion and make the intent of the string match clearer. Without --entire and --regex, a PATTERN will need to match the entire STRING before it will be reported. Matching can be made case-insensitive with --ignore-case or -i. If --groups-only or -g is given, only the capturing groups will be reported - meaning the full match will be skipped. This is incompatible with --entire and --invert, and requires --regex. It is useful as a simple cutting tool instead of string replace, so you can simply choose "this part" of a string. If --index or -n is given, each match is reported as a 1-based start position and a length. By default, PATTERN is interpreted as a glob pattern matched against each entire STRING argument. A glob pattern is only considered a valid match if it matches the entire STRING. If --regex or -r is given, PATTERN is interpreted as a Perl-compatible regular expression, which does not have to match the entire STRING. For a regular expression containing capturing groups, multiple items will be reported for each match, one for the entire match and one for each capturing group. With this, only the matching part of the STRING will be reported, unless --entire is given. When matching via regular expressions, string match automatically sets variables for all named capturing groups ((?expression)). It will create a variable with the name of the group, in the default scope, for each named capturing group, and set it to the value of the capturing group in the first matched argument. If a named capture group matched an empty string, the variable will be set to the empty string (like set var ""). If it did not match, the variable will be set to nothing (like set var). When --regex is used with --all, this behavior changes. Each named variable will contain a list of matches, with the first match contained in the first element, the second match in the second, and so on. If the group was empty or did not match, the corresponding element will be an empty string. If --invert or -v is used the selected lines will be only those which do not match the given glob pattern or regular expression. Exit status: 0 if at least one match was found, or 1 otherwise. Match Glob Examples > string match '?' a a > string match 'a*b' axxb axxb > string match -i 'a??B' Axxb Axxb > string match -- '-*' -h foo --version bar # To match things that look like options, we need a \`--\` # to tell string its options end there. -h --version > echo 'ok?' | string match '*\\?' ok? # Note that only the second STRING will match here. > string match 'foo' 'foo1' 'foo' 'foo2' foo > string match -e 'foo' 'foo1' 'foo' 'foo2' foo1 foo foo2 > string match 'foo?' 'foo1' 'foo' 'foo2' foo1 foo2 Match Regex Examples > string match -r 'cat|dog|fish' 'nice dog' dog > string match -r -v "c.*[12]" {cat,dog}(seq 1 4) dog1 dog2 cat3 dog3 cat4 dog4 > string match -r -- '-.*' -h foo --version bar # To match things that look like options, we need a \`--\` # to tell string its options end there. -h --version > string match -r '(\\d\\d?):(\\d\\d):(\\d\\d)' 2:34:56 2:34:56 2 34 56 > string match -r '^(\\w{2,4})\\1$' papa mud murmur papa pa murmur mur > string match -r -a -n at ratatat 2 2 4 2 6 2 > string match -r -i '0x[0-9a-f]{1,8}' 'int magic = 0xBadC0de;' 0xBadC0de > echo $version 3.1.2-1575-ga2ff32d90 > string match -rq '(?\\d+).(?\\d+).(?\\d+)' -- $version > echo "You are using fish $major!" You are using fish 3! > string match -raq ' *(?[^.!?]+)(?[.!?])?' "hello, friend. goodbye" > printf "%s\\n" -- $sentence hello, friend goodbye > printf "%s\\n" -- $punctuation . > string match -rq '(?hello)' 'hi' > count $word 0 PAD AND SHORTEN SUBCOMMANDS string pad [-r | --right] [(-c | --char) CHAR] [(-w | --width) INTEGER] [STRING ...] string pad extends each STRING to the given visible width by adding CHAR to the left. That means the width of all visible characters added together, excluding escape sequences and accounting for fish_emoji_width and fish_ambiguous_width. It is the amount of columns in a terminal the STRING occupies. The escape sequences reflect what fish knows about, and how it computes its output. Your terminal might support more escapes, or not support escape sequences that fish knows about. If -r or --right is given, add the padding after a string. If -c or --char is given, pad with CHAR instead of whitespace. The output is padded to the maximum width of all input strings. If -w or --width is given, use at least that. > string pad -w 10 abc abcdef abc abcdef > string pad --right --char=\u{1F41F} "fish are pretty" "rich. " fish are pretty rich. \u{1F41F}\u{1F41F}\u{1F41F}\u{1F41F} > string pad -w$COLUMNS (date) # Prints the current time on the right edge of the screen. SEE ALSO \u2022 The printf command can do simple padding, for example printf %10s\\n works like string pad -w10. \u2022 string length with the --visible option can be used to show what fish thinks the width is. string shorten [(-c | --char) CHARS] [(-m | --max) INTEGER] [-N | --no-newline] [-l | --left] [-q | --quiet] [STRING ...] string shorten truncates each STRING to the given visible width and adds an ellipsis to indicate it. "Visible width" means the width of all visible characters added together, excluding escape sequences and accounting for fish_emoji_width and fish_ambiguous_width. It is the amount of columns in a terminal the STRING occupies. The escape sequences reflect what fish knows about, and how it computes its output. Your terminal might support more escapes, or not support escape sequences that fish knows about. If -m or --max is given, truncate at the given width. Otherwise, the lowest non-zero width of all input strings is used. A max of 0 means no shortening takes place, all STRINGs are printed as-is. If -N or --no-newline is given, only the first line (or last line with --left) of each STRING is used, and an ellipsis is added if it was multiline. This only works for STRINGs being given as arguments, multiple lines given on stdin will be interpreted as separate STRINGs instead. If -c or --char is given, add CHAR instead of an ellipsis. This can also be empty or more than one character. If -l or --left is given, remove text from the left on instead, so this prints the longest suffix of the string that fits. With --no-newline, this will take from the last line instead of the first. If -q or --quiet is given, string shorten only runs for the return value - if anything would be shortened, it returns 0, else 1. The default ellipsis is \u2026. If fish thinks your system is incapable because of your locale, it will use ... instead. The return value is 0 if any shortening occured, 1 otherwise. > string shorten foo foobar # No width was given, we infer, and "foo" is the shortest. foo fo\u2026 > string shorten --char="..." foo foobar # The target width is 3 because of "foo", # and our ellipsis is 3 too, so we can't really show anything. # This is the default ellipsis if your locale doesn't allow "\u2026". foo ... > string shorten --char="" --max 4 abcdef 123456 # Leaving the char empty makes us not add an ellipsis # So this truncates at 4 columns: abcd 1234 > touch "a multiline"\\n"file" > for file in *; string shorten -N -- $file; end # Shorten the multiline file so we only show one line per file: a multiline\u2026 > ss -p | string shorten -m$COLUMNS -c "" # \`ss\` from Linux' iproute2 shows socket information, but prints extremely long lines. # This shortens input so it fits on the screen without overflowing lines. > git branch | string match -rg '^\\* (.*)' | string shorten -m20 # Take the current git branch and shorten it at 20 columns. # Here the branch is "builtin-path-with-expand" builtin-path-with-e\u2026 > git branch | string match -rg '^\\* (.*)' | string shorten -m20 --left # Taking 20 columns from the right instead: \u2026in-path-with-expand SEE ALSO \u2022 string's pad subcommand does the inverse of this command, adding padding to a specific width instead. \u2022 The printf command can do simple padding, for example printf %10s\\n works like string pad -w10. \u2022 string length with the --visible option can be used to show what fish thinks the width is. REPEAT SUBCOMMAND string repeat [(-n | --count) COUNT] [(-m | --max) MAX] [-N | --no-newline] [-q | --quiet] [STRING ...] string repeat repeats the STRING -n or --count times. The -m or --max option will limit the number of outputted characters (excluding the newline). This option can be used by itself or in conjunction with --count. If both --count and --max are present, max char will be outputed unless the final repeated string size is less than max, in that case, the string will repeat until count has been reached. Both --count and --max will accept a number greater than or equal to zero, in the case of zero, nothing will be outputed. If -N or --no-newline is given, the output won't contain a newline character at the end. Exit status: 0 if yielded string is not empty, 1 otherwise. Examples Repeat Examples > string repeat -n 2 'foo ' foo foo > echo foo | string repeat -n 2 foofoo > string repeat -n 2 -m 5 'foo' foofo > string repeat -m 5 'foo' foofo REPLACE SUBCOMMAND string replace [-a | --all] [-f | --filter] [-i | --ignore-case] [-r | --regex] [-q | --quiet] PATTERN REPLACEMENT [STRING ...] string replace is similar to string match but replaces non-overlapping matching substrings with a replacement string and prints the result. By default, PATTERN is treated as a literal substring to be matched. If -r or --regex is given, PATTERN is interpreted as a Perl-compatible regular expression, and REPLACEMENT can contain C-style escape sequences like t as well as references to capturing groups by number or name as $n or \${n}. If you specify the -f or --filter flag then each input string is printed only if a replacement was done. This is useful where you would otherwise use this idiom: a_cmd | string match pattern | string replace pattern new_pattern. You can instead just write a_cmd | string replace --filter pattern new_pattern. Exit status: 0 if at least one replacement was performed, or 1 otherwise. Replace Literal Examples > string replace is was 'blue is my favorite' blue was my favorite > string replace 3rd last 1st 2nd 3rd 1st 2nd last > string replace -a ' ' 'spaces to underscores' spaces_to_underscores Replace Regex Examples > string replace -r -a '[^\\d.]+' ' ' '0 one two 3.14 four 5x' 0 3.14 5 > string replace -r '(\\w+)\\s+(\\w+)' '$2 $1 $$' 'left right' right left $ > string replace -r '\\s*newline\\s*' '\\n' 'put a newline here' put a here SPLIT AND SPLIT0 SUBCOMMANDS string split [(-f | --fields) FIELDS] [(-m | --max) MAX] [-n | --no-empty] [-q | --quiet] [-r | --right] SEP [STRING ...] string split0 [(-f | --fields) FIELDS] [(-m | --max) MAX] [-n | --no-empty] [-q | --quiet] [-r | --right] [STRING ...] string split splits each STRING on the separator SEP, which can be an empty string. If -m or --max is specified, at most MAX splits are done on each STRING. If -r or --right is given, splitting is performed right-to-left. This is useful in combination with -m or --max. With -n or --no-empty, empty results are excluded from consideration (e.g. hello\\n\\nworld would expand to two strings and not three). Exit status: 0 if at least one split was performed, or 1 otherwise. Use -f or --fields to print out specific fields. FIELDS is a comma-separated string of field numbers and/or spans. Each field is one-indexed, and will be printed on separate lines. If a given field does not exist, then the command exits with status 1 and does not print anything, unless --allow-empty is used. See also the --delimiter option of the read command. string split0 splits each STRING on the zero byte (NUL). Options are the same as string split except that no separator is given. split0 has the important property that its output is not further split when used in a command substitution, allowing for the command substitution to produce elements containing newlines. This is most useful when used with Unix tools that produce zero bytes, such as find -print0 or sort -z. See split0 examples below. Examples > string split . example.com example com > string split -r -m1 / /usr/local/bin/fish /usr/local/bin fish > string split '' abc a b c > string split --allow-empty -f1,3-4,5 '' abcd a c d NUL Delimited Examples > # Count files in a directory, without being confused by newlines. > count (find . -print0 | string split0) 42 > # Sort a list of elements which may contain newlines > set foo beta alpha\\ngamma > set foo (string join0 $foo | sort -z | string split0) > string escape $foo[1] alpha\\ngamma SUB SUBCOMMAND string sub [(-s | --start) START] [(-e | --end) END] [(-l | --length) LENGTH] [-q | --quiet] [STRING ...] string sub prints a substring of each string argument. The start/end of the substring can be specified with -s/-e or --start/--end followed by a 1-based index value. Positive index values are relative to the start of the string and negative index values are relative to the end of the string. The default start value is 1. The length of the substring can be specified with -l or --length. If the length or end is not specified, the substring continues to the end of each STRING. Exit status: 0 if at least one substring operation was performed, 1 otherwise. --length is mutually exclusive with --end. Examples > string sub --length 2 abcde ab > string sub -s 2 -l 2 abcde bc > string sub --start=-2 abcde de > string sub --end=3 abcde abc > string sub -e -1 abcde abcd > string sub -s 2 -e -1 abcde bcd > string sub -s -3 -e -2 abcde c TRIM SUBCOMMAND string trim [-l | --left] [-r | --right] [(-c | --chars) CHARS] [-q | --quiet] [STRING ...] string trim removes leading and trailing whitespace from each STRING. If -l or --left is given, only leading whitespace is removed. If -r or --right is given, only trailing whitespace is trimmed. The -c or --chars switch causes the characters in CHARS to be removed instead of whitespace. Exit status: 0 if at least one character was trimmed, or 1 otherwise. Examples > string trim ' abc ' abc > string trim --right --chars=yz xyzzy zany x zan UPPER SUBCOMMAND string upper [-q | --quiet] [STRING ...] string upper converts each string argument to uppercase. Exit status: 0 if at least one string was converted to uppercase, else 1. This means that in conjunction with the -q flag you can readily test whether a string is already uppercase. REGULAR EXPRESSIONS Both the match and replace subcommand support regular expressions when used with the -r or --regex option. The dialect is that of PCRE2. In general, special characters are special by default, so a+ matches one or more "a"s, while a\\+ matches an "a" and then a "+". (a+) matches one or more "a"s in a capturing group ((?:XXXX) denotes a non-capturing group). For the replacement parameter of replace, $n refers to the n-th group of the match. In the match parameter, \\n (e.g. \\1) refers back to groups. Some features include repetitions: \u2022 * refers to 0 or more repetitions of the previous expression \u2022 + 1 or more \u2022 ? 0 or 1. \u2022 {n} to exactly n (where n is a number) \u2022 {n,m} at least n, no more than m. \u2022 {n,} n or more Character classes, some of the more important: \u2022 . any character except newline \u2022 \\d a decimal digit and \\D, not a decimal digit \u2022 \\s whitespace and \\S, not whitespace \u2022 \\w a "word" character and \\W, a "non-word" character \u2022 [...] (where "..." is some characters) is a character set \u2022 [^...] is the inverse of the given character set \u2022 [x-y] is the range of characters from x-y \u2022 [[:xxx:]] is a named character set \u2022 [[:^xxx:]] is the inverse of a named character set \u2022 [[:alnum:]] : "alphanumeric" \u2022 [[:alpha:]] : "alphabetic" \u2022 [[:ascii:]] : "0-127" \u2022 [[:blank:]] : "space or tab" \u2022 [[:cntrl:]] : "control character" \u2022 [[:digit:]] : "decimal digit" \u2022 [[:graph:]] : "printing, excluding space" \u2022 [[:lower:]] : "lower case letter" \u2022 [[:print:]] : "printing, including space" \u2022 [[:punct:]] : "printing, excluding alphanumeric" \u2022 [[:space:]] : "white space" \u2022 [[:upper:]] : "upper case letter" \u2022 [[:word:]] : "same as w" \u2022 [[:xdigit:]] : "hexadecimal digit" Groups: \u2022 (...) is a capturing group \u2022 (?:...) is a non-capturing group \u2022 \\n is a backreference (where n is the number of the group, starting with 1) \u2022 $n is a reference from the replacement expression to a group in the match expression. And some other things: \u2022 \\b denotes a word boundary, \\B is not a word boundary. \u2022 ^ is the start of the string or line, $ the end. \u2022 | is "alternation", i.e. the "or". COMPARISON TO OTHER TOOLS Most operations string supports can also be done by external tools. Some of these include grep, sed and cut. If you are familiar with these, it is useful to know how string differs from them. In contrast to these classics, string reads input either from stdin or as arguments. string also does not deal with files, so it requires redirections to be used with them. In contrast to grep, string's match defaults to glob-mode, while replace defaults to literal matching. If set to regex-mode, they use PCRE regular expressions, which is comparable to grep's -P option. match defaults to printing just the match, which is like grep with -o (use --entire to enable grep-like behavior). Like sed's s/old/new/ command, string replace still prints strings that don't match. sed's -n in combination with a /p modifier or command is like string replace -f. string split somedelimiter is a replacement for tr somedelimiter \\n.`,args:`string collect [-a | --allow-empty] [-N | --no-trim-newlines] [STRING ...] string escape [-n | --no-quoted] [--style=] [STRING ...] string join [-q | --quiet] [-n | --no-empty] SEP [STRING ...] string join0 [-q | --quiet] [STRING ...] string length [-q | --quiet] [STRING ...] string lower [-q | --quiet] [STRING ...] string match [-a | --all] [-e | --entire] [-i | --ignore-case] [-g | --groups-only] [-r | --regex] [-n | --index] [-q | --quiet] [-v | --invert] PATTERN [STRING ...] string pad [-r | --right] [(-c | --char) CHAR] [(-w | --width) INTEGER] [STRING ...] string repeat [(-n | --count) COUNT] [(-m | --max) MAX] [-N | --no-newline] [-q | --quiet] [STRING ...] string replace [-a | --all] [-f | --filter] [-i | --ignore-case] [-r | --regex] [-q | --quiet] PATTERN REPLACE [STRING ...] string shorten [(-c | --char) CHARS] [(-m | --max) INTEGER] [-N | --no-newline] [-l | --left] [-q | --quiet] [STRING ...] string split [(-f | --fields) FIELDS] [(-m | --max) MAX] [-n | --no-empty] [-q | --quiet] [-r | --right] SEP [STRING ...] string split0 [(-f | --fields) FIELDS] [(-m | --max) MAX] [-n | --no-empty] [-q | --quiet] [-r | --right] [STRING ...] string sub [(-s | --start) START] [(-e | --end) END] [(-l | --length) LENGTH] [-q | --quiet] [STRING ...] string trim [-l | --left] [-r | --right] [(-c | --chars) CHARS] [-q | --quiet] [STRING ...] string unescape [--style=] [STRING ...] string upper [-q | --quiet] [STRING ...]`},switch:{shortDescription:"conditionally execute a block of commands",description:`switch performs one of several blocks of commands, depending on whether a specified value equals one of several globbed values. case is used together with the switch statement in order to determine which block should be executed. Each case command is given one or more parameters. The first case command with a parameter that matches the string specified in the switch command will be evaluated. case parameters may contain globs. These need to be escaped or quoted in order to avoid regular glob expansion using filenames. Note that fish does not fall through on case statements. Only the first matching case is executed. Note that break cannot be used to exit a case/switch block early like in other languages. It can only be used in loops. Note that command substitutions in a case statement will be evaluated even if its body is not taken. All substitutions, including command substitutions, must be performed before the value can be compared against the parameter. EXAMPLE If the variable $animal contains the name of an animal, the following code would attempt to classify it: switch $animal case cat echo evil case wolf dog human moose dolphin whale echo mammal case duck goose albatross echo bird case shark trout stingray echo fish case '*' echo I have no idea what a $animal is end If the above code was run with $animal set to whale, the output would be mammal.`,args:"switch VALUE; [case [GLOB ...]; [COMMANDS ...]; ...] end"},test:{shortDescription:"Evaluate conditional expressions",description:"The `test` command evaluates conditional expressions and sets the exit status to 0 if the expression is true, and 1 if it is false. It supports various operators to evaluate expressions related to strings, numbers, and file attributes.",args:"EXPRESSION"},time:{shortDescription:"measure how long a command or block takes",description:`NOTE: This page documents the fish keyword time. To see the documentation on the time command you might have, use command man time. time causes fish to measure how long a command takes and print the results afterwards. The command can be a simple fish command or a block. The results can not currently be redirected. For checking timing after a command has completed, check $CMD_DURATION. Your system most likely also has a time command. To use that use something like command time, as in command time sleep 10. Because it's not inside fish, it won't have access to fish functions and won't be able to time blocks and such. HOW TO INTERPRET THE OUTPUT Time outputs a few different values. Let's look at an example: > time string repeat -n 10000000 y\\n | command grep y >/dev/null _______________________________________________________ Executed in 805.98 millis fish external usr time 798.88 millis 763.88 millis 34.99 millis sys time 141.22 millis 40.20 millis 101.02 millis The time after "Executed in" is what is known as the "wall-clock time". It is simply a measure of how long it took from the start of the command until it finished. Typically it is reasonably close to CMD_DURATION, except for a slight skew because the two are taken at slightly different times. The other times are all measures of CPU time. That means they measure how long the CPU was used in this part, and they count multiple cores separately. So a program with four threads using all CPU for a second will have a time of 4 seconds. The "usr" time is how much CPU time was spent inside the program itself, the "sys" time is how long was spent in the kernel on behalf of that program. The "fish" time is how much CPU was spent in fish, the "external" time how much was spent in external commands. So in this example, since string is a builtin, everything that string repeat did is accounted to fish. Any time it spends doing syscalls like write() is accounted for in the fish/sys time. And grep here is explicitly invoked as an external command, so its times will be counted in the "external" column. Note that, as in this example, the CPU times can add up to more than the execution time. This is because things can be done in parallel - grep can match while string repeat writes. EXAMPLE (for obvious reasons exact results will vary on your system) > time sleep 1s _______________________________________________________ Executed in 1,01 secs fish external usr time 2,32 millis 0,00 micros 2,32 millis sys time 0,88 millis 877,00 micros 0,00 millis > time for i in 1 2 3; sleep 1s; end _______________________________________________________ Executed in 3,01 secs fish external usr time 9,16 millis 2,94 millis 6,23 millis sys time 0,23 millis 0,00 millis 0,23 millis Inline variable assignments need to follow the time keyword: > time a_moment=1.5m sleep $a_moment _______________________________________________________ Executed in 90.00 secs fish external usr time 4.62 millis 4.62 millis 0.00 millis sys time 2.35 millis 0.41 millis 1.95 millis`,args:"time COMMAND"},true:{shortDescription:"Return a successful result",description:"The `true` command always returns a successful (zero) exit status. It is often used in scripts and conditional statements where an unconditional success result is needed."},type:{shortDescription:"locate a command and describe its type",description:`With no options, type indicates how each NAME would be interpreted if used as a command name. The following options are available: -a or --all Prints all of possible definitions of the specified names. -s or --short Suppresses function expansion when used with no options or with -a/--all. -f or --no-functions Suppresses function and builtin lookup. -t or --type Prints function, builtin, or file if NAME is a shell function, builtin, or disk file, respectively. -p or --path Prints the path to NAME if NAME resolves to an executable file in PATH, the path to the script containing the definition of the function NAME if NAME resolves to a function loaded from a file on disk (i.e. not interactively defined at the prompt), or nothing otherwise. -P or --force-path Returns the path to the executable file NAME, presuming NAME is found in the PATH environment variable, or nothing otherwise. --force-path explicitly resolves only the path to executable files in PATH, regardless of whether NAME is shadowed by a function or builtin with the same name. -q or --query Suppresses all output; this is useful when testing the exit status. For compatibility with old fish versions this is also --quiet. -h or --help Displays help about using this command. The -q, -p, -t and -P flags (and their long flag aliases) are mutually exclusive. Only one can be specified at a time. type returns 0 if at least one entry was found, 1 otherwise, and 2 for invalid options or option combinations. EXAMPLE > type fg fg is a builtin`,args:"type [OPTIONS] NAME [...]"},ulimit:{shortDescription:"set or get resource usage limits",description:`ulimit sets or outputs the resource usage limits of the shell and any processes spawned by it. If a new limit value is omitted, the current value of the limit of the resource is printed; otherwise, the specified limit is set to the new value. Use one of the following switches to specify which resource limit to set or report: -b or --socket-buffers The maximum size of socket buffers. -c or --core-size The maximum size of core files created. By setting this limit to zero, core dumps can be disabled. -d or --data-size The maximum size of a process' data segment. -e or --nice Controls the maximum nice value; on Linux, this value is subtracted from 20 to give the effective value. -f or --file-size The maximum size of files created by a process. -i or --pending-signals The maximum number of signals that may be queued. -l or --lock-size The maximum size that may be locked into memory. -m or --resident-set-size The maximum resident set size. -n or --file-descriptor-count The maximum number of open file descriptors. -q or --queue-size The maximum size of data in POSIX message queues. -r or --realtime-priority The maximum realtime scheduling priority. -s or --stack-size The maximum stack size. -t or --cpu-time The maximum amount of CPU time in seconds. -u or --process-count The maximum number of processes available to the current user. -w or --swap-size The maximum swap space available to the current user. -v or --virtual-memory-size The maximum amount of virtual memory available to the shell. -y or --realtime-maxtime The maximum contiguous realtime CPU time in microseconds. -K or --kernel-queues The maximum number of kqueues (kernel queues) for the current user. -P or --ptys The maximum number of pseudo-terminals for the current user. -T or --threads The maximum number of simultaneous threads for the current user. Note that not all these limits are available in all operating systems; consult the documentation for setrlimit in your operating system. The value of limit can be a number in the unit specified for the resource or one of the special values hard, soft, or unlimited, which stand for the current hard limit, the current soft limit, and no limit, respectively. If limit is given, it is the new value of the specified resource. If no option is given, then -f is assumed. Values are in kilobytes, except for -t, which is in seconds and -n and -u, which are unscaled values. The exit status is 0 unless an invalid option or argument is supplied, or an error occurs while setting a new limit. ulimit also accepts the following options that determine what type of limit to set: -H or --hard Sets hard resource limit. -S or --soft Sets soft resource limit. A hard limit can only be decreased. Once it is set it cannot be increased; a soft limit may be increased up to the value of the hard limit. If neither -H nor -S is specified, both the soft and hard limits are updated when assigning a new limit value, and the soft limit is used when reporting the current value. The following additional options are also understood by ulimit: -a or --all Prints all current limits. -h or --help Displays help about using this command. The fish implementation of ulimit should behave identically to the implementation in bash, except for these differences: \u2022 Fish ulimit supports GNU-style long options for all switches. \u2022 Fish ulimit does not support the -p option for getting the pipe size. The bash implementation consists of a compile-time check that empirically guesses this number by writing to a pipe and waiting for SIGPIPE. Fish does not do this because this method of determining pipe size is unreliable. Depending on bash version, there may also be further additional limits to set in bash that do not exist in fish. \u2022 Fish ulimit does not support getting or setting multiple limits in one command, except reporting all values using the -a switch. EXAMPLE ulimit -Hs 64 sets the hard stack size limit to 64 kB.`,args:"ulimit [OPTIONS] [LIMIT]"},wait:{shortDescription:"wait for jobs to complete",description:`wait waits for child jobs to complete. If a PID is specified, the command waits for the job that the process with that process ID belongs to. If a PROCESS_NAME is specified, the command waits for the jobs that the matched processes belong to. If neither a pid nor a process name is specified, the command waits for all background jobs. If the -n or --any flag is provided, the command returns as soon as the first job completes. If it is not provided, it returns after all jobs complete. The -h or --help option displays help about using this command. EXAMPLE sleep 10 & wait $last_pid spawns sleep in the background, and then waits until it finishes. for i in (seq 1 5); sleep 10 &; end wait spawns five jobs in the background, and then waits until all of them finishes. for i in (seq 1 5); sleep 10 &; end hoge & wait sleep spawns five jobs and hoge in the background, and then waits until all sleeps finish, and doesn't wait for hoge finishing.`,args:"wait [-n | --any] [PID | PROCESS_NAME] ..."},while:{shortDescription:"perform a set of commands multiple times",description:`while repeatedly executes CONDITION, and if the exit status is 0, then executes COMMANDS. The exit status of the while loop is the exit status of the last iteration of the COMMANDS executed, or 0 if none were executed. (This matches other shells and is POSIX-compatible.) You can use and or or for complex conditions. Even more complex control can be achieved with while true containing a break. The -h or --help option displays help about using this command. EXAMPLE while test -f foo.txt; or test -f bar.txt ; echo file exists; sleep 10; end # outputs 'file exists' at 10 second intervals, # as long as the file foo.txt or bar.txt exists.`,args:"while CONDITION; COMMANDS; end"}};var xn=gd(Xo);async function Jo(e,t){return[...await bd(e),...await ud(e)]}async function ud(e){let t=[];for(let n of[...xn.keys()])try{let i=fd(n);i?t.push({label:{label:n,description:i.description},detail:i.args,documentation:new _e.MarkdownString(i.documentation),kind:_e.TerminalCompletionItemKind.Method}):(console.warn(`Fish command "${n}" not found in cache.`),t.push({label:n,kind:_e.TerminalCompletionItemKind.Method}))}catch{t.push({label:n,kind:_e.TerminalCompletionItemKind.Method})}return t}function fd(e){if(!xn)return;let t=xn.get(e);if(t)return t.shortDescription?{description:t.shortDescription,args:t.args,documentation:t.description}:{description:t.description,args:t.args,documentation:t.description}}function gd(e){if(!e)return;let t=new Map;for(let[n,i]of Object.entries(e))t.set(n,i);return t}async function bd(e){return qe("fish",["-ic","alias"],/^alias (?[a-zA-Z0-9\.:-]+) (?.+)$/,e)}var re=H(require("vscode"));async function Tn(e,t){return[...await wd(e,t),...await vd(e,t)]}var yd=new Map([[1,re.TerminalCompletionItemKind.Alias],[2,re.TerminalCompletionItemKind.Method],[4,re.TerminalCompletionItemKind.Method],[8,re.TerminalCompletionItemKind.Method],[16,re.TerminalCompletionItemKind.Method],[32,re.TerminalCompletionItemKind.Method],[64,re.TerminalCompletionItemKind.Method],[256,re.TerminalCompletionItemKind.Argument]]);async function wd(e,t){let n=await we('Get-Command -CommandType Alias | Select-Object Name, CommandType, Definition, DisplayName, ModuleName, @{Name="Version";Expression={$_.Version.ToString()}} | ConvertTo-Json',{...e,maxBuffer:104857600}),i;try{i=JSON.parse(n)}catch(a){return console.error("Error parsing output:",a),[]}return Array.isArray(i)?i.filter(Zo).map(a=>{let o=a.Name!==a.DisplayName,s=[];a.Definition&&s.push(a.Definition),a.ModuleName&&a.Version&&s.push(`${a.ModuleName} v${a.Version}`);let r;if(a.Definition){let c=a.Definition.indexOf(" ");c===-1&&(c=a.Definition.length,r=a.Definition.substring(0,c))}return{label:a.Name,detail:s.join(` `),kind:o?re.TerminalCompletionItemKind.Alias:re.TerminalCompletionItemKind.Method,definitionCommand:r}}):[]}async function vd(e,t){let n=await we('Get-Command -All | Select-Object Name, CommandType, Definition, ModuleName, @{Name="Version";Expression={$_.Version.ToString()}} | ConvertTo-Json',{...e,maxBuffer:104857600}),i;try{i=JSON.parse(n)}catch(a){return console.error("Error parsing pwsh output:",a),[]}return Array.isArray(i)?i.filter(Zo).filter(a=>a.CommandType!==1).map(a=>{let o=[];return a.Definition&&o.push(a.Definition.trim()),a.ModuleName&&a.Version&&o.push(`${a.ModuleName} v${a.Version}`),{label:a.Name,detail:o.join(` `),kind:yd.get(a.CommandType)}}):[]}function Zo(e){return kd(e)&&"Name"in e&&typeof e.Name=="string"&&"CommandType"in e&&typeof e.CommandType=="number"&&(!("DisplayName"in e)||typeof e.DisplayName=="string"||e.DisplayName===null)&&(!("Definition"in e)||typeof e.Definition=="string"||e.Definition===null)&&(!("ModuleName"in e)||typeof e.ModuleName=="string"||e.ModuleName===null)&&(!("Version"in e)||typeof e.Version=="string"||e.Version===null)}function kd(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}var je=H(require("vscode"));var In={".":{shortDescription:"Source a file",description:`: Read commands from *file* and execute them in the current shell environment. If *file* does not contain a slash, or if **PATH_DIRS** is set, the shell looks in the components of **\\$path** to find the directory containing *file*. Files in the current directory are not read unless \`**.**\` appears somewhere in **\\$path**. If a file named \`*file***.zwc**\` is found, is newer than *file*, and is the compiled form (created with the **zcompile** builtin) of *file*, then commands are read from that file instead of *file*. If any arguments *arg* are given, they become the positional parameters; the old positional parameters are restored when the *file* is done executing. However, if no arguments are given, the positional parameters remain those of the calling context, and no restoring is done. If *file* was not found the return status is 127; if *file* was found but contained a syntax error the return status is 126; else the return status is the exit status of the last command executed.`,args:". file [ arg ... ]"},":":{shortDescription:"No effect",description:": This command does nothing, although normal argument expansions is performed which may have effects on shell parameters. A zero exit status is returned.",args:": [ arg ... ]"},alias:{shortDescription:"Define or view aliases",description:`: For each *name* with a corresponding *value*, define an alias with that value. A trailing space in *value* causes the next word to be checked for alias expansion. If the **-g** flag is present, define a global alias; global aliases are expanded even if they do not occur in command position: > % perldoc --help 2>&1 | grep 'built-in functions' > -f Search Perl built-in functions > % alias -g HG='--help 2>&1 | grep' > % perldoc HG 'built-in functions' > -f Search Perl built-in functions If the **-s** flag is present, define a suffix alias: if the command word on a command line is in the form \`*text***.***name*\`, where *text* is any non-empty string, it is replaced by the text \`*value* *text***.***name*\`. Note that *name* is treated as a literal string, not a pattern. A trailing space in *value* is not special in this case. For example, > alias -s ps='gv --' will cause the command \`**\\*.ps**\` to be expanded to \`**gv \\-- \\*.ps**\`. As alias expansion is carried out earlier than globbing, the \`**\\*.ps**\` will then be expanded. Suffix aliases constitute a different name space from other aliases (so in the above example it is still possible to create an alias for the command **ps**) and the two sets are never listed together. For each *name* with no *value*, print the value of *name*, if any. With no arguments, print all currently defined aliases other than suffix aliases. If the **-m** flag is given the arguments are taken as patterns (they should be quoted to preserve them from being interpreted as glob patterns), and the aliases matching these patterns are printed. When printing aliases and one of the **-g**, **-r** or **-s** flags is present, restrict the printing to global, regular or suffix aliases, respectively; a regular alias is one which is neither a global nor a suffix alias. Using \`**+**\` instead of \`**-**\`, or ending the option list with a single \`**+**\`, prevents the values of the aliases from being printed. If the **-L** flag is present, then print each alias in a manner suitable for putting in a startup script. The exit status is nonzero if a *name* (with no *value*) is given for which no alias has been defined. For more on aliases, include common problems, see the section ALIASING in *zshmisc*(1).`,args:"alias [ {+|-}gmrsL ] [ name[=value] ... ]"},autoload:{shortDescription:"Autoload a function",description:`: See the section \`Autoloading Functions\` in *zshmisc*(1) for full details. The **fpath** parameter will be searched to find the function definition when the function is first referenced. If *name* consists of an absolute path, the function is defined to load from the file given (searching as usual for dump files in the given location). The name of the function is the basename (non-directory part) of the file. It is normally an error if the function is not found in the given location; however, if the option **-d** is given, searching for the function defaults to **\\$fpath**. If a function is loaded by absolute path, any functions loaded from it that are marked for **autoload** without an absolute path have the load path of the parent function temporarily prepended to **\\$fpath**. If the option **-r** or **-R** is given, the function is searched for immediately and the location is recorded internally for use when the function is executed; a relative path is expanded using the value of **\\$PWD**. This protects against a change to **\\$fpath** after the call to **autoload**. With **-r**, if the function is not found, it is silently left unresolved until execution; with **-R**, an error message is printed and command processing aborted immediately the search fails, i.e. at the **autoload** command rather than at function execution.. The flag **-X** may be used only inside a shell function. It causes the calling function to be marked for autoloading and then immediately loaded and executed, with the current array of positional parameters as arguments. This replaces the previous definition of the function. If no function definition is found, an error is printed and the function remains undefined and marked for autoloading. If an argument is given, it is used as a directory (i.e. it does not include the name of the function) in which the function is to be found; this may be combined with the **-d** option to allow the function search to default to **\\$fpath** if it is not in the given location. The flag **+X** attempts to load each *name* as an autoloaded function, but does *not* execute it. The exit status is zero (success) if the function was not previously defined *and* a definition for it was found. This does *not* replace any existing definition of the function. The exit status is nonzero (failure) if the function was already defined or when no definition was found. In the latter case the function remains undefined and marked for autoloading. If ksh-style autoloading is enabled, the function created will contain the contents of the file plus a call to the function itself appended to it, thus giving normal ksh autoloading behaviour on the first call to the function. If the **-m** flag is also given each *name* is treated as a pattern and all functions already marked for autoload that match the pattern are loaded. With the **-t** flag, turn on execution tracing; with **-T**, turn on execution tracing only for the current function, turning it off on entry to any called functions that do not also have tracing enabled. With the **-U** flag, alias expansion is suppressed when the function is loaded. With the **-w** flag, the *name*s are taken as names of files compiled with the **zcompile** builtin, and all functions defined in them are marked for autoloading. The flags **-z** and **-k** mark the function to be autoloaded using the zsh or ksh style, as if the option **KSH_AUTOLOAD** were unset or were set, respectively. The flags override the setting of the option at the time the function is loaded. Note that the **autoload** command makes no attempt to ensure the shell options set during the loading or execution of the file have any particular value. For this, the **emulate** command can be used: > emulate zsh -c 'autoload -Uz func' arranges that when *func is loaded the shell is in native* **zsh** emulation, and this emulation is also applied when *func is run.* Some of the functions of **autoload** *are also provided by* **functions** -u *or* **functions -U***, but* **autoload** *is a more comprehensive* interface.`,args:"autoload [ {+|-}RTUXdkmrtWz ] [ -w ] [ name ... ]"},bg:{shortDescription:"Put a job in the background",description:"*job \\...* **&** Put each specified *job in the background,* or the current job if none is specified.",args:"bg [ job ... ]"},bindkey:{shortDescription:"Manipulate keymap names",description:": See the section `Zle Builtins` in *zshzle(1).*",args:"bindkey"},break:{shortDescription:"Exit from a loop",description:": Exit from an enclosing **for***,* **while***,* **until***,* **select** *or* **repeat** *loop. If an arithmetic expression n* is specified, then break *n levels instead of just one.*",args:"break [ n ]"},builtin:{shortDescription:"Executes a builtin",description:": Executes the builtin *name, with the given args.*",args:"builtin name [ args ... ]"},bye:{shortDescription:"Exit the shell",description:": Same as **exit***.*",args:"bye"},cap:{shortDescription:"Manipulating POSIX capability sets",description:": See the section `The zsh/cap Module` in *zshmodules(1).*",args:"cap"},cd:{shortDescription:"Change the current directory",description:"**cd** *\\[* **-qsLP** *\\] {***+***\\|***-***}n* Change the current directory. In the first form, change the current directory to *arg, or to the value of* **\\$HOME** *if* *arg is not specified. If arg is `***-***`, change to the* previous directory.\n\n> Otherwise, if *arg begins with a slash, attempt to change to the* directory given by *arg.*\n>\n> If *arg does not begin with a slash, the behaviour depends on whether* the current directory `**.***` occurs in the list of directories contained* in the shell parameter **cdpath***. If it does not, first attempt to change* to the directory *arg under the current directory, and if that fails* but **cdpath** *is set and contains at least one element attempt to change* to the directory *arg under each component of* **cdpath** *in turn until* successful. If `**.***` occurs in* **cdpath***, then* **cdpath** *is searched* strictly in order so that `**.***` is only tried at the appropriate point.*\n>\n> The order of testing **cdpath** *is modified if the option* **POSIX_CD** is set, as described in the documentation for the option.\n>\n> If no directory is found, the option **CDABLE_VARS** *is set, and a* parameter named *arg exists whose value begins with a slash, treat its* value as the directory. In that case, the parameter is added to the named directory hash table.\n>\n> The second form of **cd** *substitutes the string new* for the string *old in the name of the current directory,* and tries to change to this new directory.\n>\n> The third form of **cd** *extracts an entry from the directory* stack, and changes to that directory. An argument of the form `**+***n` identifies a stack entry by counting from the left* of the list shown by the **dirs** *command, starting with zero.* An argument of the form `**-***n` counts from the right.* If the **PUSHD_MINUS** *option is set, the meanings of `***+***`* and `**-***` in this context are swapped.* If the **POSIX_CD** *option is set, this form of* **cd** *is not recognised* and will be interpreted as the first form.\n>\n> If the **-q** *(quiet) option is specified, the hook function* **chpwd** and the functions in the array **chpwd_functions** *are not called.* This is useful for calls to **cd** *that do not change the environment* seen by an interactive user.\n>\n> If the **-s** *option is specified,* **cd** *refuses to change the current* directory if the given pathname contains symlinks. If the **-P** *option* is given or the **CHASE_LINKS** *option is set, symbolic links are resolved* to their true values. If the **-L** *option is given symbolic links are* retained in the directory (and not resolved) regardless of the state of the **CHASE_LINKS** *option.*",args:`cd [ -qsLP ] [ arg ] cd [ -qsLP ] old new`},chdir:{shortDescription:"Change the current directory",description:": Same as **cd***.*",args:"chdir"},clone:{shortDescription:"Clone shell onto another terminal",description:": See the section `The zsh/clone Module` in *zshmodules(1).*",args:"clone"},command:{shortDescription:"Execute a command",description:": The simple command argument is taken as an external command instead of a function or builtin and is executed. If the **POSIX_BUILTINS** *option* is set, builtins will also be executed but certain special properties of them are suppressed. The **-p** *flag causes a default path to be* searched instead of that in **\\$path***. With the* **-v** *flag,* **command** is similar to **whence** *and with* **-V***, it is equivalent to* **whence** -v*.*\n\n See also the section `Precommand Modifiers` in *zshmisc(1).*",args:"command [ -pvV ] simple command"},comparguments:{shortDescription:"Complete arguments",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"comparguments"},compcall:{shortDescription:"Complete call",description:": See the section `The zsh/compctl Module` in *zshmodules(1).*",args:"compcall"},compctl:{shortDescription:"Complete control",description:": See the section `The zsh/compctl Module` in *zshmodules(1).*",args:"compctl"},compdescribe:{shortDescription:"Complete describe",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"compdescribe"},compfiles:{shortDescription:"Complete files",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"compfiles"},compgroups:{shortDescription:"Complete groups",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"compgroups"},compquote:{shortDescription:"Complete quote",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"compquote"},comptags:{shortDescription:"Complete tags",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"comptags"},comptry:{shortDescription:"Complete try",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"comptry"},compvalues:{shortDescription:"Complete values",description:": See the section `The zsh/computil Module` in *zshmodules(1).*",args:"compvalues"},continue:{shortDescription:"Resume the next loop iteration",description:": Resume the next iteration of the enclosing **for***,* **while***,* **until***,* **select** *or* **repeat** *loop. If an arithmetic expression n is specified, break out of* *n-1 loops and resume at the nth enclosing loop.*",args:"continue [ n ]"},declare:{shortDescription:"Set or display parameter attributes/values",description:": Same as **typeset***.*",args:"declare"},dirs:{shortDescription:"Interact with directory stack",description:`**dirs** *\\[* **-lpv** *\\]* With no arguments, print the contents of the directory stack. Directories are added to this stack with the **pushd** *command,* and removed with the **cd** *or* **popd** *commands.* If arguments are specified, load them onto the directory stack, replacing anything that was there, and push the current directory onto the stack. > **-c** clear the directory stack. > > **-l** > > : print directory names in full instead of using of using **\\~** *expressions (see Dynamic and Static named directories in zshexpn(1)).* > > **-p** > > : print directory entries one per line. > > **-v** > > : number the directories in the stack when printing.`,args:"dirs [ -c ] [ arg ... ]"},disable:{shortDescription:"Disable shell features",description:`: Temporarily disable the *named hash table elements or patterns. The default* is to disable builtin commands. This allows you to use an external command with the same name as a builtin command. The **-a** *option* causes **disable** *to act on regular or global aliases. The* **-s** option causes **disable** *to act on suffix aliases. The* **-f** *option causes* **disable** *to act on shell functions. The* **-r** *options causes* **disable** *to act on reserved words. Without arguments all disabled* hash table elements from the corresponding hash table are printed. With the **-m** *flag the arguments are taken as patterns (which should be* quoted to prevent them from undergoing filename expansion), and all hash table elements from the corresponding hash table matching these patterns are disabled. Disabled objects can be enabled with the **enable** command. With the option **-p***, name \\... refer to elements of the* shell\\'s pattern syntax as described in the section \`Filename Generation\`. Certain elements can be disabled separately, as given below. Note that patterns not allowed by the current settings for the options **EXTENDED_GLOB***,* **KSH_GLOB** *and* **SH_GLOB** *are never enabled, regardless of the* setting here. For example, if **EXTENDED_GLOB** *is not active,* the pattern **\\^** *is ineffective even if \`***disable -p \\"\\^\\"***\` has* not been issued. The list below indicates any option settings that restrict the use of the pattern. It should be noted that setting **SH_GLOB** *has a wider effect than merely disabling patterns* as certain expressions, in particular those involving parentheses, are parsed differently. The following patterns may be disabled; all the strings need quoting on the command line to prevent them from being interpreted immediately as patterns and the patterns are shown below in single quotes as a reminder. **\\'?\\'** The pattern character **?** *wherever it occurs, including when preceding* a parenthesis with **KSH_GLOB***.* **\\'\\*\\'** : The pattern character **\\*** *wherever it occurs, including recursive* globbing and when preceding a parenthesis with **KSH_GLOB***.* **\\'\\[\\'** : Character classes. **\\'\\<\\'** *(***NO_SH_GLOB***)* : Numeric ranges. **\\'\\|\\'** *(***NO_SH_GLOB***)* : Alternation in grouped patterns, case statements, or KSH_GLOB parenthesised expressions. **\\'(\\'** *(***NO_SH_GLOB***)* : Grouping using single parentheses. Disabling this does not disable the use of parentheses for **KSH_GLOB** *where they are introduced by a* special character, nor for glob qualifiers (use \`**setopt** NO_BARE_GLOB_QUAL*\` to disable glob qualifiers that use parentheses* only). **\\'\\~\\'** *(***EXTENDED_GLOB***)* : Exclusion in the form *A***\\~***B.* **\\'\\^\\'** *(***EXTENDED_GLOB***)* : Exclusion in the form *A***\\^***B.* **\\'#\\'** *(***EXTENDED_GLOB***)* : The pattern character **\\#** *wherever it occurs, both for* repetition of a previous pattern and for indicating globbing flags. **\\'?(\\'** *(***KSH_GLOB***)* : The grouping form **?(***\\...***)***. Note this is also* disabled if **\\'?\\'** *is disabled.* **\\'\\*(\\'** *(***KSH_GLOB***)* : The grouping form **\\*(***\\...***)***. Note this is also* disabled if **\\'\\*\\'** *is disabled.* **\\'+(\\'** *(***KSH_GLOB***)* : The grouping form **+(***\\...***)***.* **\\'!(\\'** *(***KSH_GLOB***)* : The grouping form **!(***\\...***)***.* **\\'@(\\'** *(***KSH_GLOB***)* : The grouping form **@(***\\...***)***.*`,args:"disable [ -afmprs ] name ..."},disown:{shortDescription:"Remove job from job table",description:`*job \\...* **&\\|** *job \\...* **&!** Remove the specified *jobs from the job table; the shell will* no longer report their status, and will not complain if you try to exit an interactive shell with them running or stopped. If no *job is specified, disown the current job.* > If the *jobs are currently stopped and the* **AUTO_CONTINUE** *option* is not set, a warning is printed containing information about how to make them running after they have been disowned. If one of the latter two forms is used, the *jobs will automatically be made running,* independent of the setting of the **AUTO_CONTINUE** *option.*`,args:"disown [ job ... ]"},echo:{shortDescription:"Write on standard output",description:`: Write each *arg on the standard output, with a space separating* each one. If the **-n** *flag is not present, print a newline at the end.* **echo** *recognizes the following escape sequences:* **\\\\a** : bell character **\\\\b** : backspace **\\\\c** : suppress subsequent characters and final newline **\\\\e** : escape **\\\\f** : form feed **\\\\n** : linefeed (newline) **\\\\r** : carriage return **\\\\t** : horizontal tab **\\\\v** : vertical tab **\\\\\\\\** : backslash **\\\\0***NNN* : character code in octal **\\\\x***NN* : character code in hexadecimal **\\\\u***NNNN* : unicode character code in hexadecimal **\\\\U***NNNNNNNN* : unicode character code in hexadecimal The **-E** *flag, or the* **BSD_ECHO** *option, can be used to disable* these escape sequences. In the latter case, **-e** *flag can be used to* enable them. Note that for standards compliance a double dash does not terminate option processing; instead, it is printed directly. However, a single dash does terminate option processing, so the first dash, possibly following options, is not printed, but everything following it is printed as an argument. The single dash behaviour is different from other shells. For a more portable way of printing text, see **printf***, and for a more controllable way of printing text within zsh,* see **print***.*`,args:"echo [ -neE ] [ arg ... ]"},echotc:{shortDescription:"Echo terminal capabilities",description:": See the section `The zsh/termcap Module` in *zshmodules(1).*",args:"echotc"},echoti:{shortDescription:"Echo terminal info",description:": See the section `The zsh/terminfo Module` in *zshmodules(1).*",args:"echoti"},emulate:{shortDescription:"Emulate a shell",description:`: Without any argument print current emulation mode. With single argument set up zsh options to emulate the specified shell as much as possible. **csh** *will never be fully emulated.* If the argument is not one of the shells listed above, **zsh** will be used as a default; more precisely, the tests performed on the argument are the same as those used to determine the emulation at startup based on the shell name, see the section COMPATIBILITY in *zsh(1)* . In addition to setting shell options, the command also restores the pristine state of pattern enables, as if all patterns had been enabled using **enable -p***.* If the **emulate** *command occurs inside a function that has been* marked for execution tracing with **functions -t** *then the* **xtrace** option will be turned on regardless of emulation mode or other options. Note that code executed inside the function by the **.***,* **source***, or* **eval** *commands is not considered to be running directly from the* function, hence does not provoke this behaviour. If the **-R** *switch is given, all settable options* are reset to their default value corresponding to the specified emulation mode, except for certain options describing the interactive environment; otherwise, only those options likely to cause portability problems in scripts and functions are altered. If the **-L** *switch is given,* the options **LOCAL_OPTIONS***,* **LOCAL_PATTERNS** *and* **LOCAL_TRAPS** will be set as well, causing the effects of the **emulate** *command and any* **setopt***,* **disable -p** *or* **enable -p***, and* **trap** *commands to be local to* the immediately surrounding shell function, if any; normally these options are turned off in all emulation modes except **ksh***. The* **-L** *switch is mutually exclusive with the* use of **-c** *in flags.* If there is a single argument and the **-l** *switch is given, the* options that would be set or unset (the latter indicated with the prefix \`**no***\`) are listed.* **-l** *can be combined with* **-L** *or* **-R** *and* the list will be modified in the appropriate way. Note the list does not depend on the current setting of options, i.e. it includes all options that may in principle change, not just those that would actually change. The *flags may be any of the invocation-time flags described in* the section INVOCATION in *zsh(1),* except that \`**-o EMACS***\` and \`***-o VI***\` may not be used. Flags such* as \`**+r***\`/\`***+o RESTRICTED***\` may be prohibited in some circumstances.* If **-c** *arg appears in flags, arg is evaluated while the* requested emulation is temporarily in effect. In this case the emulation mode and all options are restored to their previous values before **emulate** *returns. The* **-R** *switch may precede the name of the shell* to emulate; note this has a meaning distinct from including **-R** *in* *flags.* Use of **-c** *enables \`sticky\` emulation mode for functions defined* within the evaluated expression: the emulation mode is associated thereafter with the function so that whenever the function is executed the emulation (respecting the **-R** *switch, if present) and all* options are set (and pattern disables cleared) before entry to the function, and the state is restored after exit. If the function is called when the sticky emulation is already in effect, either within an \`**emulate** *shell* **-c***\` expression or* within another function with the same sticky emulation, entry and exit from the function do not cause options to be altered (except due to standard processing such as the **LOCAL_OPTIONS** *option). This also* applies to functions marked for autoload within the sticky emulation; the appropriate set of options will be applied at the point the function is loaded as well as when it is run. For example: > emulate sh -c 'fni() { setopt cshnullglob; } > fno() { fni; }' > fno The two functions **fni** *and* **fno** *are defined with sticky* **sh** emulation. **fno** *is then executed, causing options associated* with emulations to be set to their values in **sh***.* **fno** *then* calls **fni***; because* **fni** *is also marked for sticky* **sh** emulation, no option changes take place on entry to or exit from it. Hence the option **cshnullglob***, turned off by* **sh** *emulation, will* be turned on within **fni** *and remain on return to* **fno***. On exit* from **fno***, the emulation mode and all options will be restored to the* state they were in before entry to the temporary emulation. The documentation above is typically sufficient for the intended purpose of executing code designed for other shells in a suitable environment. More detailed rules follow. 1\\. : The sticky emulation environment provided by \`**emulate** *shell* **-c***\` is identical to that provided by entry to* a function marked for sticky emulation as a consequence of being defined in such an environment. Hence, for example, the sticky emulation is inherited by subfunctions defined within functions with sticky emulation. 2\\. : No change of options takes place on entry to or exit from functions that are not marked for sticky emulation, other than those that would normally take place, even if those functions are called within sticky emulation. 3\\. : No special handling is provided for functions marked for **autoload** *nor for functions present in wordcode created by* the **zcompile** *command.* 4\\. : The presence or absence of the **-R** *switch to* **emulate** corresponds to different sticky emulation modes, so for example \`**emulate sh -c***\`, \`***emulate -R sh -c***\` and \`***emulate csh -c***\`* are treated as three distinct sticky emulations. 5\\. : Difference in shell options supplied in addition to the basic emulation also mean the sticky emulations are different, so for example \`**emulate zsh -c***\` and \`***emulate zsh -o cbases -c***\` are* treated as distinct sticky emulations.`,args:"emulate [ -lLR ] [ {zsh|sh|ksh|csh} [ flags ... ] ]"},enable:{shortDescription:"Enable shell features",description:': Enable the *named hash table elements, presumably disabled* earlier with **disable***. The default is to enable builtin commands.* The **-a** *option causes* **enable** *to act on regular or global aliases.* The **-s** *option causes* **enable** *to act on suffix aliases.* The **-f** *option causes* **enable** *to act on shell functions. The* **-r** option causes **enable** *to act on reserved words. Without arguments* all enabled hash table elements from the corresponding hash table are printed. With the **-m** *flag the arguments are taken as patterns* (should be quoted) and all hash table elements from the corresponding hash table matching these patterns are enabled. Enabled objects can be disabled with the **disable** *builtin command.*\n\n **enable -p** *reenables patterns disabled with* **disable -p***. Note* that it does not override globbing options; for example, `**enable -p** \\"\\~\\"*` does not cause the pattern character* **\\~** *to be active unless* the **EXTENDED_GLOB** *option is also set. To enable all possible* patterns (so that they may be individually disabled with **disable -p***),* use `**setopt EXTENDED_GLOB KSH_GLOB NO_SH_GLOB***`.*',args:"enable [ -afmprs ] name ..."},eval:{shortDescription:"Execute arguments in shell",description:": Read the arguments as input to the shell and execute the resulting command(s) in the current shell process. The return status is the same as if the commands had been executed directly by the shell; if there are no *args or they contain no commands (i.e. are* an empty string or whitespace) the return status is zero.",args:"eval [ arg ... ]"},exec:{shortDescription:"Replace shell with command",description:`: Replace the current shell with *command rather than forking.* If *command is a shell builtin command or a shell function,* the shell executes it, and exits when the command is complete. With **-c** *clear the environment; with* **-l** *prepend* **-** *to the* **argv\\[0\\]** *string of the command executed (to simulate a login shell);* with **-a** *argv0 set the* **argv\\[0\\]** *string of the command* executed. See the section \`Precommand Modifiers\` in *zshmisc(1).* If the option **POSIX_BUILTINS** *is set, command is never* interpreted as a shell builtin command or shell function. This means further precommand modifiers such as **builtin** *and* **noglob** *are also not interpreted within the shell. Hence* *command is always found by searching the command path.* If *command is omitted but any redirections are specified,* then the redirections will take effect in the current shell.`,args:"exec [ -cl ] [ -a argv0 ] [ command [ arg ... ] ]"},exit:{shortDescription:"Exit the shell",description:`: Exit the shell with the exit status specified by an arithmetic expression *n; if none* is specified, use the exit status from the last command executed. An EOF condition will also cause the shell to exit, unless the **IGNORE_EOF** *option is set.* See notes at the end of the section JOBS in *zshmisc(1) for some possibly unexpected interactions* of the **exit** *command with jobs.*`,args:"exit [ n ]"},export:{shortDescription:"Export to environment",description:": The specified *names are marked for automatic export* to the environment of subsequently executed commands. Equivalent to **typeset -gx***.* If a parameter specified does not already exist, it is created in the global scope.",args:"export [ name[=value] ... ]"},false:{shortDescription:"Return exit status of 1",description:": Do nothing and return an exit status of 1.",args:"false [ arg ... ]"},fc:{shortDescription:"Fix command",description:`**fc** **-ARWI** *\\[ filename \\]* The **fc** *command controls the interactive history mechanism. Note* that reading and writing of history options is only performed if the shell is interactive. Usually this is detected automatically, but it can be forced by setting the **interactive** *option when starting the* shell. > The first two forms of this command select a range of events from *first to last from the history list. The arguments first* and *last may be specified as a number or as a string. A negative* number is used as an offset to the current history event number. A string specifies the most recent event beginning with the given string. All substitutions *old***=***new, if any, are then performed on the* text of the events. > > The range of events selected by numbers can be narrowed further by the following flags. > > **-I** > > : restricts to only internal events (not from **\\$HISTFILE***)* > > **-L** > > : restricts to only local events (not from other shells, see **SHARE_HISTORY** *in zshoptions(1) \\-- note that* **\\$HISTFILE** *is* considered local when read at startup) > > **-m** > > : takes the first argument as a pattern (which should be quoted) and only the history events matching this pattern are considered > > If *first is not specified, it will be set to -1 (the most recent* event), or to -16 if the **-l** *flag is given.* If *last is not specified, it will be set to first,* or to -1 if the **-l** *flag is given.* However, if the current event has added entries to the history with \`**print -s***\` or \`***fc -R***\`, then the default last for* **-l** includes all new history entries since the current event began. > > When the **-l** *flag is given, the resulting events are listed on* standard output. Otherwise the editor program specified by **-e** *ename* is invoked on a file containing these history events. If **-e** *is not given, the* value of the parameter **FCEDIT** *is used; if that is not set the value of* the parameter **EDITOR** *is used; if that is not set a builtin default,* usually \`**vi***\` is used. If ename is \`***-***\`, no editor is invoked.* When editing is complete, the edited command is executed. > > The flag \`**-s***\` is equivalent to \`***-e -***\`.* The flag **-r** *reverses the order of the events and the* flag **-n** *suppresses event numbers when listing.* > > Also when listing, > > **-d** > > : prints timestamps for each event > > **-f** > > : prints full time-date stamps in the US \`*MM***/***DD***/***YY hh***:***mm\` format* > > **-E** > > : prints full time-date stamps in the European \`*dd***.***mm***.***yyyy hh***:***mm\` format* > > **-i** > > : prints full time-date stamps in ISO8601 \`*yyyy***-***mm***-***dd hh***:***mm\` format* > > **-t** *fmt* > > : prints time and date stamps in the given format; *fmt is formatted with the strftime function with the zsh extensions* described for the **%D{***string***}** *prompt format in* the section EXPANSION OF PROMPT SEQUENCES in *zshmisc(1). The resulting formatted string must be* no more than 256 characters or will not be printed > > > > **-D** > > : prints elapsed times; may be combined with one of the options above > > \`**fc -p***\` pushes the current history list onto a stack and switches to a* new history list. If the **-a** *option is also specified, this history list* will be automatically popped when the current function scope is exited, which is a much better solution than creating a trap function to call \`**fc -P***\`* manually. If no arguments are specified, the history list is left empty, **\\$HISTFILE** *is unset, and* **\\$HISTSIZE** *&* **\\$SAVEHIST** *are set to their* default values. If one argument is given, **\\$HISTFILE** *is set to that* filename, **\\$HISTSIZE** *&* **\\$SAVEHIST** *are left unchanged, and the history* file is read in (if it exists) to initialize the new list. If a second argument is specified, **\\$HISTSIZE** *&* **\\$SAVEHIST** *are instead set to the* single specified numeric value. Finally, if a third argument is specified, **\\$SAVEHIST** *is set to a separate value from* **\\$HISTSIZE***. You are free to* change these environment values for the new history list however you desire in order to manipulate the new history list. > > \`**fc -P***\` pops the history list back to an older list saved by \`***fc -p***\`.* The current list is saved to its **\\$HISTFILE** *before it is destroyed* (assuming that **\\$HISTFILE** *and* **\\$SAVEHIST** *are set appropriately, of* course). The values of **\\$HISTFILE***,* **\\$HISTSIZE***, and* **\\$SAVEHIST** *are* restored to the values they had when \`**fc -p***\` was called. Note that this* restoration can conflict with making these variables \\"local\\", so your best bet is to avoid local declarations for these variables in functions that use \`**fc -p***\`. The one other guaranteed-safe combination is declaring these* variables to be local at the top of your function and using the automatic option (**-a***) with \`***fc -p***\`. Finally, note that it is legal to manually* pop a push marked for automatic popping if you need to do so before the function exits. > > \`**fc -R***\` reads the history from the given file,* \`**fc -W***\` writes the history out to the given file,* and \`**fc -A***\` appends the history out to the given file.* If no filename is specified, the **\\$HISTFILE** *is assumed.* If the **-I** *option is added to* **-R***, only those events that are* not already contained within the internal history list are added. If the **-I** *option is added to* **-A** *or* **-W***, only those* events that are new since last incremental append/write to the history file are appended/written. In any case, the created file will have no more than **\\$SAVEHIST** entries.`,args:"fc -P"},fg:{shortDescription:"Put a job in the foreground",description:"*job \\...* Bring each specified *job in turn to the foreground.* If no *job is specified, resume the current job.*",args:"fg [ job ... ]"},float:{shortDescription:"Floating point arithmetic",description:": Equivalent to **typeset -E***, except that options irrelevant to floating* point numbers are not permitted.",args:"float [ {+|-}Hghlprtux ] [ {+|-}EFLRZ [ n ] ] [ name[=value] ... ]"},functions:{shortDescription:"List functions",description:`**functions -c** *oldfn newfn* **functions -M** *\\[***-s***\\] mathfn \\[ min \\[ max \\[ shellfn \\] \\] \\]* **functions -M** *\\[* **-m** *pattern \\... \\]* **functions +M** *\\[* **-m** *\\] mathfn \\...* Equivalent to **typeset -f***, with the exception of the* **-c***,* **-x***,* **-M** *and* **-W** *options. For* **functions -u** *and* **functions -U***,* see **autoload***, which provides additional options. For* **functions -t** and **functions -T***, see* **typeset -f***.* > The **-x** *option indicates that any functions output will have* each leading tab for indentation, added by the shell to show syntactic structure, expanded to the given number *num of spaces. num* can also be 0 to suppress all indentation. > > The **-W** *option turns on the option* **WARN_NESTED_VAR** *for the named* function or functions only. The option is turned off at the start of nested functions (apart from anonoymous functions) unless the called function also has the **-W** *attribute.* > > The **-c** *option causes oldfn to be copied to newfn. The* copy is efficiently handled internally by reference counting. If *oldfn was marked for autoload it is first loaded and if this* fails the copy fails. Either function may subsequently be redefined without affecting the other. A typical idiom is that *oldfn is the* name of a library shell function which is then redefined to call **newfn***, thereby installing a modified version of the function.* > > *The* **-M** *and* **+M** *flags* > > Use of the **-M** *option may not be combined with any of the options* handled by **typeset -f***.* > > **functions -M** *mathfn defines mathfn as the name of* a mathematical function recognised in all forms of arithmetical expressions; see the section \`Arithmetic Evaluation\` in *zshmisc(1). By default mathfn may take* any number of comma-separated arguments. If *min is given,* it must have exactly *min args; if min and max are* both given, it must have at least *min and at most max* args. *max may be -1 to indicate that there is no upper limit.* > > By default the function is implemented by a shell function of the same name; if *shellfn is specified it gives the name of the corresponding* shell function while *mathfn remains the name used in arithmetical* expressions. The name of the function in **\\$0** *is mathfn (not* *shellfn as would usually be the case), provided the option* **FUNCTION_ARGZERO** *is in effect. The positional parameters in the shell* function correspond to the arguments of the mathematical function call. > > The result of the last arithmetical expression evaluated inside the shell function gives the result of the mathematical function. This is not limited to arithmetic substitutions of the form **\\$((***\\...***))***,* but also includes arithmetical expressions evaluated in any other way, including by the **let** *builtin,* by **((***\\...***))** *statements,* and even by the **return** *builtin* and by array subscripts. Therefore, care must be taken not to use syntactical constructs that perform arithmetic evaluation after evaluating what is to be the result of the function. For example: > > > # WRONG > > zmath_cube() { > > (( $1 * $1 * $1 )) > > return 0 > > } > > functions -M cube 1 1 zmath_cube > > print $(( cube(3) )) > > This will print \`**0***\` because of the* **return***.* > > Commenting the **return** *out would lead to a different problem: the* **((***\\...***))** *statement would become* the last statement in the function, so the *return status (***\\$?***) of the* function would be non-zero (indicating failure) whenever the *arithmetic* result *of the function would happen to be zero (numerically):* > > > # WRONG > > zmath_cube() { > > (( $1 * $1 * $1 )) > > } > > functions -M cube 1 1 zmath_cube > > print $(( cube(0) )) > > Instead, the **true** *builtin can be used:* > > > # RIGHT > > zmath_cube() { > > (( $1 * $1 * $1 )) > > true > > } > > functions -M cube 1 1 zmath_cube > > print $(( cube(3) )) > > If the additional option **-s** *is given to* **functions -M***, the* argument to the function is a single string: anything between the opening and matching closing parenthesis is passed to the function as a single argument, even if it includes commas or white space. The minimum and maximum argument specifiers must therefore be 1 if given. An empty argument list is passed as a zero-length string. Thus, the following string function takes a single argument, including the commas, and prints 11: > > > stringfn() { (( $#1 )); true } > > functions -Ms stringfn > > print $(( stringfn(foo,bar,rod) )) > > **functions -M** *with no arguments lists all such user-defined functions in* the same form as a definition. With the additional option **-m** *and* a list of arguments, all functions whose *mathfn matches one of* the pattern arguments are listed. > > **function +M** *removes the list of mathematical functions; with the* additional option **-m** *the arguments are treated as patterns and* all functions whose *mathfn matches the pattern are removed. Note* that the shell function implementing the behaviour is not removed (regardless of whether its name coincides with *mathfn).*`,args:"functions [ {+|-}UkmtTuWz ] [ -x num ] [ name ... ]"},getcap:{shortDescription:"Get capabilities",description:": See the section `The zsh/cap Module` in *zshmodules(1).*",args:"getcap"},getln:{shortDescription:"Get line from buffer",description:": Read the top value from the buffer stack and put it in the shell parameter *name. Equivalent to* **read -zr***.*",args:"getln [ -AclneE ] name ..."},getopts:{shortDescription:"Parse positional parameters",description:": Checks the *args for legal options. If the args are omitted,* use the positional parameters. A valid option argument begins with a `**+***` or a `***-***`. An argument not beginning with* a `**+***` or a `***-***`, or the argument `***--***`, ends the options.* Note that a single `**-***` is not considered a valid option argument.* *optstring contains the letters that* **getopts** recognizes. If a letter is followed by a `**:***`, that option* requires an argument. The options can be separated from the argument by blanks.\n\n Each time it is invoked, **getopts** *places the option letter it finds* in the shell parameter *name, prepended with a `***+***` when* *arg begins with a `***+***`. The index of the next arg* is stored in **OPTIND***. The option argument, if any,* is stored in **OPTARG***.*\n\n The first option to be examined may be changed by explicitly assigning to **OPTIND***.* **OPTIND** *has an initial value of* **1***, and is* normally set to **1** *upon entry to a shell function and restored* upon exit. (The **POSIX_BUILTINS** *option disables this, and also changes* the way the value is calculated to match other shells.) **OPTARG** is not reset and retains its value from the most recent call to **getopts***. If either of* **OPTIND** *or* **OPTARG** *is explicitly* unset, it remains unset, and the index or option argument is not stored. The option itself is still stored in *name in this case.*\n\n A leading `**:***` in optstring causes* **getopts** *to store the* letter of any invalid option in **OPTARG***, and to set name to* `**?***` for an unknown option and to `***:***` when a required argument is* missing. Otherwise, **getopts** *sets name to `***?***` and prints* an error message when an option is invalid. The exit status is nonzero when there are no more options.",args:"getopts optstring name [ arg ... ]"},hash:{shortDescription:"Remember command locations",description:`: **hash** *can be used to directly modify the contents of the command* hash table, and the named directory hash table. Normally one would modify these tables by modifying one\\'s **PATH** (for the command hash table) or by creating appropriate shell parameters (for the named directory hash table). The choice of hash table to work on is determined by the **-d** *option;* without the option the command hash table is used, and with the option the named directory hash table is used. A command *name starting with a* **/** *is never hashed, whether by* explicit use of the **hash** *command or otherwise. Such a command* is always found by direct look up in the file system. Given no arguments, and neither the **-r** *or* **-f** *options,* the selected hash table will be listed in full. The **-r** *option causes the selected hash table to be emptied.* It will be subsequently rebuilt in the normal fashion. The **-f** *option causes the selected hash table to be fully* rebuilt immediately. For the command hash table this hashes all the absolute directories in the **PATH***,* and for the named directory hash table this adds all users\\' home directories. These two options cannot be used with any arguments. The **-m** *option causes the arguments to be taken as patterns* (which should be quoted) and the elements of the hash table matching those patterns are printed. This is the only way to display a limited selection of hash table elements. For each *name with a corresponding value, put \`name\` in* the selected hash table, associating it with the pathname \`*value\`.* In the command hash table, this means that whenever \`*name\` is used as a command argument, the shell will try* to execute the file given by \`*value\`.* In the named directory hash table, this means that \`*value\` may be referred to as \`***\\~***name\`.* For each *name with no* corresponding *value, attempt to add name to the hash table,* checking what the appropriate **value** *is in the normal manner for* that hash table. If an appropriate **value** *can\\'t be found, then* the hash table will be unchanged. The **-v** *option causes hash table entries to be listed as they are* added by explicit specification. If has no effect if used with **-f***.* If the **-L** *flag is present, then each hash table entry is printed in* the form of a call to hash.`,args:"hash [ -Ldfmrv ] [ name[=value] ] ..."},history:{shortDescription:"Command history",description:": Same as **fc -l***.*",args:"history"},integer:{shortDescription:"Integer arithmetic",description:": Equivalent to **typeset -i***, except that options irrelevant to* integers are not permitted.",args:"integer [ {+|-}Hghlprtux ] [ {+|-}LRZi [ n ] ] [ name[=value] ... ]"},jobs:{shortDescription:"List active jobs",description:`**jobs -Z** *string* Lists information about each given job, or all jobs if *job is omitted. The* **-l** *flag lists process* IDs, and the **-p** *flag lists process groups.* If the **-r** *flag is specified only running jobs will be listed* and if the **-s** *flag is given only stopped jobs are shown.* If the **-d** *flag is given, the directory from which the job was* started (which may not be the current directory of the job) will also be shown. > The **-Z** *option replaces the shell\\'s argument and environment space with* the given string, truncated if necessary to fit. This will normally be visible in **ps** *(ps(1)) listings. This feature is typically* used by daemons, to indicate their state. > > Full job control is only available in the top-level interactive shell, not in commands run in the left hand side of pipelines or within the **(***\\...***)** *construct. However, a snapshot* of the job state at that point is taken, so it is still possible to use the **jobs** *builtin, or any parameter providing job information.* This gives information about the state of jobs at the point the subshell was created. If background processes are created within the subshell, then instead information about those processes is provided. > > For example, > > > sleep 10 & # Job in background > > ( # Shell forks > > jobs # Shows information about "sleep 10 &" > > sleep 5 & # Process in background (no job control) > > jobs # Shows information about "sleep 5 &" > > )`,args:"jobs [ -dlprs ] [ job ... ]"},kill:{shortDescription:"Send a signal to a process",description:"**kill** **-l** *\\[ sig \\... \\]* Sends either **SIGTERM** *or the specified signal to the given* jobs or processes. Signals are given by number or by names, with or without the `**SIG***`* prefix. If the signal being sent is not `**KILL***` or `***CONT***`, then the job* will be sent a `**CONT***` signal if it is stopped.* The argument *job can be the process ID of a job* not in the job list. In the second form, **kill -l***, if sig is not* specified the signal names are listed. Otherwise, for each *sig that is a name, the corresponding signal number is* listed. For each *sig that is a signal number or a number* representing the exit status of a process which was terminated or stopped by a signal the name of the signal is printed.\n\n> On some systems, alternative signal names are allowed for a few signals. Typical examples are **SIGCHLD** *and* **SIGCLD** *or* **SIGPOLL** *and* **SIGIO***, assuming they correspond to the same signal number.* **kill** -l *will only list the preferred form, however* **kill -l** *alt will* show if the alternative form corresponds to a signal number. For example, under Linux **kill -l IO** *and* **kill -l POLL** *both output 29, hence* **kill -IO** *and* **kill -POLL** *have the same effect.*\n>\n> Many systems will allow process IDs to be negative to kill a process group or zero to kill the current process group.",args:"kill [ -s signal_name | -n signal_number | -sig ] job ..."},let:{shortDescription:"Evaluate arithmetic expression",description:": Evaluate each *arg as an arithmetic expression.* See the section `Arithmetic Evaluation` in *zshmisc(1)* for a description of arithmetic expressions. The exit status is 0 if the value of the last expression is nonzero, 1 if it is zero, and 2 if an error occurred.",args:"let arg ..."},limit:{shortDescription:"Set or display resource limits",description:`: Set or display resource limits. Unless the **-s** *flag is given,* the limit applies only the children of the shell. If **-s** *is* given without other arguments, the resource limits of the current shell is set to the previously set resource limits of the children. If *limit is not specified, print the current limit placed* on *resource, otherwise* set the limit to the specified value. If the **-h** *flag* is given, use hard limits instead of soft limits. If no *resource is given, print all limits.* When looping over multiple resources, the shell will abort immediately if it detects a badly formed argument. However, if it fails to set a limit for some other reason it will continue trying to set the remaining limits. *resource can be one of:* **addressspace** : Maximum amount of address space used. **aiomemorylocked** : Maximum amount of memory locked in RAM for AIO operations. **aiooperations** : Maximum number of AIO operations. **cachedthreads** : Maximum number of cached threads. **coredumpsize** : Maximum size of a core dump. **cputime** : Maximum CPU seconds per process. **datasize** : Maximum data size (including stack) for each process. **descriptors** : Maximum value for a file descriptor. **filesize** : Largest single file allowed. **kqueues** : Maximum number of kqueues allocated. **maxproc** : Maximum number of processes. **maxpthreads** : Maximum number of threads per process. **memorylocked** : Maximum amount of memory locked in RAM. **memoryuse** : Maximum resident set size. **msgqueue** : Maximum number of bytes in POSIX message queues. **posixlocks** : Maximum number of POSIX locks per user. **pseudoterminals** : Maximum number of pseudo-terminals. **resident** : Maximum resident set size. **sigpending** : Maximum number of pending signals. **sockbufsize** : Maximum size of all socket buffers. **stacksize** : Maximum stack size for each process. **swapsize** : Maximum amount of swap used. **vmemorysize** : Maximum amount of virtual memory. Which of these resource limits are available depends on the system. *resource can be abbreviated to any unambiguous prefix. It* can also be an integer, which corresponds to the integer defined for the resource by the operating system. If argument corresponds to a number which is out of the range of the resources configured into the shell, the shell will try to read or write the limit anyway, and will report an error if this fails. As the shell does not store such resources internally, an attempt to set the limit will fail unless the **-s** *option is present.* *limit is a number, with an optional scaling factor, as follows:* *n***h** : hours *n***k** : kilobytes (default) *n***m** : megabytes or minutes *n***g** : gigabytes \\[*mm***:***\\]ss* : minutes and seconds The **limit** *command is not made available by default when the* shell starts in a mode emulating another shell. It can be made available with the command \`**zmodload -F zsh/rlimits b:limit***\`.*`,args:"limit [ -hs ] [ resource [ limit ] ] ..."},local:{shortDescription:"Create a local variable",description:": Same as **typeset***, except that the options* **-g***, and* **-f** *are not permitted. In this case the* **-x** *option does not force* the use of **-g***, i.e. exported variables will be local to functions.*",args:"local [ {+|-}AHUahlprtux ] [ {+|-}EFLRZi [ n ] ] [ name[=value] ... ]"},logout:{shortDescription:"Exit the shell",description:": Same as **exit***, except that it only works in a login shell.*",args:"logout [ n ]"},noglob:{shortDescription:"Disable filename expansion",description:": See the section `Precommand Modifiers` in *zshmisc(1).*",args:"noglob simple command"},popd:{shortDescription:"Remove directory from stack",description:": Remove an entry from the directory stack, and perform a **cd** *to* the new top directory. With no argument, the current top entry is removed. An argument of the form `**+***n` identifies a stack* entry by counting from the left of the list shown by the **dirs** *command,* starting with zero. An argument of the form **-***n counts from the right.* If the **PUSHD_MINUS** *option is set, the meanings of `***+***` and* `**-***` in this context are swapped.*\n\n If the **-q** *(quiet) option is specified, the hook function* **chpwd** and the functions in the array **\\$chpwd_functions** *are not called,* and the new directory stack is not printed. This is useful for calls to **popd** *that do not change the environment seen by an interactive user.*",args:"popd [ -q ] [ {+|-}n ]"},print:{shortDescription:"Print arguments",description:`*\\[* **-v** *name \\] \\[* **-xX** *tabstop \\] \\[* **-R** *\\[* **-en** *\\]\\] \\[ arg \\... \\]* With the \`**-f***\` option the arguments are printed as described by* **printf***.* With no flags or with the flag \`**-***\`, the arguments are printed on* the standard output as described by **echo***, with the following differences:* the escape sequence \`**\\\\M-***x\` (or \`***\\\\M***x\`) metafies the character* *x (sets the highest bit),* \`**\\\\C-***x\` (or \`***\\\\C***x\`) produces a control character* (\`**\\\\C-@***\` and \`***\\\\C-?***\` give the characters NULL and delete),* a character code in octal is represented by \`**\\\\***NNN\`* (instead of \`**\\\\0***NNN\`),* and \`**\\\\E***\` is a synonym for \`***\\\\e***\`.* Finally, if not in an escape sequence, \`**\\\\***\` escapes the following character and is not printed.* > **-a** Print arguments with the column incrementing first. Only useful with the **-c** *and* **-C** *options.* > > **-b** > > : Recognize all the escape sequences defined for the **bindkey** *command,* see the section \`Zle Builtins\` in *zshzle(1).* > > **-c** > > : Print the arguments in columns. Unless **-a** *is also given, arguments are* printed with the row incrementing first. > > **-C** *cols* > > : Print the arguments in *cols columns. Unless* **-a** *is also given,* arguments are printed with the row incrementing first. > > **-D** > > : Treat the arguments as paths, replacing directory prefixes with **\\~** expressions corresponding to directory names, as appropriate. > > **-i** > > : If given together with **-o** *or* **-O***, sorting is performed* case-independently. > > **-l** > > : Print the arguments separated by newlines instead of spaces. Note: if the list of arguments is empty, **print -l** *will still output one empty* line. To print a possibly-empty list of arguments one per line, use **print -C1***, as in \`***print -rC1 \\-- \\"\\$list\\[@\\]\\"***\`.* > > **-m** > > : Take the first argument as a pattern (should be quoted), and remove it from the argument list together with subsequent arguments that do not match this pattern. > > **-n** > > : Do not add a newline to the output. > > **-N** > > : Print the arguments separated and terminated by nulls. Again, **print -rNC1 \\-- \\"\\$list\\[@\\]\\"** *is a canonical way to print an* arbitrary list as null-delimited records. > > **-o** > > : Print the arguments sorted in ascending order. > > **-O** > > : Print the arguments sorted in descending order. > > **-p** > > : Print the arguments to the input of the coprocess. > > **-P** > > : Perform prompt expansion (see EXPANSION OF PROMPT SEQUENCES in *zshmisc(1)).* In combination with \`**-f***\`,* prompt escape sequences are parsed only within interpolated arguments, not within the format string. > > **-r** > > : Ignore the escape conventions of **echo***.* > > **-R** > > : Emulate the BSD **echo** *command, which does not process escape sequences* unless the **-e** *flag is given. The* **-n** *flag suppresses the trailing* newline. Only the **-e** *and* **-n** *flags are recognized after* **-R***; all other arguments and options are printed.* > > **-s** > > : Place the results in the history list instead of on the standard output. Each argument to the **print** *command is treated as a single word in the* history, regardless of its content. > > **-S** > > : Place the results in the history list instead of on the standard output. In this case only a single argument is allowed; it will be split into words as if it were a full shell command line. The effect is similar to reading the line from a history file with the **HIST_LEX_WORDS** *option active.* > > **-u** *n* > > : Print the arguments to file descriptor *n.* > > **-v** *name* > > : Store the printed arguments as the value of the parameter *name.* > > **-x** *tab-stop* > > : Expand leading tabs on each line of output in the printed string assuming a tab stop every *tab-stop characters. This is appropriate* for formatting code that may be indented with tabs. Note that leading tabs of any argument to print, not just the first, are expanded, even if **print** *is using spaces to separate arguments (the column count* is maintained across arguments but may be incorrect on output owing to previous unexpanded tabs). > > The start of the output of each print command is assumed to be aligned with a tab stop. Widths of multibyte characters are handled if the option **MULTIBYTE** *is in effect. This option is ignored if other* formatting options are in effect, namely column alignment or **printf** *style, or if output is to a special location such as shell* history or the command line editor. > > **-X** *tab-stop* > > : This is similar to **-x***, except that all tabs in the printed string* are expanded. This is appropriate if tabs in the arguments are being used to produce a table format. > > **-z** > > : Push the arguments onto the editing buffer stack, separated by spaces. > > If any of \`**-m***\`, \`***-o***\` or \`***-O***\` are used in combination with* \`**-f***\` and there are no arguments (after the removal process in the* case of \`**-m***\`) then nothing is printed.*`,args:"print [ -abcDilmnNoOpPrsSz ] [ -u n ] [ -f format ] [ -C cols ]"},printf:{shortDescription:"Format and print data",description:": Print the arguments according to the format specification. Formatting rules are the same as used in C. The same escape sequences as for **echo** are recognised in the format. All C conversion specifications ending in one of **csdiouxXeEfgGn** *are handled. In addition to this, `***%b***` can be* used instead of `**%s***` to cause escape sequences in the argument to be* recognised and `**%q***` can be used to quote the argument in such a way* that allows it to be reused as shell input. With the numeric format specifiers, if the corresponding argument starts with a quote character, the numeric value of the following character is used as the number to print; otherwise the argument is evaluated as an arithmetic expression. See the section `Arithmetic Evaluation` in *zshmisc(1)* for a description of arithmetic expressions. With `**%n***`, the corresponding argument is taken as an* identifier which is created as an integer parameter.\n\n Normally, conversion specifications are applied to each argument in order but they can explicitly specify the *nth argument is to be used by* replacing `**%***` by `***%***n***\\$***` and `***\\****` by `***\\****n***\\$***`.* It is recommended that you do not mix references of this explicit style with the normal style and the handling of such mixed styles may be subject to future change.\n\n If arguments remain unused after formatting, the format string is reused until all arguments have been consumed. With the **print** *builtin, this* can be suppressed by using the **-r** *option. If more arguments are* required by the format than have been specified, the behaviour is as if zero or an empty string had been specified as the argument.\n\n The **-v** *option causes the output to be stored as the value of the* parameter *name, instead of printed. If name is an array and* the format string is reused when consuming arguments then one array element will be used for each use of the format string.",args:"printf [ -v name ] format [ arg ... ]"},pushd:{shortDescription:"Add directory to stack",description:"> The third form of **pushd** *changes directory by rotating the* directory list. An argument of the form `**+***n` identifies a stack* entry by counting from the left of the list shown by the **dirs** command, starting with zero. An argument of the form `**-***n` counts* from the right. If the **PUSHD_MINUS** *option is set, the meanings* of `**+***` and `***-***` in this context are swapped.*\n>\n> If the **-q** *(quiet) option is specified, the hook function* **chpwd** and the functions in the array **\\$chpwd_functions** *are not called,* and the new directory stack is not printed. This is useful for calls to **pushd** *that do not change the environment seen by an interactive user.*\n>\n> If the option **-q** *is not specified and the shell option* **PUSHD_SILENT** is not set, the directory stack will be printed after a **pushd** *is* performed.\n>\n> The options **-s***,* **-L** *and* **-P** *have the same meanings as for the* **cd** *builtin.*",args:`pushd [ -qsLP ] [ arg ] pushd [ -qsLP ] old new pushd [ -qsLP ] {+|-}n Change the current directory, and push the old current directory onto the directory stack. In the first form, change the current directory to arg. If arg is not specified, change to the second directory on the stack (that is, exchange the top two entries), or change to $HOME if t[01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:05:48) - Proceso de subida de imagen iniciado, data: {"source":"webhook","RefAL":"MAR-129924","MarcaId":"4597192000261770003","user":"dvillagomez@arochilindner.com"} [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:05:55) - Tokens generados: 1000.c6eb50f601ebd3c8a9c56cf8d2630c3b.8e2c7a220535b5d14e3124e0b66c2b23 [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:05:55) - Intento 0 el registro no contiene foto asociada [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:05:55) - ERROR al obtener imagen, intento: 1 , respuesta: null [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:05:58) - Intento 1 el registro no contiene foto asociada [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:05:58) - ERROR al obtener imagen, intento: 2 , respuesta: null [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:06:00) - Intento 2 el registro no contiene foto asociada [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:06:00) - ERROR al obtener imagen, intento: 3 , respuesta: null [01e2cd9f-e136-47a7-93f4-a3f3fdb9364d](2025-06-02 10:06:02) - No se pudo encontrar una imagen asociada a registro de CRM \n [410dbd98-3f2f-405d-9349-d3a5b944d63e](2025-06-02 10:56:48) - Proceso de subida de imagen iniciado, data: {"source":"webhook","RefAL":"MAR-129925","MarcaId":"4597192000261806611","user":"bmeza@arochilindner.com"} [410dbd98-3f2f-405d-9349-d3a5b944d63e](2025-06-02 10:56:55) - Tokens generados: 1000.c6eb50f601ebd3c8a9c56cf8d2630c3b.8e2c7a220535b5d14e3124e0b66c2b23 [410dbd98-3f2f-405d-9349-d3a5b944d63e](2025-06-02 10:56:56) - Intento 0 para obtener imagen de marca de CRM, respuesta: 200 [410dbd98-3f2f-405d-9349-d3a5b944d63e](2025-06-02 10:56:56) - Imagen guardada localmente de manera exitosa [410dbd98-3f2f-405d-9349-d3a5b944d63e](2025-06-02 10:56:57) - Intento 0 para actualizar CRM con datos de url de marca: { "data": [ { "code": "SUCCESS", "details": { "Modified_Time": "2025-06-02T11:56:57-04:00", "Modified_By": { "name": "Aptus Legal Administrator", "id": "4597192000000287001" }, "Created_Time": "2025-06-02T11:56:47-04:00", "id": "4597192000261806611", "Created_By": { "name": "Bryan Meza Guzm\u00e1n", "id": "4597192000239638001" } }, "message": "record updated", "status": "success" } ] } [410dbd98-3f2f-405d-9349-d3a5b944d63e](2025-06-02 10:56:57) - Proceso finalizado exitosamente, URL: https://aptuslegal.app/imagenesAptusLegal/arochi/LogosArochi/MAR-129925.png [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:15) - Proceso de subida de imagen iniciado, data: {"source":"webhook","RefAL":"MAR-129926","MarcaId":"4597192000261824033","user":"jcuevas@arochilindner.com"} [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:22) - Tokens generados: 1000.012c28e9f0a3d8791c7f73998ec2d33c.2a7d944bf9798097b86fd89c7c2bcd51 [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:23) - Intento 0 el registro no contiene foto asociada [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:23) - ERROR al obtener imagen, intento: 1 , respuesta: null [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:25) - Intento 1 el registro no contiene foto asociada [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:25) - ERROR al obtener imagen, intento: 2 , respuesta: null [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:28) - Intento 2 el registro no contiene foto asociada [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:28) - ERROR al obtener imagen, intento: 3 , respuesta: null [62ae4731-8166-4b07-9489-857166ac844c](2025-06-02 11:18:30) - No se pudo encontrar una imagen asociada a registro de CRM \n [18f9dbb1-5ead-45d0-9a68-2507ccb42cd2](2025-06-02 12:09:51) - Proceso de subida de imagen iniciado, data: {"source":"webhook","RefAL":"MAR-129910","MarcaId":"4597192000261400116","user":"bmeza@arochisTransport object representing the DTLS transport used for the transmission and receipt of data packets. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCSctpTransport/transport) */ readonly transport: RTCDtlsTransport; addEventListener(type: K, listener: (this: RTCSctpTransport, ev: RTCSctpTransportEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: RTCSctpTransport, ev: RTCSctpTransportEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var RTCSctpTransport: { prototype: RTCSctpTransport; new(): RTCSctpTransport; }; /** * The **`RTCSessionDescription`** interface describes one end of a connection—or potential connection—and how it's configured. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCSessionDescription) */ interface RTCSessionDescription { /** * The property **`RTCSessionDescription.sdp`** is a read-only string containing the SDP which describes the session. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCSessionDescription/sdp) */ readonly sdp: string; /** * The property **`RTCSessionDescription.type`** is a read-only string value which describes the description's type. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCSessionDescription/type) */ readonly type: RTCSdpType; /** * The **`RTCSessionDescription.toJSON()`** method generates a ```js-nolint toJSON() ``` None. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCSessionDescription/toJSON) */ toJSON(): RTCSessionDescriptionInit; } declare var RTCSessionDescription: { prototype: RTCSessionDescription; new(descriptionInitDict: RTCSessionDescriptionInit): RTCSessionDescription; }; /** * The **`RTCStatsReport`** interface of the WebRTC API provides a statistics report for a RTCPeerConnection, RTCRtpSender, or RTCRtpReceiver. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCStatsReport) */ interface RTCStatsReport { forEach(callbackfn: (value: any, key: string, parent: RTCStatsReport) => void, thisArg?: any): void; } declare var RTCStatsReport: { prototype: RTCStatsReport; new(): RTCStatsReport; }; /** * The WebRTC API interface **`RTCTrackEvent`** represents the RTCPeerConnection.track_event event, which is sent when a new MediaStreamTrack is added to an RTCRtpReceiver which is part of the RTCPeerConnection. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCTrackEvent) */ interface RTCTrackEvent extends Event { /** * The read-only **`receiver`** property of the RTCTrackEvent interface indicates the The RTCRtpReceiver which pairs the `receiver` with a sender and other properties which establish a single bidirectional RTP stream for use by the RTCTrackEvent.track associated with the `RTCTrackEvent`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCTrackEvent/receiver) */ readonly receiver: RTCRtpReceiver; /** * The WebRTC API interface RTCTrackEvent's read-only **`streams`** property specifies an array of track being added to the RTCPeerConnection. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCTrackEvent/streams) */ readonly streams: ReadonlyArray; /** * The * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCTrackEvent/track) */ readonly track: MediaStreamTrack; /** * The WebRTC API interface RTCTrackEvent's read-only **`transceiver`** property indicates the The transceiver pairs the track's The RTCRtpTransceiver which pairs the `receiver` with a sender and other properties which establish a single bidirectional RTP stream for use by the RTCTrackEvent.track associated with the `RTCTrackEvent`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RTCTrackEvent/transceiver) */ readonly transceiver: RTCRtpTransceiver; } declare var RTCTrackEvent: { prototype: RTCTrackEvent; new(type: string, eventInitDict: RTCTrackEventInit): RTCTrackEvent; }; /** * The **`RadioNodeList`** interface represents a collection of elements in a form returned by a call to HTMLFormControlsCollection.namedItem(). * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RadioNodeList) */ interface RadioNodeList extends NodeListOf { /** * If the underlying element collection contains radio buttons, the **`RadioNodeList.value`** property represents the checked radio button. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RadioNodeList/value) */ value: string; } declare var RadioNodeList: { prototype: RadioNodeList; new(): RadioNodeList; }; /** * The **`Range`** interface represents a fragment of a document that can contain nodes and parts of text nodes. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range) */ interface Range extends AbstractRange { /** * The **`Range.commonAncestorContainer`** read-only property returns the deepest — or furthest down the document tree — Node that contains both boundary points of the Range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/commonAncestorContainer) */ readonly commonAncestorContainer: Node; /** * The **`cloneContents()`** method of the Range interface copies the selected Node children of the range's Range/commonAncestorContainer and puts them in a new DocumentFragment object. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/cloneContents) */ cloneContents(): DocumentFragment; /** * The **`Range.cloneRange()`** method returns a The returned clone is copied by value, not reference, so a change in either ```js-nolint cloneRange() ``` None. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/cloneRange) */ cloneRange(): Range; /** * The **`collapse()`** method of the Range interface collapses the A collapsed Range is empty, containing no content, specifying a single-point in a DOM tree. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/collapse) */ collapse(toStart?: boolean): void; /** * The **`compareBoundaryPoints()`** method of the Range interface compares the boundary points of the Range with those of another range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/compareBoundaryPoints) */ compareBoundaryPoints(how: number, sourceRange: Range): number; /** * The **`comparePoint()`** method of the Range interface determines whether a specified point is before, within, or after the Range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/comparePoint) */ comparePoint(node: Node, offset: number): number; /** * The **`Range.createContextualFragment()`** method returns a XML fragment parsing algorithm with the start of the range (the _parent_ of the selected node) as the context node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/createContextualFragment) */ createContextualFragment(string: string): DocumentFragment; /** * The **`Range.deleteContents()`** method removes all completely-selected Node within this range from the document. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/deleteContents) */ deleteContents(): void; /** * The **`Range.detach()`** method does nothing. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/detach) */ detach(): void; /** * The **`extractContents()`** method of the Range interface is similar to a combination of Range.cloneContents() and Range.deleteContents(). * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/extractContents) */ extractContents(): DocumentFragment; /** * The **`Range.getBoundingClientRect()`** method returns a DOMRect object that bounds the contents of the range; this is a rectangle enclosing the union of the bounding rectangles for all the elements in the range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/getBoundingClientRect) */ getBoundingClientRect(): DOMRect; /** * The **`Range.getClientRects()`** method returns a list of DOMRect objects representing the area of the screen occupied by the range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/getClientRects) */ getClientRects(): DOMRectList; /** * The **`Range.insertNode()`** method inserts a node at the start of the Range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/insertNode) */ insertNode(node: Node): void; /** * The **`Range.intersectsNode()`** method returns a boolean indicating whether the given Node intersects the Range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/intersectsNode) */ intersectsNode(node: Node): boolean; /** * The **`isPointInRange()`** method of the Range interface determines whether a specified point is within the Range. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/isPointInRange) */ isPointInRange(node: Node, offset: number): boolean; /** * The **`Range.selectNode()`** method sets the the parent of the _referenceNode_. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/selectNode) */ selectNode(node: Node): void; /** * The **`Range.selectNodeContents()`** method sets the Range to contain the contents of a Node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/selectNodeContents) */ selectNodeContents(node: Node): void; /** * The **`Range.setEnd()`** method sets the end position of a Range to be located at the given offset into the specified node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/setEnd) */ setEnd(node: Node, offset: number): void; /** * The **`Range.setEndAfter()`** method sets the end position of a `Node` of end of the `Range` will be the same as that for the `referenceNode`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/setEndAfter) */ setEndAfter(node: Node): void; /** * The **`Range.setEndBefore()`** method sets the end position of a `Range` relative to another Node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/setEndBefore) */ setEndBefore(node: Node): void; /** * The **`Range.setStart()`** method sets the start position of a If the `startNode` is a Node of type Text, the number of characters from the start of `startNode`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/setStart) */ setStart(node: Node, offset: number): void; /** * The **`Range.setStartAfter()`** method sets the start position of a Range relative to a Node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/setStartAfter) */ setStartAfter(node: Node): void; /** * The **`Range.setStartBefore()`** method sets the start position of a Range relative to another Node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/setStartBefore) */ setStartBefore(node: Node): void; /** * The **`surroundContents()`** method of the Range interface surrounds the selected content by a provided node. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Range/surroundContents) */ surroundContents(newParent: Node): void; toString(): string; readonly START_TO_START: 0; readonly START_TO_END: 1; readonly END_TO_END: 2; readonly END_TO_START: 3; } declare var Range: { prototype: Range; new(): Range; readonly START_TO_START: 0; readonly START_TO_END: 1; readonly END_TO_END: 2; readonly END_TO_START: 3; }; /** * The **`ReadableByteStreamController`** interface of the Streams API represents a controller for a readable byte stream. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableByteStreamController) */ interface ReadableByteStreamController { /** * The **`byobRequest`** read-only property of the ReadableByteStreamController interface returns the current BYOB request, or `null` if there are no pending requests. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableByteStreamController/byobRequest) */ readonly byobRequest: ReadableStreamBYOBRequest | null; /** * The **`desiredSize`** read-only property of the ReadableByteStreamController interface returns the number of bytes required to fill the stream's internal queue to its 'desired size'. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableByteStreamController/desiredSize) */ readonly desiredSize: number | null; /** * The **`close()`** method of the ReadableByteStreamController interface closes the associated stream. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableByteStreamController/close) */ close(): void; /** * The **`enqueue()`** method of the ReadableByteStreamController interface enqueues a given chunk on the associated readable byte stream (the chunk is copied into the stream's internal queues). * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableByteStreamController/enqueue) */ enqueue(chunk: ArrayBufferView): void; /** * The **`error()`** method of the ReadableByteStreamController interface causes any future interactions with the associated stream to error with the specified reason. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableByteStreamController/error) */ error(e?: any): void; } declare var ReadableByteStreamController: { prototype: ReadableByteStreamController; new(): ReadableByteStreamController; }; /** * The `ReadableStream` interface of the Streams API represents a readable stream of byte data. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream) */ interface ReadableStream { /** * The **`locked`** read-only property of the ReadableStream interface returns whether or not the readable stream is locked to a reader. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/locked) */ readonly locked: boolean; /** * The **`cancel()`** method of the ReadableStream interface returns a Promise that resolves when the stream is canceled. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/cancel) */ cancel(reason?: any): Promise; /** * The **`getReader()`** method of the ReadableStream interface creates a reader and locks the stream to it. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/getReader) */ getReader(options: { mode: "byob" }): ReadableStreamBYOBReader; getReader(): ReadableStreamDefaultReader; getReader(options?: ReadableStreamGetReaderOptions): ReadableStreamReader; /** * The **`pipeThrough()`** method of the ReadableStream interface provides a chainable way of piping the current stream through a transform stream or any other writable/readable pair. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/pipeThrough) */ pipeThrough(transform: ReadableWritablePair, options?: StreamPipeOptions): ReadableStream; /** * The **`pipeTo()`** method of the ReadableStream interface pipes the current `ReadableStream` to a given WritableStream and returns a Promise that fulfills when the piping process completes successfully, or rejects if any errors were encountered. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/pipeTo) */ pipeTo(destination: WritableStream, options?: StreamPipeOptions): Promise; /** * The **`tee()`** method of the two-element array containing the two resulting branches as new ReadableStream instances. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStream/tee) */ tee(): [ReadableStream, ReadableStream]; } declare var ReadableStream: { prototype: ReadableStream; new(underlyingSource: UnderlyingByteSource, strategy?: { highWaterMark?: number }): ReadableStream>; new(underlyingSource: UnderlyingDefaultSource, strategy?: QueuingStrategy): ReadableStream; new(underlyingSource?: UnderlyingSource, strategy?: QueuingStrategy): ReadableStream; }; /** * The `ReadableStreamBYOBReader` interface of the Streams API defines a reader for a ReadableStream that supports zero-copy reading from an underlying byte source. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBReader) */ interface ReadableStreamBYOBReader extends ReadableStreamGenericReader { /** * The **`read()`** method of the ReadableStreamBYOBReader interface is used to read data into a view on a user-supplied buffer from an associated readable byte stream. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBReader/read) */ read(view: T): Promise>; /** * The **`releaseLock()`** method of the ReadableStreamBYOBReader interface releases the reader's lock on the stream. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBReader/releaseLock) */ releaseLock(): void; } declare var ReadableStreamBYOBReader: { prototype: ReadableStreamBYOBReader; new(stream: ReadableStream>): ReadableStreamBYOBReader; }; /** * The **`ReadableStreamBYOBRequest`** interface of the Streams API represents a 'pull request' for data from an underlying source that will made as a zero-copy transfer to a consumer (bypassing the stream's internal queues). * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBRequest) */ interface ReadableStreamBYOBRequest { /** * The **`view`** getter property of the ReadableStreamBYOBRequest interface returns the current view. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBRequest/view) */ readonly view: ArrayBufferView | null; /** * The **`respond()`** method of the ReadableStreamBYOBRequest interface is used to signal to the associated readable byte stream that the specified number of bytes were written into the ReadableStreamBYOBRequest.view. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBRequest/respond) */ respond(bytesWritten: number): void; /** * The **`respondWithNewView()`** method of the ReadableStreamBYOBRequest interface specifies a new view that the consumer of the associated readable byte stream should write to instead of ReadableStreamBYOBRequest.view. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBRequest/respondWithNewView) */ respondWithNewView(view: ArrayBufferView): void; } declare var ReadableStreamBYOBRequest: { prototype: ReadableStreamBYOBRequest; new(): ReadableStreamBYOBRequest; }; /** * The **`ReadableStreamDefaultController`** interface of the Streams API represents a controller allowing control of a ReadableStream's state and internal queue. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultController) */ interface ReadableStreamDefaultController { /** * The **`desiredSize`** read-only property of the required to fill the stream's internal queue. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultController/desiredSize) */ readonly desiredSize: number | null; /** * The **`close()`** method of the ReadableStreamDefaultController interface closes the associated stream. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultController/close) */ close(): void; /** * The **`enqueue()`** method of the ```js-nolint enqueue(chunk) ``` - `chunk` - : The chunk to enqueue. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultController/enqueue) */ enqueue(chunk?: R): void; /** * The **`error()`** method of the with the associated stream to error. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultController/error) */ error(e?: any): void; } declare var ReadableStreamDefaultController: { prototype: ReadableStreamDefaultController; new(): ReadableStreamDefaultController; }; /** * The **`ReadableStreamDefaultReader`** interface of the Streams API represents a default reader that can be used to read stream data supplied from a network (such as a fetch request). * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultReader) */ interface ReadableStreamDefaultReader extends ReadableStreamGenericReader { /** * The **`read()`** method of the ReadableStreamDefaultReader interface returns a Promise providing access to the next chunk in the stream's internal queue. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultReader/read) */ read(): Promise>; /** * The **`releaseLock()`** method of the ReadableStreamDefaultReader interface releases the reader's lock on the stream. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamDefaultReader/releaseLock) */ releaseLock(): void; } declare var ReadableStreamDefaultReader: { prototype: ReadableStreamDefaultReader; new(stream: ReadableStream): ReadableStreamDefaultReader; }; interface ReadableStreamGenericReader { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBReader/closed) */ readonly closed: Promise; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReadableStreamBYOBReader/cancel) */ cancel(reason?: any): Promise; } interface RemotePlaybackEventMap { "connect": Event; "connecting": Event; "disconnect": Event; } /** * The **`RemotePlayback`** interface of the Remote Playback API allows the page to detect availability of remote playback devices, then connect to and control playing on these devices. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback) */ interface RemotePlayback extends EventTarget { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/connect_event) */ onconnect: ((this: RemotePlayback, ev: Event) => any) | null; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/connecting_event) */ onconnecting: ((this: RemotePlayback, ev: Event) => any) | null; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/disconnect_event) */ ondisconnect: ((this: RemotePlayback, ev: Event) => any) | null; /** * The **`state`** read-only property of the RemotePlayback interface returns the current state of the `RemotePlayback` connection. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/state) */ readonly state: RemotePlaybackState; /** * The **`cancelWatchAvailability()`** method of the RemotePlayback interface cancels the request to watch for one or all available devices. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/cancelWatchAvailability) */ cancelWatchAvailability(id?: number): Promise; /** * The **`prompt()`** method of the RemotePlayback interface prompts the user to select an available remote playback device and give permission for the current media to be played using that device. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/prompt) */ prompt(): Promise; /** * The **`watchAvailability()`** method of the RemotePlayback interface watches the list of available remote playback devices and returns a Promise that resolves with the `callbackId` of a remote playback device. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/RemotePlayback/watchAvailability) */ watchAvailability(callback: RemotePlaybackAvailabilityCallback): Promise; addEventListener(type: K, listener: (this: RemotePlayback, ev: RemotePlaybackEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: RemotePlayback, ev: RemotePlaybackEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var RemotePlayback: { prototype: RemotePlayback; new(): RemotePlayback; }; /** * The `Report` interface of the Reporting API represents a single report. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Report) */ interface Report { /** * The **`body`** read-only property of the Report interface returns the body of the report, which is a `ReportBody` object containing the detailed report information. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Report/body) */ readonly body: ReportBody | null; /** * The **`type`** read-only property of the Report interface returns the type of report generated, e.g., `deprecation` or `intervention`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Report/type) */ readonly type: string; /** * The **`url`** read-only property of the Report interface returns the URL of the document that generated the report. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Report/url) */ readonly url: string; toJSON(): any; } declare var Report: { prototype: Report; new(): Report; }; /** * The **`ReportBody`** interface of the Reporting API represents the body of a report. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReportBody) */ interface ReportBody { /** * The **`toJSON()`** method of the ReportBody interface is a _serializer_, and returns a JSON representation of the `ReportBody` object. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReportBody/toJSON) */ toJSON(): any; } declare var ReportBody: { prototype: ReportBody; new(): ReportBody; }; /** * The `ReportingObserver` interface of the Reporting API allows you to collect and access reports. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReportingObserver) */ interface ReportingObserver { /** * The **`disconnect()`** method of the previously started observing from collecting reports. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReportingObserver/disconnect) */ disconnect(): void; /** * The **`observe()`** method of the collecting reports in its report queue. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReportingObserver/observe) */ observe(): void; /** * The **`takeRecords()`** method of the in the observer's report queue, and empties the queue. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ReportingObserver/takeRecords) */ takeRecords(): ReportList; } declare var ReportingObserver: { prototype: ReportingObserver; new(callback: ReportingObserverCallback, options?: ReportingObserverOptions): ReportingObserver; }; /** * The **`Request`** interface of the Fetch API represents a resource request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request) */ interface Request extends Body { /** * The **`cache`** read-only property of the Request interface contains the cache mode of the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/cache) */ readonly cache: RequestCache; /** * The **`credentials`** read-only property of the Request interface reflects the value given to the Request.Request() constructor in the `credentials` option. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/credentials) */ readonly credentials: RequestCredentials; /** * The **`destination`** read-only property of the **Request** interface returns a string describing the type of content being requested. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/destination) */ readonly destination: RequestDestination; /** * The **`headers`** read-only property of the with the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/headers) */ readonly headers: Headers; /** * The **`integrity`** read-only property of the Request interface contains the subresource integrity value of the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/integrity) */ readonly integrity: string; /** * The **`keepalive`** read-only property of the Request interface contains the request's `keepalive` setting (`true` or `false`), which indicates whether the browser will keep the associated request alive if the page that initiated it is unloaded before the request is complete. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/keepalive) */ readonly keepalive: boolean; /** * The **`method`** read-only property of the `POST`, etc.) A String indicating the method of the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/method) */ readonly method: string; /** * The **`mode`** read-only property of the Request interface contains the mode of the request (e.g., `cors`, `no-cors`, `same-origin`, or `navigate`.) This is used to determine if cross-origin requests lead to valid responses, and which properties of the response are readable. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/mode) */ readonly mode: RequestMode; /** * The **`redirect`** read-only property of the Request interface contains the mode for how redirects are handled. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/redirect) */ readonly redirect: RequestRedirect; /** * The **`referrer`** read-only property of the Request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/referrer) */ readonly referrer: string; /** * The **`referrerPolicy`** read-only property of the referrer information, sent in the Referer header, should be included with the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/referrerPolicy) */ readonly referrerPolicy: ReferrerPolicy; /** * The read-only **`signal`** property of the Request interface returns the AbortSignal associated with the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/signal) */ readonly signal: AbortSignal; /** * The **`url`** read-only property of the Request interface contains the URL of the request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/url) */ readonly url: string; /** * The **`clone()`** method of the Request interface creates a copy of the current `Request` object. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/clone) */ clone(): Request; } declare var Request: { prototype: Request; new(input: RequestInfo | URL, init?: RequestInit): Request; }; /** * The **`ResizeObserver`** interface reports changes to the dimensions of an Element's content or border box, or the bounding box of an SVGElement. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserver) */ interface ResizeObserver { /** * The **`disconnect()`** method of the or SVGElement targets. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserver/disconnect) */ disconnect(): void; /** * The **`observe()`** method of the ```js-nolint observe(target) observe(target, options) ``` - `target` - : A reference to an Element or SVGElement to be observed. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserver/observe) */ observe(target: Element, options?: ResizeObserverOptions): void; /** * The **`unobserve()`** method of the ```js-nolint unobserve(target) ``` - `target` - : A reference to an Element or SVGElement to be unobserved. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserver/unobserve) */ unobserve(target: Element): void; } declare var ResizeObserver: { prototype: ResizeObserver; new(callback: ResizeObserverCallback): ResizeObserver; }; /** * The **`ResizeObserverEntry`** interface represents the object passed to the ResizeObserver.ResizeObserver constructor's callback function, which allows you to access the new dimensions of the Element or SVGElement being observed. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverEntry) */ interface ResizeObserverEntry { /** * The **`borderBoxSize`** read-only property of the ResizeObserverEntry interface returns an array containing the new border box size of the observed element when the callback is run. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverEntry/borderBoxSize) */ readonly borderBoxSize: ReadonlyArray; /** * The **`contentBoxSize`** read-only property of the ResizeObserverEntry interface returns an array containing the new content box size of the observed element when the callback is run. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverEntry/contentBoxSize) */ readonly contentBoxSize: ReadonlyArray; /** * The `contentRect` read-only property of the object containing the new size of the observed element when the callback is run. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverEntry/contentRect) */ readonly contentRect: DOMRectReadOnly; /** * The **`devicePixelContentBoxSize`** read-only property of the ResizeObserverEntry interface returns an array containing the size in device pixels of the observed element when the callback is run. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverEntry/devicePixelContentBoxSize) */ readonly devicePixelContentBoxSize: ReadonlyArray; /** * The **`target`** read-only property of the An Element or SVGElement representing the element being observed. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverEntry/target) */ readonly target: Element; } declare var ResizeObserverEntry: { prototype: ResizeObserverEntry; new(): ResizeObserverEntry; }; /** * The **`ResizeObserverSize`** interface of the Resize Observer API is used by the ResizeObserverEntry interface to access the box sizing properties of the element being observed. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverSize) */ interface ResizeObserverSize { /** * The **`blockSize`** read-only property of the ResizeObserverSize interface returns the length of the observed element's border box in the block dimension. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverSize/blockSize) */ readonly blockSize: number; /** * The **`inlineSize`** read-only property of the ResizeObserverSize interface returns the length of the observed element's border box in the inline dimension. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/ResizeObserverSize/inlineSize) */ readonly inlineSize: number; } declare var ResizeObserverSize: { prototype: ResizeObserverSize; new(): ResizeObserverSize; }; /** * The **`Response`** interface of the Fetch API represents the response to a request. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response) */ interface Response extends Body { /** * The **`headers`** read-only property of the with the response. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/headers) */ readonly headers: Headers; /** * The **`ok`** read-only property of the Response interface contains a Boolean stating whether the response was successful (status in the range 200-299) or not. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/ok) */ readonly ok: boolean; /** * The **`redirected`** read-only property of the Response interface indicates whether or not the response is the result of a request you made which was redirected. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/redirected) */ readonly redirected: boolean; /** * The **`status`** read-only property of the Response interface contains the HTTP status codes of the response. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/status) */ readonly status: number; /** * The **`statusText`** read-only property of the Response interface contains the status message corresponding to the HTTP status code in Response.status. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/statusText) */ readonly statusText: string; /** * The **`type`** read-only property of the Response interface contains the type of the response. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/type) */ readonly type: ResponseType; /** * The **`url`** read-only property of the Response interface contains the URL of the response. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/url) */ readonly url: string; /** * The **`clone()`** method of the Response interface creates a clone of a response object, identical in every way, but stored in a different variable. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/clone) */ clone(): Response; } declare var Response: { prototype: Response; new(body?: BodyInit | null, init?: ResponseInit): Response; /** * The **`error()`** static method of the Response interface returns a new `Response` object associated with a network error. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/error_static) */ error(): Response; /** * The **`json()`** static method of the Response interface returns a `Response` that contains the provided JSON data as body, and a Content-Type header which is set to `application/json`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/json_static) */ json(data: any, init?: ResponseInit): Response; /** * The **`redirect()`** static method of the Response interface returns a `Response` resulting in a redirect to the specified URL. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Response/redirect_static) */ redirect(url: string | URL, status?: number): Response; }; /** * The **`SVGAElement`** interface provides access to the properties of an a element, as well as methods to manipulate them. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAElement) */ interface SVGAElement extends SVGGraphicsElement, SVGURIReference { rel: string; get relList(): DOMTokenList; set relList(value: string); /** * The **`SVGAElement.target`** read-only property of SVGAElement returns an SVGAnimatedString object that specifies the portion of a target window, frame, pane into which a document is to be opened when a link is activated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAElement/target) */ readonly target: SVGAnimatedString; addEventListener(type: K, listener: (this: SVGAElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGAElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGAElement: { prototype: SVGAElement; new(): SVGAElement; }; /** * The `SVGAngle` interface is used to represent a value that can be an <angle> or <number> value. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle) */ interface SVGAngle { /** * The **`unitType`** property of the SVGAngle interface is one of the unit type constants and represents the units in which this angle's value is expressed. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle/unitType) */ readonly unitType: number; /** * The `value` property of the SVGAngle interface represents the floating point value of the `` in degrees. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle/value) */ value: number; /** * The `valueAsString` property of the SVGAngle interface represents the angle's value as a string, in the units expressed by SVGAngle.unitType. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle/valueAsString) */ valueAsString: string; /** * The `valueInSpecifiedUnits` property of the SVGAngle interface represents the value of this angle as a number, in the units expressed by the angle's SVGAngle.unitType. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle/valueInSpecifiedUnits) */ valueInSpecifiedUnits: number; /** * The `convertToSpecifiedUnits()` method of the SVGAngle interface allows you to convert the angle's value to the specified unit type. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle/convertToSpecifiedUnits) */ convertToSpecifiedUnits(unitType: number): void; /** * The `newValueSpecifiedUnits()` method of the SVGAngle interface sets the value to a number with an associated SVGAngle.unitType, thereby replacing the values for all of the attributes on the object. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAngle/newValueSpecifiedUnits) */ newValueSpecifiedUnits(unitType: number, valueInSpecifiedUnits: number): void; readonly SVG_ANGLETYPE_UNKNOWN: 0; readonly SVG_ANGLETYPE_UNSPECIFIED: 1; readonly SVG_ANGLETYPE_DEG: 2; readonly SVG_ANGLETYPE_RAD: 3; readonly SVG_ANGLETYPE_GRAD: 4; } declare var SVGAngle: { prototype: SVGAngle; new(): SVGAngle; readonly SVG_ANGLETYPE_UNKNOWN: 0; readonly SVG_ANGLETYPE_UNSPECIFIED: 1; readonly SVG_ANGLETYPE_DEG: 2; readonly SVG_ANGLETYPE_RAD: 3; readonly SVG_ANGLETYPE_GRAD: 4; }; /** * The **`SVGAnimateElement`** interface corresponds to the animate element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimateElement) */ interface SVGAnimateElement extends SVGAnimationElement { addEventListener(type: K, listener: (this: SVGAnimateElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGAnimateElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGAnimateElement: { prototype: SVGAnimateElement; new(): SVGAnimateElement; }; /** * The **`SVGAnimateMotionElement`** interface corresponds to the animateMotion element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimateMotionElement) */ interface SVGAnimateMotionElement extends SVGAnimationElement { addEventListener(type: K, listener: (this: SVGAnimateMotionElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGAnimateMotionElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGAnimateMotionElement: { prototype: SVGAnimateMotionElement; new(): SVGAnimateMotionElement; }; /** * The `SVGAnimateTransformElement` interface corresponds to the animateTransform element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimateTransformElement) */ interface SVGAnimateTransformElement extends SVGAnimationElement { addEventListener(type: K, listener: (this: SVGAnimateTransformElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGAnimateTransformElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGAnimateTransformElement: { prototype: SVGAnimateTransformElement; new(): SVGAnimateTransformElement; }; /** * The **`SVGAnimatedAngle`** interface is used for attributes of basic type \ which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedAngle) */ interface SVGAnimatedAngle { /** * The **`animVal`** read-only property of the SVGAnimatedAngle interface represents the current animated value of the associated `` on an SVG element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedAngle/animVal) */ readonly animVal: SVGAngle; /** * The **`baseVal`** read-only property of the SVGAnimatedAngle interface represents the base (non-animated) value of the associated `` on an SVG element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedAngle/baseVal) */ readonly baseVal: SVGAngle; } declare var SVGAnimatedAngle: { prototype: SVGAnimatedAngle; new(): SVGAnimatedAngle; }; /** * The **`SVGAnimatedBoolean`** interface is used for attributes of type boolean which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedBoolean) */ interface SVGAnimatedBoolean { /** * The **`animVal`** read-only property of the SVGAnimatedBoolean interface represents the current animated value of the associated animatable boolean SVG attribute. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedBoolean/animVal) */ readonly animVal: boolean; /** * The **`baseVal`** property of the SVGAnimatedBoolean interface is the value of the associated animatable boolean SVG attribute in its base (none-animated) state. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedBoolean/baseVal) */ baseVal: boolean; } declare var SVGAnimatedBoolean: { prototype: SVGAnimatedBoolean; new(): SVGAnimatedBoolean; }; /** * The **`SVGAnimatedEnumeration`** interface describes attribute values which are constants from a particular enumeration and which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedEnumeration) */ interface SVGAnimatedEnumeration { /** * The **`animVal`** property of the SVGAnimatedEnumeration interface contains the current value of an SVG enumeration. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedEnumeration/animVal) */ readonly animVal: number; /** * The **`baseVal`** property of the SVGAnimatedEnumeration interface contains the initial value of an SVG enumeration. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedEnumeration/baseVal) */ baseVal: number; } declare var SVGAnimatedEnumeration: { prototype: SVGAnimatedEnumeration; new(): SVGAnimatedEnumeration; }; /** * The **`SVGAnimatedInteger`** interface is used for attributes of basic type \ which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedInteger) */ interface SVGAnimatedInteger { /** * The **`animVal`** property of the SVGAnimatedInteger interface represents the animated value of an ``. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedInteger/animVal) */ readonly animVal: number; /** * The **`baseVal`** property of the SVGAnimatedInteger interface represents the base (non-animated) value of an animatable ``. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedInteger/baseVal) */ baseVal: number; } declare var SVGAnimatedInteger: { prototype: SVGAnimatedInteger; new(): SVGAnimatedInteger; }; /** * The **`SVGAnimatedLength`** interface represents attributes of type \ which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedLength) */ interface SVGAnimatedLength { /** * The **`animVal`** property of the SVGAnimatedLength interface contains the current value of an SVG enumeration. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedLength/animVal) */ readonly animVal: SVGLength; /** * The **`baseVal`** property of the SVGAnimatedLength interface contains the initial value of an SVG enumeration. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedLength/baseVal) */ readonly baseVal: SVGLength; } declare var SVGAnimatedLength: { prototype: SVGAnimatedLength; new(): SVGAnimatedLength; }; /** * The **`SVGAnimatedLengthList`** interface is used for attributes of type SVGLengthList which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedLengthList) */ interface SVGAnimatedLengthList { /** * The **`animVal`** read-only property of the SVGAnimatedLengthList interface represents the animated value of an attribute that accepts a list of ``, ``, or `` values. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedLengthList/animVal) */ readonly animVal: SVGLengthList; /** * The **`baseVal`** read-only property of the SVGAnimatedLengthList interface represents the base (non-animated) value of an animatable attribute that accepts a list of ``, ``, or `` values. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedLengthList/baseVal) */ readonly baseVal: SVGLengthList; } declare var SVGAnimatedLengthList: { prototype: SVGAnimatedLengthList; new(): SVGAnimatedLengthList; }; /** * The **`SVGAnimatedNumber`** interface represents attributes of type \ which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedNumber) */ interface SVGAnimatedNumber { /** * The **`animVal`** read-only property of the SVGAnimatedNumber interface represents the animated value of an SVG element's numeric attribute. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedNumber/animVal) */ readonly animVal: number; /** * The **`baseVal`** property of the SVGAnimatedNumber interface represents the base (non-animated) value of an animatable numeric attribute. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedNumber/baseVal) */ baseVal: number; } declare var SVGAnimatedNumber: { prototype: SVGAnimatedNumber; new(): SVGAnimatedNumber; }; /** * The **`SVGAnimatedNumberList`** interface represents a list of attributes of type \ which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedNumberList) */ interface SVGAnimatedNumberList { /** * The **`animVal`** read-only property of the SVGAnimatedNumberList interface represents the current animated value of an animatable attribute that accepts a list of `` values. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedNumberList/animVal) */ readonly animVal: SVGNumberList; /** * The **`baseVal`** read-only property of the SVGAnimatedNumberList interface represents the base (non-animated) value of an animatable attribute that accepts a list of `` values. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedNumberList/baseVal) */ readonly baseVal: SVGNumberList; } declare var SVGAnimatedNumberList: { prototype: SVGAnimatedNumberList; new(): SVGAnimatedNumberList; }; interface SVGAnimatedPoints { /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGPolygonElement/animatedPoints) */ readonly animatedPoints: SVGPointList; /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGPolygonElement/points) */ readonly points: SVGPointList; } /** * The **`SVGAnimatedPreserveAspectRatio`** interface represents attributes of type SVGPreserveAspectRatio which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedPreserveAspectRatio) */ interface SVGAnimatedPreserveAspectRatio { /** * The **`animVal`** read-only property of the SVGAnimatedPreserveAspectRatio interface represents the value of the preserveAspectRatio attribute of an SVG element after any animations or transformations are applied. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedPreserveAspectRatio/animVal) */ readonly animVal: SVGPreserveAspectRatio; /** * The **`baseVal`** read-only property of the SVGAnimatedPreserveAspectRatio interface represents the base (non-animated) value of the preserveAspectRatio attribute of an SVG element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedPreserveAspectRatio/baseVal) */ readonly baseVal: SVGPreserveAspectRatio; } declare var SVGAnimatedPreserveAspectRatio: { prototype: SVGAnimatedPreserveAspectRatio; new(): SVGAnimatedPreserveAspectRatio; }; /** * The **`SVGAnimatedRect`** interface represents an SVGRect attribute that can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedRect) */ interface SVGAnimatedRect { /** * The **`animVal`** read-only property of the SVGAnimatedRect interface represents the current animated value of the `viewBox` attribute of an SVG element as a read-only DOMRectReadOnly object. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedRect/animVal) */ readonly animVal: DOMRectReadOnly; /** * The **`baseVal`** read-only property of the SVGAnimatedRect interface represents the current non-animated value of the `viewBox` attribute of an SVG element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedRect/baseVal) */ readonly baseVal: DOMRect; } declare var SVGAnimatedRect: { prototype: SVGAnimatedRect; new(): SVGAnimatedRect; }; /** * The **`SVGAnimatedString`** interface represents string attributes which can be animated from each SVG declaration. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedString) */ interface SVGAnimatedString { /** * The `animVal` read-only property of the SVGAnimatedString interface contains the same value as the SVGAnimatedString.baseVal property. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedString/animVal) */ readonly animVal: string; /** * BaseVal gets or sets the base value of the given attribute before any animations are applied. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedString/baseVal) */ baseVal: string; } declare var SVGAnimatedString: { prototype: SVGAnimatedString; new(): SVGAnimatedString; }; /** * The **`SVGAnimatedTransformList`** interface represents attributes which take a list of numbers and which can be animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedTransformList) */ interface SVGAnimatedTransformList { /** * The **`animVal`** read-only property of the SVGAnimatedTransformList interface represents the animated value of the `transform` attribute of an SVG element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedTransformList/animVal) */ readonly animVal: SVGTransformList; /** * The **`baseVal`** read-only property of the SVGAnimatedTransformList interface represents the non-animated value of the `transform` attribute of an SVG element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimatedTransformList/baseVal) */ readonly baseVal: SVGTransformList; } declare var SVGAnimatedTransformList: { prototype: SVGAnimatedTransformList; new(): SVGAnimatedTransformList; }; /** * The **`SVGAnimationElement`** interface is the base interface for all of the animation element interfaces: SVGAnimateElement, SVGSetElement, SVGAnimateColorElement, SVGAnimateMotionElement and SVGAnimateTransformElement. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement) */ interface SVGAnimationElement extends SVGElement, SVGTests { /** * The **`targetElement`** read-only property of the SVGAnimationElement interface refers to the element which is being animated. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/targetElement) */ readonly targetElement: SVGElement | null; /** * The SVGAnimationElement method `beginElement()` creates a begin instance time for the current time. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/beginElement) */ beginElement(): void; /** * The SVGAnimationElement method `beginElementAt()` creates a begin instance time for the current time plus the specified offset. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/beginElementAt) */ beginElementAt(offset: number): void; /** * The SVGAnimationElement method `endElement()` creates an end instance time for the current time. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/endElement) */ endElement(): void; /** * The SVGAnimationElement method `endElementAt()` creates an end instance time for the current time plus the specified offset. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/endElementAt) */ endElementAt(offset: number): void; /** * The SVGAnimationElement method `getCurrentTime()` returns a float representing the current time in seconds relative to time zero for the given time container. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/getCurrentTime) */ getCurrentTime(): number; /** * The SVGAnimationElement method `getSimpleDuration()` returns a float representing the number of seconds for the simple duration for this animation. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/getSimpleDuration) */ getSimpleDuration(): number; /** * The SVGAnimationElement method `getStartTime()` returns a float representing the start time, in seconds, for this animation element's current interval, if it exists, regardless of whether the interval has begun yet. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGAnimationElement/getStartTime) */ getStartTime(): number; addEventListener(type: K, listener: (this: SVGAnimationElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGAnimationElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGAnimationElement: { prototype: SVGAnimationElement; new(): SVGAnimationElement; }; /** * The **`SVGCircleElement`** interface is an interface for the circle element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGCircleElement) */ interface SVGCircleElement extends SVGGeometryElement { /** * The **`cx`** read-only property of the SVGCircleElement interface reflects the cx attribute of a circle element and by that defines the x-coordinate of the circle's center.< If unspecified, the effect is as if the value is set to `0`. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGCircleElement/cx) */ readonly cx: SVGAnimatedLength; /** * The **`cy`** read-only property of the SVGCircleElement interface reflects the cy attribute of a circle element and by that defines the y-coordinate of the circle's center. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGCircleElement/cy) */ readonly cy: SVGAnimatedLength; /** * The **`r`** read-only property of the SVGCircleElement interface reflects the r attribute of a circle element and by that defines the radius of the circle. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGCircleElement/r) */ readonly r: SVGAnimatedLength; addEventListener(type: K, listener: (this: SVGCircleElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGCircleElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGCircleElement: { prototype: SVGCircleElement; new(): SVGCircleElement; }; /** * The **`SVGClipPathElement`** interface provides access to the properties of clipPath elements, as well as methods to manipulate them. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGClipPathElement) */ interface SVGClipPathElement extends SVGElement { /** * The read-only **`clipPathUnits`** property of the SVGClipPathElement interface reflects the clipPathUnits attribute of a clipPath element which defines the coordinate system to use for the content of the element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGClipPathElement/clipPathUnits) */ readonly clipPathUnits: SVGAnimatedEnumeration; /** * The read-only **`transform`** property of the SVGClipPathElement interface reflects the transform attribute of a clipPath element, that is a list of transformations applied to the element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGClipPathElement/transform) */ readonly transform: SVGAnimatedTransformList; addEventListener(type: K, listener: (this: SVGClipPathElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGClipPathElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGClipPathElement: { prototype: SVGClipPathElement; new(): SVGClipPathElement; }; /** * The **`SVGComponentTransferFunctionElement`** interface represents a base interface used by the component transfer function interfaces. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement) */ interface SVGComponentTransferFunctionElement extends SVGElement { /** * The **`amplitude`** read-only property of the SVGComponentTransferFunctionElement interface reflects the amplitude attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/amplitude) */ readonly amplitude: SVGAnimatedNumber; /** * The **`exponent`** read-only property of the SVGComponentTransferFunctionElement interface reflects the exponent attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/exponent) */ readonly exponent: SVGAnimatedNumber; /** * The **`intercept`** read-only property of the SVGComponentTransferFunctionElement interface reflects the intercept attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/intercept) */ readonly intercept: SVGAnimatedNumber; /** * The **`offset`** read-only property of the SVGComponentTransferFunctionElement interface reflects the offset attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/offset) */ readonly offset: SVGAnimatedNumber; /** * The **`slope`** read-only property of the SVGComponentTransferFunctionElement interface reflects the slope attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/slope) */ readonly slope: SVGAnimatedNumber; /** * The **`tableValues`** read-only property of the SVGComponentTransferFunctionElement interface reflects the tableValues attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/tableValues) */ readonly tableValues: SVGAnimatedNumberList; /** * The **`type`** read-only property of the SVGComponentTransferFunctionElement interface reflects the type attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGComponentTransferFunctionElement/type) */ readonly type: SVGAnimatedEnumeration; readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: 0; readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: 1; readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: 2; readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: 3; readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: 4; readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: 5; addEventListener(type: K, listener: (this: SVGComponentTransferFunctionElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGComponentTransferFunctionElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGComponentTransferFunctionElement: { prototype: SVGComponentTransferFunctionElement; new(): SVGComponentTransferFunctionElement; readonly SVG_FECOMPONENTTRANSFER_TYPE_UNKNOWN: 0; readonly SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY: 1; readonly SVG_FECOMPONENTTRANSFER_TYPE_TABLE: 2; readonly SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE: 3; readonly SVG_FECOMPONENTTRANSFER_TYPE_LINEAR: 4; readonly SVG_FECOMPONENTTRANSFER_TYPE_GAMMA: 5; }; /** * The **`SVGDefsElement`** interface corresponds to the defs element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGDefsElement) */ interface SVGDefsElement extends SVGGraphicsElement { addEventListener(type: K, listener: (this: SVGDefsElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGDefsElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGDefsElement: { prototype: SVGDefsElement; new(): SVGDefsElement; }; /** * The **`SVGDescElement`** interface corresponds to the desc element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGDescElement) */ interface SVGDescElement extends SVGElement { addEventListener(type: K, listener: (this: SVGDescElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGDescElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGDescElement: { prototype: SVGDescElement; new(): SVGDescElement; }; interface SVGElementEventMap extends ElementEventMap, GlobalEventHandlersEventMap { } /** * All of the SVG DOM interfaces that correspond directly to elements in the SVG language derive from the `SVGElement` interface. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement) */ interface SVGElement extends Element, ElementCSSInlineStyle, GlobalEventHandlers, HTMLOrSVGElement { /** @deprecated */ readonly className: any; /** * The **`ownerSVGElement`** property of the SVGElement interface reflects the nearest ancestor svg element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement/ownerSVGElement) */ readonly ownerSVGElement: SVGSVGElement | null; /** * The **`viewportElement`** property of the SVGElement interface represents the `SVGElement` which established the current viewport. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGElement/viewportElement) */ readonly viewportElement: SVGElement | null; addEventListener(type: K, listener: (this: SVGElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGElement: { prototype: SVGElement; new(): SVGElement; }; /** * The **`SVGEllipseElement`** interface provides access to the properties of ellipse elements. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGEllipseElement) */ interface SVGEllipseElement extends SVGGeometryElement { /** * The **`cx`** read-only property of the SVGEllipseElement interface describes the x-axis coordinate of the center of the ellipse as an SVGAnimatedLength. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGEllipseElement/cx) */ readonly cx: SVGAnimatedLength; /** * The **`cy`** read-only property of the SVGEllipseElement interface describes the y-axis coordinate of the center of the ellipse as an SVGAnimatedLength. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGEllipseElement/cy) */ readonly cy: SVGAnimatedLength; /** * The **`rx`** read-only property of the SVGEllipseElement interface describes the x-axis radius of the ellipse as an SVGAnimatedLength. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGEllipseElement/rx) */ readonly rx: SVGAnimatedLength; /** * The **`ry`** read-only property of the SVGEllipseElement interface describes the y-axis radius of the ellipse as an SVGAnimatedLength. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGEllipseElement/ry) */ readonly ry: SVGAnimatedLength; addEventListener(type: K, listener: (this: SVGEllipseElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGEllipseElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGEllipseElement: { prototype: SVGEllipseElement; new(): SVGEllipseElement; }; /** * The **`SVGFEBlendElement`** interface corresponds to the feBlend element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEBlendElement) */ interface SVGFEBlendElement extends SVGElement, SVGFilterPrimitiveStandardAttributes { /** * The **`in1`** read-only property of the SVGFEBlendElement interface reflects the in attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEBlendElement/in1) */ readonly in1: SVGAnimatedString; /** * The **`in2`** read-only property of the SVGFEBlendElement interface reflects the in2 attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEBlendElement/in2) */ readonly in2: SVGAnimatedString; /** * The **`mode`** read-only property of the SVGFEBlendElement interface reflects the mode attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEBlendElement/mode) */ readonly mode: SVGAnimatedEnumeration; readonly SVG_FEBLEND_MODE_UNKNOWN: 0; readonly SVG_FEBLEND_MODE_NORMAL: 1; readonly SVG_FEBLEND_MODE_MULTIPLY: 2; readonly SVG_FEBLEND_MODE_SCREEN: 3; readonly SVG_FEBLEND_MODE_DARKEN: 4; readonly SVG_FEBLEND_MODE_LIGHTEN: 5; readonly SVG_FEBLEND_MODE_OVERLAY: 6; readonly SVG_FEBLEND_MODE_COLOR_DODGE: 7; readonly SVG_FEBLEND_MODE_COLOR_BURN: 8; readonly SVG_FEBLEND_MODE_HARD_LIGHT: 9; readonly SVG_FEBLEND_MODE_SOFT_LIGHT: 10; readonly SVG_FEBLEND_MODE_DIFFERENCE: 11; readonly SVG_FEBLEND_MODE_EXCLUSION: 12; readonly SVG_FEBLEND_MODE_HUE: 13; readonly SVG_FEBLEND_MODE_SATURATION: 14; readonly SVG_FEBLEND_MODE_COLOR: 15; readonly SVG_FEBLEND_MODE_LUMINOSITY: 16; addEventListener(type: K, listener: (this: SVGFEBlendElement, ev: SVGElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; removeEventListener(type: K, listener: (this: SVGFEBlendElement, ev: SVGElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } declare var SVGFEBlendElement: { prototype: SVGFEBlendElement; new(): SVGFEBlendElement; readonly SVG_FEBLEND_MODE_UNKNOWN: 0; readonly SVG_FEBLEND_MODE_NORMAL: 1; readonly SVG_FEBLEND_MODE_MULTIPLY: 2; readonly SVG_FEBLEND_MODE_SCREEN: 3; readonly SVG_FEBLEND_MODE_DARKEN: 4; readonly SVG_FEBLEND_MODE_LIGHTEN: 5; readonly SVG_FEBLEND_MODE_OVERLAY: 6; readonly SVG_FEBLEND_MODE_COLOR_DODGE: 7; readonly SVG_FEBLEND_MODE_COLOR_BURN: 8; readonly SVG_FEBLEND_MODE_HARD_LIGHT: 9; readonly SVG_FEBLEND_MODE_SOFT_LIGHT: 10; readonly SVG_FEBLEND_MODE_DIFFERENCE: 11; readonly SVG_FEBLEND_MODE_EXCLUSION: 12; readonly SVG_FEBLEND_MODE_HUE: 13; readonly SVG_FEBLEND_MODE_SATURATION: 14; readonly SVG_FEBLEND_MODE_COLOR: 15; readonly SVG_FEBLEND_MODE_LUMINOSITY: 16; }; /** * The **`SVGFEColorMatrixElement`** interface corresponds to the feColorMatrix element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEColorMatrixElement) */ interface SVGFEColorMatrixElement extends SVGElement, SVGFilterPrimitiveStandardAttributes { /** * The **`in1`** read-only property of the SVGFEColorMatrixElement interface reflects the in attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEColorMatrixElement/in1) */ readonly in1: SVGAnimatedString; /** * The **`type`** read-only property of the SVGFEColorMatrixElement interface reflects the type attribute of the given element. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/SVGFEColorMatrixElement/type) */ readonly type: SVGAnimatedEnumeration; /** * The **`values`** read-only property of the SVGFEColorMatrixElement interface reflects the values attribute of the given element. [a2eb755b-4d5c-4644-a39c-313b1b58f695](2025-06-02 12:59:40) - Intento 0 para actualizar CRM con datos de url de marca: { "data": [ { "code": "SUCCESS", "details": { "Modified_Time": "2025-06-02T13:59:39-04:00", "Modified_By": { "name": "Aptus Legal Administrator", "id": "4597192000000287001" }, "Created_Time": "2025-05-20T11:25:58-04:00", "id": "4597192000258709283", "Created_By": { "name": "Valentina Gomez Fernandez", "id": "4597192000026519400" } }, "message": "record updated", "status": "success" } ] } [a2eb755b-4d5c-4644-a39c-313b1b58f695](2025-06-02 12:59:40) - Proceso finalizado exitosamente, URL: https://aptuslegal.app/imagenesAptusLegal/arochi/LogosArochi/MAR-129795.png [b00e07eb-35e9-4af4-a320-d0c0abe4a2ab](2025-06-02 13:00:37) - Proceso de subida de imagen iniciado, data: {"source":"webhook","RefAL":"MAR-129915","MarcaId":"4597192000261400473","user":"bmeza@arochilindner.com"} [b00e07eb-35e9-4af4-a320-d0c0abe4a2ab](2025-06-02 13:00:44) - Tokens generados: 1000.4be251632257efabe3ac5db23e150b46.39d86cbfffa3687c56ee5a5e00de6370 [b00e07eb-35e9-4af4-a320-d0c0abe4a2ab](2025-06-02 13:00:44) - Intento 0 para obtener imagen de marca de CRM, respuesta: 200 [b00e07eb-35e9-4af4-a320-d0c0abe4a2ab](2025-06-02 13:00:44) - Imagen guardada localmente de manera exitosa [b00e07eb-35e9-4af4-a320-d0c0abe4a2ab](2025-06-02 13:00:46) - Intento 0 para actualizar CRM con datos de url de marca: { "data": [ { "code": "SUCCESS", "details": { "Modified_Time": "2025-06-02T14:00:45-04:00", "Modified_By": { "name": "Aptus Legal Administrator", "id": "4597192000000287001" }, "Created_Time": "2025-05-30T12:22:36-04:00", "id": "4597192000261400473", "Created_By": { "name": "Valentina Gomez Fernandez", "id": "4597192000026519400" } }, "message": "record updated", "status": "success" } ] } [b00e07eb-35e9-4af4-a320-d0c0abe4a2ab](2025-06-02 13:00:46) - Proceso finalizado exitosamente, URL: https://aptuslegal.app/imagenesAptusLegal/arochi/LogosArochi/MAR-129915.png [f87f19a0-759f-4449-ad03-718f5eb93f18](2025-06-02 13:01:55) - Proceso de subida de imagen iniciado, data: {"source":"webhook","RefAL":"MAR-129794","MarcaId":"4597192000258709223","user":"igrimaldo@arochilindner.com"} [f87f19a0-759f-4449-ad03-718f5eb93f18](2025-06-02 13:02:02) - Tokens generados: 1000.4be251632257efabe3ac5db23e150b46.39d86cbfffa3687c56ee5a5e00de6370 [f87f19a0-759f-4449-ad03-718f5eb93f18](2025-06-02 13:02:03) - Intento 0 para obtener imagen de marca de CRM, respuesta: 200 [f87f19a0-759f-4449-ad03-718f5eb93f18](2025-06-02 13:02:03) - Imagen guardada localmente de manera exitosa [f87f19a0-759f-4449-ad03-718f5eb93f18](2025-06-02 13:02:04) - Intento 0 para actualizar CRM con datos de url de marca: { "data": [ { "code": "SUCCESS", "details": { "Modified_Time": "2025-06-02T14:02:03-04:00", "Modified_By": { "name": "Aptus Legal Administrator", "id": "4597192000000287001" }, "Created_Time": "2025-05-20T11:25:29-04:00", "id": "4597192000258709223", "Created_By": { "name": "Valentina Gomez Fernandez", "id": "4597192000026519400" } }, "message": "record updated", "status": "success" } ] } [f87f19a0-759f-4449-ad03-718f5eb93f18](2025-06-02 13:02:04) - Proceso finalizado exitosamente, URL: https://aptuslegal.app/imagenesAptusLegal/arochi/LogosArochi/MAR-129794.png [53a5d0