Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion commands/docs/abbr.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: abbr
categories: |
platform
version: 0.115.1
version: 0.116.0
platform: |
Abbreviations related commands.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/abbr_list.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: abbr list
categories: |
platform
version: 0.115.1
version: 0.116.0
platform: |
List all defined abbreviations.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/alias.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: alias
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Alias a command (with optional flags) to a new name.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/all.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: all
categories: |
filters
version: 0.115.1
version: 0.116.0
filters: |
Test if every element of the input fulfills a predicate expression.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/ansi.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: ansi
categories: |
platform
version: 0.115.1
version: 0.116.0
platform: |
Output ANSI codes to change color and style of text.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/ansi_gradient.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: ansi gradient
categories: |
platform
version: 0.115.1
version: 0.116.0
platform: |
Add a color gradient (using ANSI color codes) to the given string.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/ansi_link.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: ansi link
categories: |
platform
version: 0.115.1
version: 0.116.0
platform: |
Add a link (using OSC 8 escape sequence) to the given string.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/ansi_strip.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: ansi strip
categories: |
platform
version: 0.115.1
version: 0.116.0
platform: |
Strip ANSI escape sequences from a string.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/any.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: any
categories: |
filters
version: 0.115.1
version: 0.116.0
filters: |
Tests if any element of the input fulfills a predicate expression.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/append.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: append
categories: |
filters
version: 0.115.1
version: 0.116.0
filters: |
Append any number of rows to a table.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/ast.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: ast
categories: |
debug
version: 0.115.1
version: 0.116.0
debug: |
Print the abstract syntax tree (ast) for a pipeline.
usage: |
Expand Down
3 changes: 2 additions & 1 deletion commands/docs/attr.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Various attributes for custom commands.
usage: |
Expand Down Expand Up @@ -42,4 +42,5 @@ You must use one of the following subcommands. Using this command as-is will onl
| [`attr complete external`](/commands/docs/attr_complete_external.md) | Attribute for enabling use of the external completer for internal commands. | built-in |
| [`attr deprecated`](/commands/docs/attr_deprecated.md) | Attribute for marking a command or flag as deprecated. | built-in |
| [`attr example`](/commands/docs/attr_example.md) | Attribute for adding examples to custom commands. | built-in |
| [`attr interactive`](/commands/docs/attr_interactive.md) | Attribute marking a completer as interactive. | built-in |
| [`attr search-terms`](/commands/docs/attr_search-terms.md) | Attribute for adding search terms to custom commands. | built-in |
2 changes: 1 addition & 1 deletion commands/docs/attr_category.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr category
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Attribute for adding a category to custom commands.
usage: |
Expand Down
6 changes: 3 additions & 3 deletions commands/docs/attr_complete.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr complete
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Attribute for using another command as a completion source for all arguments.
usage: |
Expand Down Expand Up @@ -38,8 +38,8 @@ contributors: false

Use another command as completion source.
```nu
> def complete-foo [spans: list<string>] {
[bar baz qux spam eggs] | where $it not-in $spans
> def complete-foo [token: record] {
[bar baz qux spam eggs] | where $it != $token.text
}

@complete 'complete-foo'
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/attr_complete_external.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr complete external
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Attribute for enabling use of the external completer for internal commands.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/attr_deprecated.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr deprecated
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Attribute for marking a command or flag as deprecated.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/attr_example.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr example
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Attribute for adding examples to custom commands.
usage: |
Expand Down
49 changes: 49 additions & 0 deletions commands/docs/attr_interactive.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
---
title: attr interactive
categories: |
core
version: 0.116.0
core: |
Attribute marking a completer as interactive.
usage: |
Attribute marking a completer as interactive.
editLink: false
contributors: false
---
<!-- This file is automatically generated. Please edit the command in https://github.com/nushell/nushell instead. -->

# `attr interactive` for [core](/commands/categories/core.md)

<div class='command-title'>Attribute marking a completer as interactive.</div>

## Command Type

`built-in`

## Signature

```> attr interactive {flags} ```


## Input/output types:

| input | output |
| ------- | ------ |
| nothing | bool |
## Examples

Drive a terminal picker from a completer, then attach it to an argument.
```nu
> @interactive
def pick-file [token: record] {
ls | get name | to text | ^fzf --query $token.text | lines
}

def open-file [path: string@pick-file] { open $path }

```

## Notes
An interactive completer runs on the line-editor thread, with the terminal to itself, instead of on the background completion worker. This lets it drive a terminal picker such as `fzf` or `input list`, which need stdin and the TTY. Every other completer stays on the worker, so it never blocks the line editor and its result can be cached; only completers that must own the terminal should opt in.

The attribute only chooses where a completer runs; it does not make the command one. Attach it as usual, `arg: type@name` or `@complete 'name'`; and the completion engine calls it with the `token` record when you press Tab. Called directly it is an ordinary command, so declare `token: record`: that way `pick-file foo` is rejected at the call site instead of failing deep inside the body on `$token.text`. To try a completer by hand, get a real record from `commandline complete --input`.
2 changes: 1 addition & 1 deletion commands/docs/attr_search-terms.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: attr search-terms
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Attribute for adding search terms to custom commands.
usage: |
Expand Down
5 changes: 3 additions & 2 deletions commands/docs/banner.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: banner
categories: |
default
version: 0.115.1
version: 0.116.0
default: |
Print a banner for Nushell with information about the project
usage: |
Expand All @@ -26,4 +26,5 @@ contributors: false

## Flags

- `--short`: Only show startup time
- `--short`: Only show the startup time
- `--no-startup-time`: Show the welcome message without the startup time
2 changes: 1 addition & 1 deletion commands/docs/bits.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Various commands for working with bits.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_and.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits and
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Performs bitwise and for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_not.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits not
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Performs logical negation on each bit.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_or.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits or
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Performs bitwise or for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_rol.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits rol
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Bitwise rotate left for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_ror.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits ror
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Bitwise rotate right for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_shl.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits shl
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Bitwise shift left for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_shr.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits shr
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Bitwise shift right for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bits_xor.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bits xor
categories: |
bits
version: 0.115.1
version: 0.116.0
bits: |
Performs bitwise xor for ints or binary values.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/break.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: break
categories: |
core
version: 0.115.1
version: 0.116.0
core: |
Break a loop.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Various commands for working with byte data.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes_add.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes add
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Add specified bytes to the binary input.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes_at.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes at
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Get bytes from the input defined by a range.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes_build.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes build
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Create a binary value from the provided arguments.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes_collect.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes collect
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Concatenate multiple binary into a single binary, with an optional separator between each.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes_ends-with.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes ends-with
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Check if binary data ends with a pattern.
usage: |
Expand Down
2 changes: 1 addition & 1 deletion commands/docs/bytes_index-of.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: bytes index-of
categories: |
bytes
version: 0.115.1
version: 0.116.0
bytes: |
Returns start index of first occurrence of pattern in bytes, or -1 if no match.
usage: |
Expand Down
Loading
Loading