diff --git a/commands/docs/alias.md b/commands/docs/alias.md index 129dcd07912..553822d7a27 100644 --- a/commands/docs/alias.md +++ b/commands/docs/alias.md @@ -2,7 +2,7 @@ title: alias categories: | core -version: 0.106.0 +version: 0.107.0 core: | Alias a command (with optional flags) to a new name. usage: | diff --git a/commands/docs/all.md b/commands/docs/all.md index 05a34be5432..dbbd4ce7597 100644 --- a/commands/docs/all.md +++ b/commands/docs/all.md @@ -2,7 +2,7 @@ title: all categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Test if every element of the input fulfills a predicate expression. usage: | diff --git a/commands/docs/ansi.md b/commands/docs/ansi.md index 5a1003ceb74..8d2af2c307a 100644 --- a/commands/docs/ansi.md +++ b/commands/docs/ansi.md @@ -2,7 +2,7 @@ title: ansi categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Output ANSI codes to change color and style of text. usage: | diff --git a/commands/docs/ansi_gradient.md b/commands/docs/ansi_gradient.md index 49a203d4656..1a3f9f216de 100644 --- a/commands/docs/ansi_gradient.md +++ b/commands/docs/ansi_gradient.md @@ -2,7 +2,7 @@ title: ansi gradient categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Add a color gradient (using ANSI color codes) to the given string. usage: | diff --git a/commands/docs/ansi_link.md b/commands/docs/ansi_link.md index 52d00de5c5e..481f549b241 100644 --- a/commands/docs/ansi_link.md +++ b/commands/docs/ansi_link.md @@ -2,7 +2,7 @@ title: ansi link categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Add a link (using OSC 8 escape sequence) to the given string. usage: | diff --git a/commands/docs/ansi_strip.md b/commands/docs/ansi_strip.md index 8d019e519db..367091cdd73 100644 --- a/commands/docs/ansi_strip.md +++ b/commands/docs/ansi_strip.md @@ -2,7 +2,7 @@ title: ansi strip categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Strip ANSI escape sequences from a string. usage: | diff --git a/commands/docs/any.md b/commands/docs/any.md index 58e1b4c3969..ee011a7ab15 100644 --- a/commands/docs/any.md +++ b/commands/docs/any.md @@ -2,7 +2,7 @@ title: any categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Tests if any element of the input fulfills a predicate expression. usage: | diff --git a/commands/docs/append.md b/commands/docs/append.md index 57fb8c0d64d..6f67beef3cf 100644 --- a/commands/docs/append.md +++ b/commands/docs/append.md @@ -2,7 +2,7 @@ title: append categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Append any number of rows to a table. usage: | diff --git a/commands/docs/ast.md b/commands/docs/ast.md index 34a8325a5cc..602033060c6 100644 --- a/commands/docs/ast.md +++ b/commands/docs/ast.md @@ -2,7 +2,7 @@ title: ast categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Print the abstract syntax tree (ast) for a pipeline. usage: | diff --git a/commands/docs/attr.md b/commands/docs/attr.md new file mode 100644 index 00000000000..d462b40fd98 --- /dev/null +++ b/commands/docs/attr.md @@ -0,0 +1,39 @@ +--- +title: attr +categories: | + core +version: 0.107.0 +core: | + Various attributes for custom commands. +usage: | + Various attributes for custom commands. +editLink: false +contributors: false +--- + + +# `attr` for [core](/commands/categories/core.md) + +
Various attributes for custom commands.
+ +## Signature + +```> attr {flags} ``` + + +## Input/output types: + +| input | output | +| ------- | ------ | +| nothing | string | +## Notes +You must use one of the following subcommands. Using this command as-is will only produce this help message. + +## Subcommands: + +| name | description | type | +| ---------------------------------------------------------- | ------------------------------------------------------ | -------- | +| [`attr category`](/commands/docs/attr_category.md) | Attribute for adding a category to custom 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 search-terms`](/commands/docs/attr_search-terms.md) | Attribute for adding search terms to custom commands. | built-in | \ No newline at end of file diff --git a/commands/docs/attr_category.md b/commands/docs/attr_category.md index 5b55641f4c8..b3a7d2ddde0 100644 --- a/commands/docs/attr_category.md +++ b/commands/docs/attr_category.md @@ -2,7 +2,7 @@ title: attr category categories: | core -version: 0.106.0 +version: 0.107.0 core: | Attribute for adding a category to custom commands. usage: | diff --git a/commands/docs/attr_deprecated.md b/commands/docs/attr_deprecated.md index 8e3690d3fc4..707a17f3815 100644 --- a/commands/docs/attr_deprecated.md +++ b/commands/docs/attr_deprecated.md @@ -2,7 +2,7 @@ title: attr deprecated categories: | core -version: 0.106.0 +version: 0.107.0 core: | Attribute for marking a command or flag as deprecated. usage: | diff --git a/commands/docs/attr_example.md b/commands/docs/attr_example.md index c168257e78e..c24762455a2 100644 --- a/commands/docs/attr_example.md +++ b/commands/docs/attr_example.md @@ -2,7 +2,7 @@ title: attr example categories: | core -version: 0.106.0 +version: 0.107.0 core: | Attribute for adding examples to custom commands. usage: | diff --git a/commands/docs/attr_search-terms.md b/commands/docs/attr_search-terms.md index 9911726f453..504fbe40bf7 100644 --- a/commands/docs/attr_search-terms.md +++ b/commands/docs/attr_search-terms.md @@ -2,7 +2,7 @@ title: attr search-terms categories: | core -version: 0.106.0 +version: 0.107.0 core: | Attribute for adding search terms to custom commands. usage: | diff --git a/commands/docs/banner.md b/commands/docs/banner.md index 9da356224fe..faff6e9b733 100644 --- a/commands/docs/banner.md +++ b/commands/docs/banner.md @@ -2,7 +2,7 @@ title: banner categories: | default -version: 0.106.0 +version: 0.107.0 default: | Print a banner for Nushell with information about the project usage: | diff --git a/commands/docs/bits.md b/commands/docs/bits.md index dfe3cb713ab..03d375c99b5 100644 --- a/commands/docs/bits.md +++ b/commands/docs/bits.md @@ -2,7 +2,7 @@ title: bits categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Various commands for working with bits. usage: | diff --git a/commands/docs/bits_and.md b/commands/docs/bits_and.md index 8a31b7f09cb..d310fe4bee4 100644 --- a/commands/docs/bits_and.md +++ b/commands/docs/bits_and.md @@ -2,7 +2,7 @@ title: bits and categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Performs bitwise and for ints or binary values. usage: | diff --git a/commands/docs/bits_not.md b/commands/docs/bits_not.md index e98814e9c5d..2167907c026 100644 --- a/commands/docs/bits_not.md +++ b/commands/docs/bits_not.md @@ -2,7 +2,7 @@ title: bits not categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Performs logical negation on each bit. usage: | diff --git a/commands/docs/bits_or.md b/commands/docs/bits_or.md index 530ad8117e8..695dc4dd347 100644 --- a/commands/docs/bits_or.md +++ b/commands/docs/bits_or.md @@ -2,7 +2,7 @@ title: bits or categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Performs bitwise or for ints or binary values. usage: | diff --git a/commands/docs/bits_rol.md b/commands/docs/bits_rol.md index 9bdfba204f0..575e8de35c9 100644 --- a/commands/docs/bits_rol.md +++ b/commands/docs/bits_rol.md @@ -2,7 +2,7 @@ title: bits rol categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Bitwise rotate left for ints or binary values. usage: | @@ -23,7 +23,7 @@ contributors: false ## Flags - `--signed, -s`: always treat input number as a signed number - - `--number-bytes, -n {int}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` + - `--number-bytes, -n {int}`: the word size in number of bytes. Must be `1`, `2`, `4`, or `8` (defaults to the smallest of those that fits the input number) ## Parameters diff --git a/commands/docs/bits_ror.md b/commands/docs/bits_ror.md index 611f3a8b413..0f64a1c91b9 100644 --- a/commands/docs/bits_ror.md +++ b/commands/docs/bits_ror.md @@ -2,7 +2,7 @@ title: bits ror categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Bitwise rotate right for ints or binary values. usage: | @@ -23,7 +23,7 @@ contributors: false ## Flags - `--signed, -s`: always treat input number as a signed number - - `--number-bytes, -n {int}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` + - `--number-bytes, -n {int}`: the word size in number of bytes. Must be `1`, `2`, `4`, or `8` (defaults to the smallest of those that fits the input number) ## Parameters diff --git a/commands/docs/bits_shl.md b/commands/docs/bits_shl.md index fafacc2f4f0..a040bf4e74d 100644 --- a/commands/docs/bits_shl.md +++ b/commands/docs/bits_shl.md @@ -2,7 +2,7 @@ title: bits shl categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Bitwise shift left for ints or binary values. usage: | @@ -23,7 +23,7 @@ contributors: false ## Flags - `--signed, -s`: always treat input number as a signed number - - `--number-bytes, -n {int}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` + - `--number-bytes, -n {int}`: the word size in number of bytes. Must be `1`, `2`, `4`, or `8` (defaults to the smallest of those that fits the input number) ## Parameters diff --git a/commands/docs/bits_shr.md b/commands/docs/bits_shr.md index a09a1961dfa..bba93ddc91f 100644 --- a/commands/docs/bits_shr.md +++ b/commands/docs/bits_shr.md @@ -2,7 +2,7 @@ title: bits shr categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Bitwise shift right for ints or binary values. usage: | @@ -23,7 +23,7 @@ contributors: false ## Flags - `--signed, -s`: always treat input number as a signed number - - `--number-bytes, -n {int}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` + - `--number-bytes, -n {int}`: the word size in number of bytes. Must be `1`, `2`, `4`, or `8` (defaults to the smallest of those that fits the input number) ## Parameters diff --git a/commands/docs/bits_xor.md b/commands/docs/bits_xor.md index 3b87f40c898..acd9b88a5de 100644 --- a/commands/docs/bits_xor.md +++ b/commands/docs/bits_xor.md @@ -2,7 +2,7 @@ title: bits xor categories: | bits -version: 0.106.0 +version: 0.107.0 bits: | Performs bitwise xor for ints or binary values. usage: | diff --git a/commands/docs/break.md b/commands/docs/break.md index 24b526f97c8..0802675f0e7 100644 --- a/commands/docs/break.md +++ b/commands/docs/break.md @@ -2,7 +2,7 @@ title: break categories: | core -version: 0.106.0 +version: 0.107.0 core: | Break a loop. usage: | diff --git a/commands/docs/bytes.md b/commands/docs/bytes.md index 92af563380a..24ba8d2e5af 100644 --- a/commands/docs/bytes.md +++ b/commands/docs/bytes.md @@ -2,7 +2,7 @@ title: bytes categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Various commands for working with byte data. usage: | diff --git a/commands/docs/bytes_add.md b/commands/docs/bytes_add.md index 7cb14a828fd..b569ef9bbc7 100644 --- a/commands/docs/bytes_add.md +++ b/commands/docs/bytes_add.md @@ -2,7 +2,7 @@ title: bytes add categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Add specified bytes to the input. usage: | diff --git a/commands/docs/bytes_at.md b/commands/docs/bytes_at.md index 737de452c8c..ff3e4367f20 100644 --- a/commands/docs/bytes_at.md +++ b/commands/docs/bytes_at.md @@ -2,7 +2,7 @@ title: bytes at categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Get bytes defined by a range. usage: | diff --git a/commands/docs/bytes_build.md b/commands/docs/bytes_build.md index d428160580b..65656aef6b0 100644 --- a/commands/docs/bytes_build.md +++ b/commands/docs/bytes_build.md @@ -2,7 +2,7 @@ title: bytes build categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Create bytes from the arguments. usage: | diff --git a/commands/docs/bytes_collect.md b/commands/docs/bytes_collect.md index be571a1a486..a5a99b3ce63 100644 --- a/commands/docs/bytes_collect.md +++ b/commands/docs/bytes_collect.md @@ -2,7 +2,7 @@ title: bytes collect categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Concatenate multiple binary into a single binary, with an optional separator between each. usage: | diff --git a/commands/docs/bytes_ends-with.md b/commands/docs/bytes_ends-with.md index 4b52868ff9e..fee90c4d6eb 100644 --- a/commands/docs/bytes_ends-with.md +++ b/commands/docs/bytes_ends-with.md @@ -2,7 +2,7 @@ title: bytes ends-with categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Check if bytes ends with a pattern. usage: | diff --git a/commands/docs/bytes_index-of.md b/commands/docs/bytes_index-of.md index 706990798d2..53d51b2da87 100644 --- a/commands/docs/bytes_index-of.md +++ b/commands/docs/bytes_index-of.md @@ -2,7 +2,7 @@ title: bytes index-of categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Returns start index of first occurrence of pattern in bytes, or -1 if no match. usage: | diff --git a/commands/docs/bytes_length.md b/commands/docs/bytes_length.md index 723b7bc9cac..e20d6d6b07f 100644 --- a/commands/docs/bytes_length.md +++ b/commands/docs/bytes_length.md @@ -2,7 +2,7 @@ title: bytes length categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Output the length of any bytes in the pipeline. usage: | diff --git a/commands/docs/bytes_remove.md b/commands/docs/bytes_remove.md index bdbb882cfe1..a67c1071a74 100644 --- a/commands/docs/bytes_remove.md +++ b/commands/docs/bytes_remove.md @@ -2,7 +2,7 @@ title: bytes remove categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Remove bytes. usage: | diff --git a/commands/docs/bytes_replace.md b/commands/docs/bytes_replace.md index 5324b492ea1..d96ab25672d 100644 --- a/commands/docs/bytes_replace.md +++ b/commands/docs/bytes_replace.md @@ -2,7 +2,7 @@ title: bytes replace categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Find and replace binary. usage: | diff --git a/commands/docs/bytes_reverse.md b/commands/docs/bytes_reverse.md index 0746097b835..3f82de54ea6 100644 --- a/commands/docs/bytes_reverse.md +++ b/commands/docs/bytes_reverse.md @@ -2,7 +2,7 @@ title: bytes reverse categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Reverse the bytes in the pipeline. usage: | diff --git a/commands/docs/bytes_split.md b/commands/docs/bytes_split.md index fbf0b2dc6d0..8ce13f04fc5 100644 --- a/commands/docs/bytes_split.md +++ b/commands/docs/bytes_split.md @@ -2,7 +2,7 @@ title: bytes split categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Split input into multiple items using a separator. usage: | diff --git a/commands/docs/bytes_starts-with.md b/commands/docs/bytes_starts-with.md index 10507346ec5..698e9a8b3ea 100644 --- a/commands/docs/bytes_starts-with.md +++ b/commands/docs/bytes_starts-with.md @@ -2,7 +2,7 @@ title: bytes starts-with categories: | bytes -version: 0.106.0 +version: 0.107.0 bytes: | Check if bytes starts with a pattern. usage: | diff --git a/commands/docs/cal.md b/commands/docs/cal.md index ffebff205e1..f80b5c09d8a 100644 --- a/commands/docs/cal.md +++ b/commands/docs/cal.md @@ -2,7 +2,7 @@ title: cal categories: | generators -version: 0.106.0 +version: 0.107.0 generators: | Display a calendar. usage: | diff --git a/commands/docs/cd.md b/commands/docs/cd.md index 5972972592f..b33ac7e281e 100644 --- a/commands/docs/cd.md +++ b/commands/docs/cd.md @@ -2,7 +2,7 @@ title: cd categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Change directory. usage: | diff --git a/commands/docs/char.md b/commands/docs/char.md index 760b0f740ae..18c12c58140 100644 --- a/commands/docs/char.md +++ b/commands/docs/char.md @@ -2,7 +2,7 @@ title: char categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Output special characters (e.g., 'newline'). usage: | diff --git a/commands/docs/chunk-by.md b/commands/docs/chunk-by.md index 139e08586b7..b65b1530bcb 100644 --- a/commands/docs/chunk-by.md +++ b/commands/docs/chunk-by.md @@ -2,7 +2,7 @@ title: chunk-by categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Divides a sequence into sub-sequences based on a closure. usage: | diff --git a/commands/docs/chunks.md b/commands/docs/chunks.md index cc821fd8c24..b9c676881b2 100644 --- a/commands/docs/chunks.md +++ b/commands/docs/chunks.md @@ -2,7 +2,7 @@ title: chunks categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Divide a list, table or binary input into chunks of `chunk_size`. usage: | diff --git a/commands/docs/clear.md b/commands/docs/clear.md index 3cdd19f38bd..241a2798aea 100644 --- a/commands/docs/clear.md +++ b/commands/docs/clear.md @@ -2,7 +2,7 @@ title: clear categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Clear the terminal. usage: | diff --git a/commands/docs/collect.md b/commands/docs/collect.md index b80dfde93fe..f68fbce17f8 100644 --- a/commands/docs/collect.md +++ b/commands/docs/collect.md @@ -2,7 +2,7 @@ title: collect categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Collect a stream into a value. usage: | diff --git a/commands/docs/columns.md b/commands/docs/columns.md index 92524dce985..d29a599a80d 100644 --- a/commands/docs/columns.md +++ b/commands/docs/columns.md @@ -2,7 +2,7 @@ title: columns categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Given a record or table, produce a list of its columns' names. usage: | diff --git a/commands/docs/commandline.md b/commands/docs/commandline.md index 95e8760dfc7..e45cc5b74dc 100644 --- a/commands/docs/commandline.md +++ b/commands/docs/commandline.md @@ -2,7 +2,7 @@ title: commandline categories: | core -version: 0.106.0 +version: 0.107.0 core: | View the current command line input buffer. usage: | diff --git a/commands/docs/commandline_edit.md b/commands/docs/commandline_edit.md index 4b9bc812b2b..a4a3fdd3b49 100644 --- a/commands/docs/commandline_edit.md +++ b/commands/docs/commandline_edit.md @@ -2,7 +2,7 @@ title: commandline edit categories: | core -version: 0.106.0 +version: 0.107.0 core: | Modify the current command line input buffer. usage: | @@ -25,6 +25,7 @@ contributors: false - `--append, -a`: appends the string to the end of the buffer - `--insert, -i`: inserts the string into the buffer at the cursor position - `--replace, -r`: replaces the current contents of the buffer (default) + - `--accept, -A`: immediately executes the result after edit ## Parameters diff --git a/commands/docs/commandline_get-cursor.md b/commands/docs/commandline_get-cursor.md index 2e74ca87204..1bfb2c3a007 100644 --- a/commands/docs/commandline_get-cursor.md +++ b/commands/docs/commandline_get-cursor.md @@ -2,7 +2,7 @@ title: commandline get-cursor categories: | core -version: 0.106.0 +version: 0.107.0 core: | Get the current cursor position. usage: | diff --git a/commands/docs/commandline_set-cursor.md b/commands/docs/commandline_set-cursor.md index a5e36f485c0..10d0b224634 100644 --- a/commands/docs/commandline_set-cursor.md +++ b/commands/docs/commandline_set-cursor.md @@ -2,7 +2,7 @@ title: commandline set-cursor categories: | core -version: 0.106.0 +version: 0.107.0 core: | Set the current cursor position. usage: | diff --git a/commands/docs/compact.md b/commands/docs/compact.md index c7ebfa9d651..54ec79d86ec 100644 --- a/commands/docs/compact.md +++ b/commands/docs/compact.md @@ -2,7 +2,7 @@ title: compact categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Creates a table with non-empty rows. usage: | diff --git a/commands/docs/complete.md b/commands/docs/complete.md index 7245c72d86b..9ce836e578e 100644 --- a/commands/docs/complete.md +++ b/commands/docs/complete.md @@ -2,7 +2,7 @@ title: complete categories: | system -version: 0.106.0 +version: 0.107.0 system: | Capture the outputs and exit code from an external piped in command in a nushell table. usage: | diff --git a/commands/docs/config.md b/commands/docs/config.md index 62541bf6672..a0a5b41eb5e 100644 --- a/commands/docs/config.md +++ b/commands/docs/config.md @@ -2,7 +2,7 @@ title: config categories: | env -version: 0.106.0 +version: 0.107.0 env: | Edit nushell configuration files. usage: | diff --git a/commands/docs/config_env.md b/commands/docs/config_env.md index e9bb4a1c1b4..1214caba6d5 100644 --- a/commands/docs/config_env.md +++ b/commands/docs/config_env.md @@ -2,7 +2,7 @@ title: config env categories: | env -version: 0.106.0 +version: 0.107.0 env: | Edit nu environment configurations. usage: | diff --git a/commands/docs/config_flatten.md b/commands/docs/config_flatten.md index 89861cf0f83..db32a1981fb 100644 --- a/commands/docs/config_flatten.md +++ b/commands/docs/config_flatten.md @@ -2,7 +2,7 @@ title: config flatten categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Show the current configuration in a flattened form. usage: | diff --git a/commands/docs/config_nu.md b/commands/docs/config_nu.md index 9644ebc85f2..719d236b8c1 100644 --- a/commands/docs/config_nu.md +++ b/commands/docs/config_nu.md @@ -2,7 +2,7 @@ title: config nu categories: | env -version: 0.106.0 +version: 0.107.0 env: | Edit nu configurations. usage: | diff --git a/commands/docs/config_reset.md b/commands/docs/config_reset.md index 40ec52be55c..3351b9ca578 100644 --- a/commands/docs/config_reset.md +++ b/commands/docs/config_reset.md @@ -2,7 +2,7 @@ title: config reset categories: | env -version: 0.106.0 +version: 0.107.0 env: | Reset nushell environment configurations to default, and saves old config files in the config location as oldconfig.nu and oldenv.nu. usage: | diff --git a/commands/docs/config_use-colors.md b/commands/docs/config_use-colors.md index 1250a9d36ae..92671860185 100644 --- a/commands/docs/config_use-colors.md +++ b/commands/docs/config_use-colors.md @@ -2,7 +2,7 @@ title: config use-colors categories: | env -version: 0.106.0 +version: 0.107.0 env: | Get the configuration for color output. usage: | diff --git a/commands/docs/const.md b/commands/docs/const.md index e9b05c078b6..3b6680e5107 100644 --- a/commands/docs/const.md +++ b/commands/docs/const.md @@ -2,7 +2,7 @@ title: const categories: | core -version: 0.106.0 +version: 0.107.0 core: | Create a parse-time constant. usage: | diff --git a/commands/docs/continue.md b/commands/docs/continue.md index 3d5f23ba563..4721340924e 100644 --- a/commands/docs/continue.md +++ b/commands/docs/continue.md @@ -2,7 +2,7 @@ title: continue categories: | core -version: 0.106.0 +version: 0.107.0 core: | Continue a loop from the next iteration. usage: | diff --git a/commands/docs/cp.md b/commands/docs/cp.md index b8bc6cbd739..2d705b4dbac 100644 --- a/commands/docs/cp.md +++ b/commands/docs/cp.md @@ -2,7 +2,7 @@ title: cp categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Copy files using uutils/coreutils cp. usage: | diff --git a/commands/docs/date.md b/commands/docs/date.md index 13fd5924caa..cb23f2c8ff7 100644 --- a/commands/docs/date.md +++ b/commands/docs/date.md @@ -2,7 +2,7 @@ title: date categories: | date -version: 0.106.0 +version: 0.107.0 date: | Date-related commands. usage: | diff --git a/commands/docs/date_format.md b/commands/docs/date_format.md index 1a445bf8cad..cda71d1a664 100644 --- a/commands/docs/date_format.md +++ b/commands/docs/date_format.md @@ -2,7 +2,7 @@ title: date format categories: | removed -version: 0.106.0 +version: 0.107.0 removed: | Removed command: use `format date` instead. usage: | diff --git a/commands/docs/date_from-human.md b/commands/docs/date_from-human.md index 6ec1e771b2c..4e4714243e9 100644 --- a/commands/docs/date_from-human.md +++ b/commands/docs/date_from-human.md @@ -2,7 +2,7 @@ title: date from-human categories: | date -version: 0.106.0 +version: 0.107.0 date: | Convert a human readable datetime string to a datetime. usage: | diff --git a/commands/docs/date_humanize.md b/commands/docs/date_humanize.md index 6f202e9e902..de930d972c4 100644 --- a/commands/docs/date_humanize.md +++ b/commands/docs/date_humanize.md @@ -2,7 +2,7 @@ title: date humanize categories: | date -version: 0.106.0 +version: 0.107.0 date: | Print a 'humanized' format for the date, relative to now. usage: | diff --git a/commands/docs/date_list-timezone.md b/commands/docs/date_list-timezone.md index df57b52b58b..9e89754f807 100644 --- a/commands/docs/date_list-timezone.md +++ b/commands/docs/date_list-timezone.md @@ -2,7 +2,7 @@ title: date list-timezone categories: | date -version: 0.106.0 +version: 0.107.0 date: | List supported time zones. usage: | diff --git a/commands/docs/date_now.md b/commands/docs/date_now.md index 0c8449498e5..35ed6569288 100644 --- a/commands/docs/date_now.md +++ b/commands/docs/date_now.md @@ -2,7 +2,7 @@ title: date now categories: | date -version: 0.106.0 +version: 0.107.0 date: | Get the current date. usage: | diff --git a/commands/docs/date_to-timezone.md b/commands/docs/date_to-timezone.md index 2ae09214996..3e6899b809c 100644 --- a/commands/docs/date_to-timezone.md +++ b/commands/docs/date_to-timezone.md @@ -2,7 +2,7 @@ title: date to-timezone categories: | date -version: 0.106.0 +version: 0.107.0 date: | Convert a date to a given time zone. usage: | diff --git a/commands/docs/debug.md b/commands/docs/debug.md index 9f9d7eb0052..df3a789a5cb 100644 --- a/commands/docs/debug.md +++ b/commands/docs/debug.md @@ -2,7 +2,7 @@ title: debug categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Debug print the value(s) piped in. usage: | diff --git a/commands/docs/debug_env.md b/commands/docs/debug_env.md index d67d19b1eae..45dd3ecc811 100644 --- a/commands/docs/debug_env.md +++ b/commands/docs/debug_env.md @@ -2,7 +2,7 @@ title: debug env categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Show environment variables as external commands would get it. usage: | diff --git a/commands/docs/debug_experimental-options.md b/commands/docs/debug_experimental-options.md index 4b8355f8773..5cd9233fc70 100644 --- a/commands/docs/debug_experimental-options.md +++ b/commands/docs/debug_experimental-options.md @@ -2,7 +2,7 @@ title: debug experimental-options categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Show all experimental options. usage: | diff --git a/commands/docs/debug_info.md b/commands/docs/debug_info.md index 30ec1010e1f..b7903c3f05e 100644 --- a/commands/docs/debug_info.md +++ b/commands/docs/debug_info.md @@ -2,7 +2,7 @@ title: debug info categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | View process memory info. usage: | diff --git a/commands/docs/debug_profile.md b/commands/docs/debug_profile.md index fdb21d3bbda..dc9edec4a07 100644 --- a/commands/docs/debug_profile.md +++ b/commands/docs/debug_profile.md @@ -2,7 +2,7 @@ title: debug profile categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Profile pipeline elements in a closure. usage: | diff --git a/commands/docs/decode.md b/commands/docs/decode.md index 20facda2ee9..b02e3f7e0d9 100644 --- a/commands/docs/decode.md +++ b/commands/docs/decode.md @@ -2,7 +2,7 @@ title: decode categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Decode bytes into a string. usage: | diff --git a/commands/docs/decode_base32.md b/commands/docs/decode_base32.md index 8753491e54a..09b3ff5c8da 100644 --- a/commands/docs/decode_base32.md +++ b/commands/docs/decode_base32.md @@ -2,7 +2,7 @@ title: decode base32 categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Decode a Base32 value. usage: | diff --git a/commands/docs/decode_base32hex.md b/commands/docs/decode_base32hex.md index e3056b17ef3..231a26ef835 100644 --- a/commands/docs/decode_base32hex.md +++ b/commands/docs/decode_base32hex.md @@ -2,7 +2,7 @@ title: decode base32hex categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Encode a base32hex value. usage: | diff --git a/commands/docs/decode_base64.md b/commands/docs/decode_base64.md index b528e5282a5..a745890708a 100644 --- a/commands/docs/decode_base64.md +++ b/commands/docs/decode_base64.md @@ -2,7 +2,7 @@ title: decode base64 categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Decode a Base64 value. usage: | diff --git a/commands/docs/decode_hex.md b/commands/docs/decode_hex.md index c4f12eb289d..9a501449c0f 100644 --- a/commands/docs/decode_hex.md +++ b/commands/docs/decode_hex.md @@ -2,7 +2,7 @@ title: decode hex categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Hex decode a value. usage: | diff --git a/commands/docs/def.md b/commands/docs/def.md index d74cb5569b5..fe94c76e672 100644 --- a/commands/docs/def.md +++ b/commands/docs/def.md @@ -2,7 +2,7 @@ title: def categories: | core -version: 0.106.0 +version: 0.107.0 core: | Define a custom command. usage: | diff --git a/commands/docs/default.md b/commands/docs/default.md index 3207b296b01..835b9efab96 100644 --- a/commands/docs/default.md +++ b/commands/docs/default.md @@ -2,7 +2,7 @@ title: default categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Sets a default value if a row's column is missing or null. usage: | diff --git a/commands/docs/describe.md b/commands/docs/describe.md index 0d3d2b3053a..670bbe9bef0 100644 --- a/commands/docs/describe.md +++ b/commands/docs/describe.md @@ -2,7 +2,7 @@ title: describe categories: | core -version: 0.106.0 +version: 0.107.0 core: | Describe the type and structure of the value(s) piped in. usage: | diff --git a/commands/docs/detect.md b/commands/docs/detect.md new file mode 100644 index 00000000000..d769965792a --- /dev/null +++ b/commands/docs/detect.md @@ -0,0 +1,36 @@ +--- +title: detect +categories: | + strings +version: 0.107.0 +strings: | + Various commands for detecting things. +usage: | + Various commands for detecting things. +editLink: false +contributors: false +--- + + +# `detect` for [strings](/commands/categories/strings.md) + +
Various commands for detecting things.
+ +## Signature + +```> detect {flags} ``` + + +## Input/output types: + +| input | output | +| ------- | ------ | +| nothing | string | +## Notes +You must use one of the following subcommands. Using this command as-is will only produce this help message. + +## Subcommands: + +| name | description | type | +| ---------------------------------------------------- | ---------------------------------------------------------- | -------- | +| [`detect columns`](/commands/docs/detect_columns.md) | Attempt to automatically split text into multiple columns. | built-in | \ No newline at end of file diff --git a/commands/docs/detect_columns.md b/commands/docs/detect_columns.md index def71b32e8d..e26d92946df 100644 --- a/commands/docs/detect_columns.md +++ b/commands/docs/detect_columns.md @@ -2,7 +2,7 @@ title: detect columns categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Attempt to automatically split text into multiple columns. usage: | diff --git a/commands/docs/do.md b/commands/docs/do.md index 3c40a19b98d..a341f2f882b 100644 --- a/commands/docs/do.md +++ b/commands/docs/do.md @@ -2,7 +2,7 @@ title: do categories: | core -version: 0.106.0 +version: 0.107.0 core: | Run a closure, providing it with the pipeline input. usage: | diff --git a/commands/docs/drop.md b/commands/docs/drop.md index 323ff65d9e5..39a64b16be6 100644 --- a/commands/docs/drop.md +++ b/commands/docs/drop.md @@ -2,7 +2,7 @@ title: drop categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Remove items/rows from the end of the input list/table. Counterpart of `skip`. Opposite of `last`. usage: | diff --git a/commands/docs/drop_column.md b/commands/docs/drop_column.md index c12a0f70863..3ffa4ca9807 100644 --- a/commands/docs/drop_column.md +++ b/commands/docs/drop_column.md @@ -2,7 +2,7 @@ title: drop column categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Remove N columns at the right-hand end of the input table. To remove columns by name, use `reject`. usage: | diff --git a/commands/docs/drop_nth.md b/commands/docs/drop_nth.md index 8798417c623..d78d20fe2d6 100644 --- a/commands/docs/drop_nth.md +++ b/commands/docs/drop_nth.md @@ -2,7 +2,7 @@ title: drop nth categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Drop the selected rows. usage: | diff --git a/commands/docs/du.md b/commands/docs/du.md index b935aa2488d..0bc1a504df5 100644 --- a/commands/docs/du.md +++ b/commands/docs/du.md @@ -2,7 +2,7 @@ title: du categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Find disk usage sizes of specified items. usage: | diff --git a/commands/docs/each.md b/commands/docs/each.md index 194dbdd3bf4..7991b5a44a2 100644 --- a/commands/docs/each.md +++ b/commands/docs/each.md @@ -2,7 +2,7 @@ title: each categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Run a closure on each row of the input list, creating a new list with the results. usage: | @@ -90,6 +90,12 @@ Iterate over each element, keeping null results ``` +Update value if not null, otherwise do nothing +```nu +> $env.name? | each { $"hello ($in)" } | default "bye" + +``` + ## Notes Since tables are lists of records, passing a table into 'each' will iterate over each record, not necessarily each cell within it. diff --git a/commands/docs/each_while.md b/commands/docs/each_while.md index 88914dd96ea..87f2fcabc07 100644 --- a/commands/docs/each_while.md +++ b/commands/docs/each_while.md @@ -2,7 +2,7 @@ title: each while categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Run a closure on each row of the input list until a null is found, then create a new list with the results. usage: | diff --git a/commands/docs/echo.md b/commands/docs/echo.md index 61fe2dae0b3..236b92547d3 100644 --- a/commands/docs/echo.md +++ b/commands/docs/echo.md @@ -2,7 +2,7 @@ title: echo categories: | core -version: 0.106.0 +version: 0.107.0 core: | Returns its arguments, ignoring the piped-in value. usage: | diff --git a/commands/docs/encode.md b/commands/docs/encode.md index b2342522726..f8829fee7f4 100644 --- a/commands/docs/encode.md +++ b/commands/docs/encode.md @@ -2,7 +2,7 @@ title: encode categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Encode a string into bytes. usage: | diff --git a/commands/docs/encode_base32.md b/commands/docs/encode_base32.md index 7b816692189..eb469f8072a 100644 --- a/commands/docs/encode_base32.md +++ b/commands/docs/encode_base32.md @@ -2,7 +2,7 @@ title: encode base32 categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Encode a string or binary value using Base32. usage: | diff --git a/commands/docs/encode_base32hex.md b/commands/docs/encode_base32hex.md index 773e3e0a983..e0c0eb50dd2 100644 --- a/commands/docs/encode_base32hex.md +++ b/commands/docs/encode_base32hex.md @@ -2,7 +2,7 @@ title: encode base32hex categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Encode a binary value or a string using base32hex. usage: | diff --git a/commands/docs/encode_base64.md b/commands/docs/encode_base64.md index 7432cb52f30..80446493d30 100644 --- a/commands/docs/encode_base64.md +++ b/commands/docs/encode_base64.md @@ -2,7 +2,7 @@ title: encode base64 categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Encode a string or binary value using Base64. usage: | diff --git a/commands/docs/encode_hex.md b/commands/docs/encode_hex.md index 7a790eb0b09..38b8a5bdcb8 100644 --- a/commands/docs/encode_hex.md +++ b/commands/docs/encode_hex.md @@ -2,7 +2,7 @@ title: encode hex categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Hex encode a binary value or a string. usage: | diff --git a/commands/docs/enumerate.md b/commands/docs/enumerate.md index fb12188029b..3de9784f76f 100644 --- a/commands/docs/enumerate.md +++ b/commands/docs/enumerate.md @@ -2,7 +2,7 @@ title: enumerate categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Enumerate the elements in a stream. usage: | diff --git a/commands/docs/error.md b/commands/docs/error.md new file mode 100644 index 00000000000..4885b13d289 --- /dev/null +++ b/commands/docs/error.md @@ -0,0 +1,36 @@ +--- +title: error +categories: | + core +version: 0.107.0 +core: | + Various commands for working with errors. +usage: | + Various commands for working with errors. +editLink: false +contributors: false +--- + + +# `error` for [core](/commands/categories/core.md) + +
Various commands for working with errors.
+ +## Signature + +```> error {flags} ``` + + +## Input/output types: + +| input | output | +| ------- | ------ | +| nothing | string | +## Notes +You must use one of the following subcommands. Using this command as-is will only produce this help message. + +## Subcommands: + +| name | description | type | +| -------------------------------------------- | ---------------- | -------- | +| [`error make`](/commands/docs/error_make.md) | Create an error. | built-in | \ No newline at end of file diff --git a/commands/docs/error_make.md b/commands/docs/error_make.md index 7741570a739..5fd1441dfae 100644 --- a/commands/docs/error_make.md +++ b/commands/docs/error_make.md @@ -2,7 +2,7 @@ title: error make categories: | core -version: 0.106.0 +version: 0.107.0 core: | Create an error. usage: | diff --git a/commands/docs/every.md b/commands/docs/every.md index dcfe4eb17eb..62d68aee2af 100644 --- a/commands/docs/every.md +++ b/commands/docs/every.md @@ -2,7 +2,7 @@ title: every categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Show (or skip) every n-th row, starting from the first one. usage: | diff --git a/commands/docs/exec.md b/commands/docs/exec.md index 7ae78ce2e61..0a22fd2a7d0 100644 --- a/commands/docs/exec.md +++ b/commands/docs/exec.md @@ -2,7 +2,7 @@ title: exec categories: | system -version: 0.106.0 +version: 0.107.0 system: | Execute a command, replacing or exiting the current process, depending on platform. usage: | diff --git a/commands/docs/exit.md b/commands/docs/exit.md index 583861b4e82..62685a414a8 100644 --- a/commands/docs/exit.md +++ b/commands/docs/exit.md @@ -2,7 +2,7 @@ title: exit categories: | shells -version: 0.106.0 +version: 0.107.0 shells: | Exit Nu. usage: | diff --git a/commands/docs/explain.md b/commands/docs/explain.md index eacf58bc1bb..7e92cafeea9 100644 --- a/commands/docs/explain.md +++ b/commands/docs/explain.md @@ -2,7 +2,7 @@ title: explain categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Explain closure contents. usage: | diff --git a/commands/docs/explore.md b/commands/docs/explore.md index 6079f90215e..f410d4a54e4 100644 --- a/commands/docs/explore.md +++ b/commands/docs/explore.md @@ -2,7 +2,7 @@ title: explore categories: | viewers -version: 0.106.0 +version: 0.107.0 viewers: | Explore acts as a table pager, just like `less` does for text. usage: | diff --git a/commands/docs/export-env.md b/commands/docs/export-env.md index be0d172a873..0e0e9a4e8b2 100644 --- a/commands/docs/export-env.md +++ b/commands/docs/export-env.md @@ -2,7 +2,7 @@ title: export-env categories: | env -version: 0.106.0 +version: 0.107.0 env: | Run a block and preserve its environment in a current scope. usage: | diff --git a/commands/docs/export.md b/commands/docs/export.md index a6f1796f40d..be5f227c516 100644 --- a/commands/docs/export.md +++ b/commands/docs/export.md @@ -2,7 +2,7 @@ title: export categories: | core -version: 0.106.0 +version: 0.107.0 core: | Export definitions or environment variables from a module. usage: | diff --git a/commands/docs/export_alias.md b/commands/docs/export_alias.md index 6913adca705..eff0d8bd02e 100644 --- a/commands/docs/export_alias.md +++ b/commands/docs/export_alias.md @@ -2,7 +2,7 @@ title: export alias categories: | core -version: 0.106.0 +version: 0.107.0 core: | Alias a command (with optional flags) to a new name and export it from a module. usage: | diff --git a/commands/docs/export_const.md b/commands/docs/export_const.md index 2ea7dd60865..14fbc4a930e 100644 --- a/commands/docs/export_const.md +++ b/commands/docs/export_const.md @@ -2,7 +2,7 @@ title: export const categories: | core -version: 0.106.0 +version: 0.107.0 core: | Use parse-time constant from a module and export them from this module. usage: | diff --git a/commands/docs/export_def.md b/commands/docs/export_def.md index cb4e842b3d6..bd20d15805f 100644 --- a/commands/docs/export_def.md +++ b/commands/docs/export_def.md @@ -2,7 +2,7 @@ title: export def categories: | core -version: 0.106.0 +version: 0.107.0 core: | Define a custom command and export it from a module. usage: | diff --git a/commands/docs/export_extern.md b/commands/docs/export_extern.md index 38ba333ef9c..2f71a4fc9d1 100644 --- a/commands/docs/export_extern.md +++ b/commands/docs/export_extern.md @@ -2,7 +2,7 @@ title: export extern categories: | core -version: 0.106.0 +version: 0.107.0 core: | Define an extern and export it from a module. usage: | diff --git a/commands/docs/export_module.md b/commands/docs/export_module.md index b61f0fdb4d0..0944198858f 100644 --- a/commands/docs/export_module.md +++ b/commands/docs/export_module.md @@ -2,7 +2,7 @@ title: export module categories: | core -version: 0.106.0 +version: 0.107.0 core: | Export a custom module from a module. usage: | diff --git a/commands/docs/export_use.md b/commands/docs/export_use.md index 629525021df..1c610ea80c6 100644 --- a/commands/docs/export_use.md +++ b/commands/docs/export_use.md @@ -2,7 +2,7 @@ title: export use categories: | core -version: 0.106.0 +version: 0.107.0 core: | Use definitions from a module and export them from this module. usage: | diff --git a/commands/docs/extern.md b/commands/docs/extern.md index a182c2bbed0..f1981b9918d 100644 --- a/commands/docs/extern.md +++ b/commands/docs/extern.md @@ -2,7 +2,7 @@ title: extern categories: | core -version: 0.106.0 +version: 0.107.0 core: | Define a signature for an external command. usage: | diff --git a/commands/docs/fill.md b/commands/docs/fill.md index 4232ae8afda..1c68358ca17 100644 --- a/commands/docs/fill.md +++ b/commands/docs/fill.md @@ -2,7 +2,7 @@ title: fill categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Fill and Align. usage: | diff --git a/commands/docs/filter.md b/commands/docs/filter.md index 676f8934708..e948277c21f 100644 --- a/commands/docs/filter.md +++ b/commands/docs/filter.md @@ -2,7 +2,7 @@ title: filter categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Filter values based on a predicate closure. usage: | diff --git a/commands/docs/find.md b/commands/docs/find.md index 03d3a6d1561..8652c1df08d 100644 --- a/commands/docs/find.md +++ b/commands/docs/find.md @@ -2,7 +2,7 @@ title: find categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Searches terms in the input. usage: | @@ -23,8 +23,8 @@ contributors: false ## Flags - `--regex, -r {string}`: regex to match with - - `--ignore-case, -i`: case-insensitive regex mode; equivalent to (?i) - - `--multiline, -m`: multi-line regex mode: ^ and $ match begin/end of line; equivalent to (?m) + - `--ignore-case, -i`: case-insensitive; when in regex mode, this is equivalent to (?i) + - `--multiline, -m`: don't split multi-line strings into lists of lines. you should use this option when using the (?m) or (?s) flags in regex mode - `--dotall, -s`: dotall regex mode: allow a dot . to match newlines \n; equivalent to (?s) - `--columns, -c {list}`: column names to be searched - `--no-highlight, -n`: no-highlight mode: find without marking with ansi code @@ -49,15 +49,15 @@ Search for multiple terms in a command output ``` -Search and highlight text for a term in a string. Note that regular search is case insensitive +Search and highlight text for a term in a string. ```nu -> 'Cargo.toml' | find cargo +> 'Cargo.toml' | find Cargo Cargo.toml ``` Search a number or a file size in a list of numbers ```nu -> [1 5 3kb 4 3Mb] | find 5 3kb +> [1 5 3kb 4 35 3Mb] | find 5 3kb ╭───┬────────╮ │ 0 │ 5 │ │ 1 │ 3.0 kB │ @@ -75,9 +75,9 @@ Search a char in a list of string ``` -Find using regex +Search using regex ```nu -> [abc bde arc abf] | find --regex "ab" +> [abc odb arc abf] | find --regex "b." ╭───┬─────╮ │ 0 │ abc │ │ 1 │ abf │ @@ -85,9 +85,9 @@ Find using regex ``` -Find using regex case insensitive +Case insensitive search ```nu -> [aBc bde Arc abf] | find --regex "ab" -i +> [aBc bde Arc abf] | find "ab" -i ╭───┬─────╮ │ 0 │ aBc │ │ 1 │ abf │ @@ -163,3 +163,22 @@ Find and highlight text in specific columns ╰───┴──────┴───────┴───────╯ ``` + +Find in a multi-line string +```nu +> "Violets are red\nAnd roses are blue\nWhen metamaterials\nAlter their hue" | find "ue" +╭───┬────────────────────╮ +│ 0 │ And roses are blue │ +│ 1 │ Alter their hue │ +╰───┴────────────────────╯ + +``` + +Find in a multi-line string without splitting the input into a list of lines +```nu +> "Violets are red\nAnd roses are blue\nWhen metamaterials\nAlter their hue" | find --multiline "ue" +Violets are red +And roses are blue +When metamaterials +Alter their hue +``` diff --git a/commands/docs/first.md b/commands/docs/first.md index be3e6a60d61..dc90e7492f8 100644 --- a/commands/docs/first.md +++ b/commands/docs/first.md @@ -2,7 +2,7 @@ title: first categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Return only the first several rows of the input. Counterpart of `last`. Opposite of `skip`. usage: | diff --git a/commands/docs/flatten.md b/commands/docs/flatten.md index 2b16b96f89e..e55bbb119e2 100644 --- a/commands/docs/flatten.md +++ b/commands/docs/flatten.md @@ -2,7 +2,7 @@ title: flatten categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Flatten the table. usage: | diff --git a/commands/docs/for.md b/commands/docs/for.md index 2ce7409ce6d..be471036697 100644 --- a/commands/docs/for.md +++ b/commands/docs/for.md @@ -2,7 +2,7 @@ title: for categories: | core -version: 0.106.0 +version: 0.107.0 core: | Loop over a range. usage: | diff --git a/commands/docs/format.md b/commands/docs/format.md index 9f229dadfd9..e28e458ea98 100644 --- a/commands/docs/format.md +++ b/commands/docs/format.md @@ -2,7 +2,7 @@ title: format categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Various commands for formatting data. usage: | diff --git a/commands/docs/format_bits.md b/commands/docs/format_bits.md index dccc5b93b78..e47fc8fc37d 100644 --- a/commands/docs/format_bits.md +++ b/commands/docs/format_bits.md @@ -2,7 +2,7 @@ title: format bits categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to a string of binary data represented by 0 and 1. usage: | @@ -51,6 +51,12 @@ convert an int into a string, padded to 8 places with 0s 00000001 ``` +convert an int into a string, padded to 8 places with 0s (big endian) +```nu +> 258 | format bits +00000001 00000010 +``` + convert a filesize value into a string, padded to 8 places with 0s ```nu > 1b | format bits diff --git a/commands/docs/format_date.md b/commands/docs/format_date.md index 596a868db11..5e928260a05 100644 --- a/commands/docs/format_date.md +++ b/commands/docs/format_date.md @@ -2,7 +2,7 @@ title: format date categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Format a given date using a format string. usage: | diff --git a/commands/docs/format_duration.md b/commands/docs/format_duration.md index b5ba57e78ee..3d5357c5258 100644 --- a/commands/docs/format_duration.md +++ b/commands/docs/format_duration.md @@ -2,7 +2,7 @@ title: format duration categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Outputs duration with a specified unit of time. usage: | diff --git a/commands/docs/format_filesize.md b/commands/docs/format_filesize.md index fb07b68edfb..32c3d7cf8fc 100644 --- a/commands/docs/format_filesize.md +++ b/commands/docs/format_filesize.md @@ -2,7 +2,7 @@ title: format filesize categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Converts a column of filesizes to some specified format. usage: | @@ -37,7 +37,7 @@ contributors: false Convert the size column to KB ```nu -> ls | format filesize KB size +> ls | format filesize kB size ``` diff --git a/commands/docs/format_number.md b/commands/docs/format_number.md index d46693bac72..10e5245b891 100644 --- a/commands/docs/format_number.md +++ b/commands/docs/format_number.md @@ -2,7 +2,7 @@ title: format number categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Format a number. usage: | diff --git a/commands/docs/format_pattern.md b/commands/docs/format_pattern.md index 0a4cecc2be7..13e0899b6f4 100644 --- a/commands/docs/format_pattern.md +++ b/commands/docs/format_pattern.md @@ -2,7 +2,7 @@ title: format pattern categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Format columns into a string using a simple pattern. usage: | diff --git a/commands/docs/from.md b/commands/docs/from.md index 7d67441fc86..be3a0d85da8 100644 --- a/commands/docs/from.md +++ b/commands/docs/from.md @@ -2,7 +2,7 @@ title: from categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse a string or binary data into structured data. usage: | diff --git a/commands/docs/from_csv.md b/commands/docs/from_csv.md index 79377674120..0dc8c5406a0 100644 --- a/commands/docs/from_csv.md +++ b/commands/docs/from_csv.md @@ -2,7 +2,7 @@ title: from csv categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .csv and create table. usage: | diff --git a/commands/docs/from_eml.md b/commands/docs/from_eml.md index 327489c8ad7..9a9935ee3c9 100644 --- a/commands/docs/from_eml.md +++ b/commands/docs/from_eml.md @@ -2,7 +2,7 @@ title: from eml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .eml and create record. usage: | diff --git a/commands/docs/from_ics.md b/commands/docs/from_ics.md index 7d6111f989b..12484b24b7e 100644 --- a/commands/docs/from_ics.md +++ b/commands/docs/from_ics.md @@ -2,7 +2,7 @@ title: from ics categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .ics and create table. usage: | diff --git a/commands/docs/from_ini.md b/commands/docs/from_ini.md index 3d166a3bdfa..e1cdd73cac5 100644 --- a/commands/docs/from_ini.md +++ b/commands/docs/from_ini.md @@ -2,7 +2,7 @@ title: from ini categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .ini and create table. usage: | diff --git a/commands/docs/from_json.md b/commands/docs/from_json.md index b2cb298855a..3e1ebd39e4c 100644 --- a/commands/docs/from_json.md +++ b/commands/docs/from_json.md @@ -2,7 +2,7 @@ title: from json categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert from json to structured data. usage: | diff --git a/commands/docs/from_msgpack.md b/commands/docs/from_msgpack.md index 485103780dc..5d950091fcc 100644 --- a/commands/docs/from_msgpack.md +++ b/commands/docs/from_msgpack.md @@ -2,7 +2,7 @@ title: from msgpack categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert MessagePack data into Nu values. usage: | diff --git a/commands/docs/from_msgpackz.md b/commands/docs/from_msgpackz.md index 2f66f3feabd..09f022fa8fc 100644 --- a/commands/docs/from_msgpackz.md +++ b/commands/docs/from_msgpackz.md @@ -2,7 +2,7 @@ title: from msgpackz categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert brotli-compressed MessagePack data into Nu values. usage: | diff --git a/commands/docs/from_nuon.md b/commands/docs/from_nuon.md index db06b29600e..8d5ba98bdc3 100644 --- a/commands/docs/from_nuon.md +++ b/commands/docs/from_nuon.md @@ -2,7 +2,7 @@ title: from nuon categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert from nuon to structured data. usage: | diff --git a/commands/docs/from_ods.md b/commands/docs/from_ods.md index 17edf4f98ab..ef67dcc4ab0 100644 --- a/commands/docs/from_ods.md +++ b/commands/docs/from_ods.md @@ -2,7 +2,7 @@ title: from ods categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse OpenDocument Spreadsheet(.ods) data and create table. usage: | diff --git a/commands/docs/from_plist.md b/commands/docs/from_plist.md index 60e987bce64..895a6d7bd52 100644 --- a/commands/docs/from_plist.md +++ b/commands/docs/from_plist.md @@ -2,7 +2,7 @@ title: from plist categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert plist to Nushell values usage: | diff --git a/commands/docs/from_ssv.md b/commands/docs/from_ssv.md index 913adeb3364..8994ef9d79e 100644 --- a/commands/docs/from_ssv.md +++ b/commands/docs/from_ssv.md @@ -2,7 +2,7 @@ title: from ssv categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as space-separated values and create a table. The default minimum number of spaces counted as a separator is 2. usage: | diff --git a/commands/docs/from_toml.md b/commands/docs/from_toml.md index c7202cfb791..262043f12f3 100644 --- a/commands/docs/from_toml.md +++ b/commands/docs/from_toml.md @@ -2,7 +2,7 @@ title: from toml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .toml and create record. usage: | diff --git a/commands/docs/from_tsv.md b/commands/docs/from_tsv.md index 6ebd69370b2..e7124e39bff 100644 --- a/commands/docs/from_tsv.md +++ b/commands/docs/from_tsv.md @@ -2,7 +2,7 @@ title: from tsv categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .tsv and create table. usage: | diff --git a/commands/docs/from_url.md b/commands/docs/from_url.md index 925ea6b5da6..b2988ce8790 100644 --- a/commands/docs/from_url.md +++ b/commands/docs/from_url.md @@ -2,7 +2,7 @@ title: from url categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse url-encoded string as a record. usage: | diff --git a/commands/docs/from_vcf.md b/commands/docs/from_vcf.md index ded8704f949..3c930ce4389 100644 --- a/commands/docs/from_vcf.md +++ b/commands/docs/from_vcf.md @@ -2,7 +2,7 @@ title: from vcf categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .vcf and create table. usage: | diff --git a/commands/docs/from_xlsx.md b/commands/docs/from_xlsx.md index 8f76293244a..b3c916d84b2 100644 --- a/commands/docs/from_xlsx.md +++ b/commands/docs/from_xlsx.md @@ -2,7 +2,7 @@ title: from xlsx categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse binary Excel(.xlsx) data and create table. usage: | diff --git a/commands/docs/from_xml.md b/commands/docs/from_xml.md index e6d778810c9..2693f1d665a 100644 --- a/commands/docs/from_xml.md +++ b/commands/docs/from_xml.md @@ -2,7 +2,7 @@ title: from xml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .xml and create record. usage: | diff --git a/commands/docs/from_yaml.md b/commands/docs/from_yaml.md index c8dee2d5a62..455d073dd9d 100644 --- a/commands/docs/from_yaml.md +++ b/commands/docs/from_yaml.md @@ -2,7 +2,7 @@ title: from yaml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .yaml/.yml and create table. usage: | diff --git a/commands/docs/from_yml.md b/commands/docs/from_yml.md index b1fe620e4f3..ff2beb59d05 100644 --- a/commands/docs/from_yml.md +++ b/commands/docs/from_yml.md @@ -2,7 +2,7 @@ title: from yml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Parse text as .yaml/.yml and create table. usage: | diff --git a/commands/docs/generate.md b/commands/docs/generate.md index e1e081d6fef..9ef499d3ad4 100644 --- a/commands/docs/generate.md +++ b/commands/docs/generate.md @@ -2,7 +2,7 @@ title: generate categories: | generators -version: 0.106.0 +version: 0.107.0 generators: | Generate a list of values by successively invoking a closure. usage: | diff --git a/commands/docs/get.md b/commands/docs/get.md index 87dad84fc87..c1b54abebb0 100644 --- a/commands/docs/get.md +++ b/commands/docs/get.md @@ -2,7 +2,7 @@ title: get categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Extract data using a cell path. usage: | @@ -23,6 +23,7 @@ contributors: false ## Flags - `--optional, -o`: make all cell path members optional (returns `null` for missing values) + - `--ignore-case`: make all cell path members case insensitive - `--ignore-errors, -i`: ignore missing data (make all cell path members optional) (deprecated) - `--sensitive, -s`: get path in a case sensitive manner (deprecated) @@ -57,6 +58,28 @@ Get a column from a table ``` +Get a column from a table where some rows don't have that column, using optional cell-path syntax +```nu +> [{A: A0, B: B0}, {B: B1}, {A: A2, B: B2}] | get A? +╭───┬────╮ +│ 0 │ A0 │ +│ 1 │ │ +│ 2 │ A2 │ +╰───┴────╯ + +``` + +Get a column from a table where some rows don't have that column, using the optional flag +```nu +> [{A: A0, B: B0}, {B: B1}, {A: A2, B: B2}] | get -o A +╭───┬────╮ +│ 0 │ A0 │ +│ 1 │ │ +│ 2 │ A2 │ +╰───┴────╯ + +``` + Get a cell from a table ```nu > [{A: A0}] | get 0.A @@ -75,9 +98,15 @@ Extract the name of the 3rd record in a list ``` -Getting Path/PATH in a case insensitive way +Getting environment variables in a case insensitive way, using case insensitive cell-path syntax +```nu +> $env | get home! path! + +``` + +Getting environment variables in a case insensitive way, using the '--ignore-case' flag ```nu -> $env | get paTH! +> $env | get --ignore-case home path ``` diff --git a/commands/docs/glob.md b/commands/docs/glob.md index 0133f8f14f9..c317efd41ff 100644 --- a/commands/docs/glob.md +++ b/commands/docs/glob.md @@ -2,7 +2,7 @@ title: glob categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Creates a list of files and/or folders based on the glob pattern provided. usage: | diff --git a/commands/docs/grid.md b/commands/docs/grid.md index bfa78d6c8a2..2ad409b584f 100644 --- a/commands/docs/grid.md +++ b/commands/docs/grid.md @@ -2,7 +2,7 @@ title: grid categories: | viewers -version: 0.106.0 +version: 0.107.0 viewers: | Renders the output to a textual terminal grid. usage: | diff --git a/commands/docs/group-by.md b/commands/docs/group-by.md index ffa13f899e1..c819c4e57b3 100644 --- a/commands/docs/group-by.md +++ b/commands/docs/group-by.md @@ -2,7 +2,7 @@ title: group-by categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Splits a list or table into groups, and returns a record containing those groups. usage: | diff --git a/commands/docs/gstat.md b/commands/docs/gstat.md index fa7d4a7fb0e..06a9f23c722 100644 --- a/commands/docs/gstat.md +++ b/commands/docs/gstat.md @@ -2,7 +2,7 @@ title: gstat categories: | prompt -version: 0.106.0 +version: 0.107.0 prompt: | Get the git status of a repo usage: | diff --git a/commands/docs/hash.md b/commands/docs/hash.md index 092f5cefd07..7667ac3fc98 100644 --- a/commands/docs/hash.md +++ b/commands/docs/hash.md @@ -2,7 +2,7 @@ title: hash categories: | hash -version: 0.106.0 +version: 0.107.0 hash: | Apply hash function. usage: | diff --git a/commands/docs/hash_md5.md b/commands/docs/hash_md5.md index 6cb36124c84..4da8e2c2b58 100644 --- a/commands/docs/hash_md5.md +++ b/commands/docs/hash_md5.md @@ -2,7 +2,7 @@ title: hash md5 categories: | hash -version: 0.106.0 +version: 0.107.0 hash: | Hash a value using the md5 hash algorithm. usage: | diff --git a/commands/docs/hash_sha256.md b/commands/docs/hash_sha256.md index 96e103559e6..44883622530 100644 --- a/commands/docs/hash_sha256.md +++ b/commands/docs/hash_sha256.md @@ -2,7 +2,7 @@ title: hash sha256 categories: | hash -version: 0.106.0 +version: 0.107.0 hash: | Hash a value using the sha256 hash algorithm. usage: | diff --git a/commands/docs/headers.md b/commands/docs/headers.md index b174d5b9f7c..106e16d0bb4 100644 --- a/commands/docs/headers.md +++ b/commands/docs/headers.md @@ -2,7 +2,7 @@ title: headers categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Use the first row of the table as column names. usage: | diff --git a/commands/docs/help.md b/commands/docs/help.md index 9d4ab1e3850..009ec328912 100644 --- a/commands/docs/help.md +++ b/commands/docs/help.md @@ -2,7 +2,7 @@ title: help categories: | core -version: 0.106.0 +version: 0.107.0 core: | Display help information about different parts of Nushell. usage: | @@ -56,6 +56,8 @@ search for string in command names, descriptions, and search terms ## Notes `help word` searches for "word" in commands, aliases and modules, in that order. +If you want your own help implementation, create a custom command named `help` and it will also be used for `--help` invocations. +There already is an alternative `help` command in the standard library you can try with `use std/help`. ## Subcommands: diff --git a/commands/docs/help_aliases.md b/commands/docs/help_aliases.md index 3ab95930673..0d583693c55 100644 --- a/commands/docs/help_aliases.md +++ b/commands/docs/help_aliases.md @@ -2,7 +2,7 @@ title: help aliases categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell aliases. usage: | diff --git a/commands/docs/help_commands.md b/commands/docs/help_commands.md index 15e20b20db4..4ee784674b7 100644 --- a/commands/docs/help_commands.md +++ b/commands/docs/help_commands.md @@ -2,7 +2,7 @@ title: help commands categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell commands. usage: | diff --git a/commands/docs/help_escapes.md b/commands/docs/help_escapes.md index 4ebec82f6a7..b34b2bd5424 100644 --- a/commands/docs/help_escapes.md +++ b/commands/docs/help_escapes.md @@ -2,7 +2,7 @@ title: help escapes categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell string escapes. usage: | diff --git a/commands/docs/help_externs.md b/commands/docs/help_externs.md index 8e108a2f984..3e2553cb3b6 100644 --- a/commands/docs/help_externs.md +++ b/commands/docs/help_externs.md @@ -2,7 +2,7 @@ title: help externs categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell externs. usage: | diff --git a/commands/docs/help_modules.md b/commands/docs/help_modules.md index e91aae269a4..d863a2b13c9 100644 --- a/commands/docs/help_modules.md +++ b/commands/docs/help_modules.md @@ -2,7 +2,7 @@ title: help modules categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell modules. usage: | diff --git a/commands/docs/help_operators.md b/commands/docs/help_operators.md index cbd640e4d8b..2b38f7a5f04 100644 --- a/commands/docs/help_operators.md +++ b/commands/docs/help_operators.md @@ -2,7 +2,7 @@ title: help operators categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell operators. usage: | diff --git a/commands/docs/help_pipe-and-redirect.md b/commands/docs/help_pipe-and-redirect.md index 06fb6b9ab53..2fd6f87e3fb 100644 --- a/commands/docs/help_pipe-and-redirect.md +++ b/commands/docs/help_pipe-and-redirect.md @@ -2,7 +2,7 @@ title: help pipe-and-redirect categories: | core -version: 0.106.0 +version: 0.107.0 core: | Show help on nushell pipes and redirects. usage: | diff --git a/commands/docs/hide-env.md b/commands/docs/hide-env.md index e562f50531b..ceec6f2aaa9 100644 --- a/commands/docs/hide-env.md +++ b/commands/docs/hide-env.md @@ -2,7 +2,7 @@ title: hide-env categories: | core -version: 0.106.0 +version: 0.107.0 core: | Hide environment variables in the current scope. usage: | diff --git a/commands/docs/hide.md b/commands/docs/hide.md index f7481252332..14ccfd89542 100644 --- a/commands/docs/hide.md +++ b/commands/docs/hide.md @@ -2,7 +2,7 @@ title: hide categories: | core -version: 0.106.0 +version: 0.107.0 core: | Hide definitions in the current scope. usage: | @@ -23,7 +23,7 @@ contributors: false ## Parameters - `module`: Module or module file. - - `members`: Which members of the module to import. + - `members`: Which members of the module to hide. ## Input/output types: diff --git a/commands/docs/histogram.md b/commands/docs/histogram.md index dca447e5870..6ee3a9e81d5 100644 --- a/commands/docs/histogram.md +++ b/commands/docs/histogram.md @@ -2,7 +2,7 @@ title: histogram categories: | chart -version: 0.106.0 +version: 0.107.0 chart: | Creates a new table with a histogram based on the column name passed in. usage: | diff --git a/commands/docs/history.md b/commands/docs/history.md index a24827280ad..ae6e7f3575b 100644 --- a/commands/docs/history.md +++ b/commands/docs/history.md @@ -2,7 +2,7 @@ title: history categories: | history -version: 0.106.0 +version: 0.107.0 history: | Get the command history. usage: | diff --git a/commands/docs/history_import.md b/commands/docs/history_import.md index a3c384b5445..2027c0bb044 100644 --- a/commands/docs/history_import.md +++ b/commands/docs/history_import.md @@ -2,7 +2,7 @@ title: history import categories: | history -version: 0.106.0 +version: 0.107.0 history: | Import command line history. usage: | diff --git a/commands/docs/history_session.md b/commands/docs/history_session.md index 9d38bad55e5..41c48d78523 100644 --- a/commands/docs/history_session.md +++ b/commands/docs/history_session.md @@ -2,7 +2,7 @@ title: history session categories: | history -version: 0.106.0 +version: 0.107.0 history: | Get the command history session. usage: | diff --git a/commands/docs/http.md b/commands/docs/http.md index 341552a87ed..886c6da9c49 100644 --- a/commands/docs/http.md +++ b/commands/docs/http.md @@ -2,7 +2,7 @@ title: http categories: | network -version: 0.106.0 +version: 0.107.0 network: | Various commands for working with http methods. usage: | @@ -29,7 +29,14 @@ contributors: false - `--headers, -H {any}`: custom headers you want to add - `--raw, -r`: fetch contents as text rather than a table - `--insecure, -k`: allow insecure server connections when using SSL - - `--full, -f`: returns the full response instead of only the body + - `--full, -f`: Returns the record, containing metainformation about the exchange in addition to the response. + Returning record fields: + - urls: list of url redirects this command had to make to get to the destination + - headers.request: list of headers passed when doing the request + - headers.response: list of received headers + - body: the http body of the response + - status: the http status of the response + - `--allow-errors, -e`: do not fail if the server returns an error code - `--redirect-mode, -R {string}`: What to do when encountering redirects. Default: 'follow'. Valid options: 'follow' ('f'), 'manual' ('m'), 'error' ('e'). diff --git a/commands/docs/http_delete.md b/commands/docs/http_delete.md index 0dcf28627ce..17cbd446d90 100644 --- a/commands/docs/http_delete.md +++ b/commands/docs/http_delete.md @@ -2,7 +2,7 @@ title: http delete categories: | network -version: 0.106.0 +version: 0.107.0 network: | Delete the specified resource. usage: | diff --git a/commands/docs/http_get.md b/commands/docs/http_get.md index 1e2655d636c..a1491602210 100644 --- a/commands/docs/http_get.md +++ b/commands/docs/http_get.md @@ -2,7 +2,7 @@ title: http get categories: | network -version: 0.106.0 +version: 0.107.0 network: | Fetch the contents from a URL. usage: | diff --git a/commands/docs/http_head.md b/commands/docs/http_head.md index 910cf636fef..be2857af6f3 100644 --- a/commands/docs/http_head.md +++ b/commands/docs/http_head.md @@ -2,7 +2,7 @@ title: http head categories: | network -version: 0.106.0 +version: 0.107.0 network: | Get the headers from a URL. usage: | diff --git a/commands/docs/http_options.md b/commands/docs/http_options.md index 13ba8de3161..6a5bb0d9272 100644 --- a/commands/docs/http_options.md +++ b/commands/docs/http_options.md @@ -2,7 +2,7 @@ title: http options categories: | network -version: 0.106.0 +version: 0.107.0 network: | Requests permitted communication options for a given URL. usage: | diff --git a/commands/docs/http_patch.md b/commands/docs/http_patch.md index 22402dd7302..1f5e856a278 100644 --- a/commands/docs/http_patch.md +++ b/commands/docs/http_patch.md @@ -2,7 +2,7 @@ title: http patch categories: | network -version: 0.106.0 +version: 0.107.0 network: | Patch a body to a URL. usage: | diff --git a/commands/docs/http_post.md b/commands/docs/http_post.md index ed13e22afd9..f375dc82ed9 100644 --- a/commands/docs/http_post.md +++ b/commands/docs/http_post.md @@ -2,7 +2,7 @@ title: http post categories: | network -version: 0.106.0 +version: 0.107.0 network: | Post a body to a URL. usage: | diff --git a/commands/docs/http_put.md b/commands/docs/http_put.md index a2a1601f799..d804301c43f 100644 --- a/commands/docs/http_put.md +++ b/commands/docs/http_put.md @@ -2,7 +2,7 @@ title: http put categories: | network -version: 0.106.0 +version: 0.107.0 network: | Put a body to a URL. usage: | diff --git a/commands/docs/if.md b/commands/docs/if.md index da8696128a9..86e339e81a1 100644 --- a/commands/docs/if.md +++ b/commands/docs/if.md @@ -2,7 +2,7 @@ title: if categories: | core -version: 0.106.0 +version: 0.107.0 core: | Conditionally run a block. usage: | diff --git a/commands/docs/ignore.md b/commands/docs/ignore.md index 29abbe83886..62af2c8441f 100644 --- a/commands/docs/ignore.md +++ b/commands/docs/ignore.md @@ -2,7 +2,7 @@ title: ignore categories: | core -version: 0.106.0 +version: 0.107.0 core: | Ignore the output of the previous command in the pipeline. usage: | diff --git a/commands/docs/inc.md b/commands/docs/inc.md index 078cd5ab9eb..e324a93f43d 100644 --- a/commands/docs/inc.md +++ b/commands/docs/inc.md @@ -2,7 +2,7 @@ title: inc categories: | default -version: 0.106.0 +version: 0.107.0 default: | Increment a value or version. Optionally use the column of a table. usage: | diff --git a/commands/docs/input.md b/commands/docs/input.md index 1609b574ffb..3a4aedd693c 100644 --- a/commands/docs/input.md +++ b/commands/docs/input.md @@ -2,7 +2,7 @@ title: input categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Get input from the user. usage: | @@ -26,8 +26,8 @@ contributors: false - `--numchar, -n {int}`: number of characters to read; suppresses output - `--default, -d {string}`: default value if no input is provided - `--reedline`: use the reedline library, defaults to false - - `--history-file {path}`: Path to a file to read and write command history. This is a text file and will be created if it doesn't exist. Will be used as the selection list. - - `--max-history {int}`: The maximum number of entries to keep in the history, defaults to $env.config.history.max_size. + - `--history-file {path}`: Path to a file to read and write command history. This is a text file and will be created if it doesn't exist. Will be used as the selection list. Implies `--reedline`. + - `--max-history {int}`: The maximum number of entries to keep in the history, defaults to $env.config.history.max_size. Implies `--reedline`. - `--suppress-output, -s`: don't print keystroke values ## Parameters @@ -61,15 +61,21 @@ Get input from the user with default value, and assign to a variable ``` +Get multiple lines of input from the user (newlines can be entered using `Alt` + `Enter` or `Ctrl` + `Enter`), and assign to a variable +```nu +> let multiline_input = (input --reedline) + +``` + Get input from the user with history, and assign to a variable ```nu -> let user_input = ([past,command,entries] | input ) +> let user_input = ([past,command,entries] | input --reedline) ``` Get input from the user with history backed by a file, and assign to a variable ```nu -> let user_input = (input --history-file ./history.txt) +> let user_input = (input --reedline --history-file ./history.txt) ``` diff --git a/commands/docs/input_list.md b/commands/docs/input_list.md index 3be5bb8bb56..d8ed171538f 100644 --- a/commands/docs/input_list.md +++ b/commands/docs/input_list.md @@ -2,7 +2,7 @@ title: input list categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Interactive list selection. usage: | diff --git a/commands/docs/input_listen.md b/commands/docs/input_listen.md index a1d9b03cf12..689efc82e34 100644 --- a/commands/docs/input_listen.md +++ b/commands/docs/input_listen.md @@ -2,7 +2,7 @@ title: input listen categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Listen for user interface event. usage: | diff --git a/commands/docs/insert.md b/commands/docs/insert.md index 2364670588f..c9bc8f2a6c9 100644 --- a/commands/docs/insert.md +++ b/commands/docs/insert.md @@ -2,7 +2,7 @@ title: insert categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Insert a new column, using an expression or closure to create each row's values. usage: | diff --git a/commands/docs/inspect.md b/commands/docs/inspect.md index 6e8018bef95..3c707c3e8ce 100644 --- a/commands/docs/inspect.md +++ b/commands/docs/inspect.md @@ -2,7 +2,7 @@ title: inspect categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Inspect pipeline results while running a pipeline. usage: | diff --git a/commands/docs/interleave.md b/commands/docs/interleave.md index 00c687118a5..110fba3c3c5 100644 --- a/commands/docs/interleave.md +++ b/commands/docs/interleave.md @@ -2,7 +2,7 @@ title: interleave categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Read multiple streams in parallel and combine them into one stream. usage: | diff --git a/commands/docs/into.md b/commands/docs/into.md index e6c54515329..7efead1489e 100644 --- a/commands/docs/into.md +++ b/commands/docs/into.md @@ -2,7 +2,7 @@ title: into categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Commands to convert data from one type to another. usage: | diff --git a/commands/docs/into_binary.md b/commands/docs/into_binary.md index cade8834074..495e97dbc35 100644 --- a/commands/docs/into_binary.md +++ b/commands/docs/into_binary.md @@ -2,7 +2,7 @@ title: into binary categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to a binary primitive. usage: | @@ -23,6 +23,7 @@ contributors: false ## Flags - `--compact, -c`: output without padding zeros + - `--endian, -e {string}`: byte encode endian. Does not affect string, date or binary. In containers, only individual elements are affected. Available options: native(default), little, big ## Parameters @@ -63,6 +64,22 @@ Length: 8 (0x8) bytes | printable whitespace ascii_other non_ascii ``` +convert a number to a nushell binary primitive (big endian) +```nu +> 258 | into binary --endian big +Length: 8 (0x8) bytes | printable whitespace ascii_other non_ascii +00000000: 00 00 00 00 00 00 01 02 000000•• + +``` + +convert a number to a nushell binary primitive (little endian) +```nu +> 258 | into binary --endian little +Length: 8 (0x8) bytes | printable whitespace ascii_other non_ascii +00000000: 02 01 00 00 00 00 00 00 ••000000 + +``` + convert a boolean to a nushell binary primitive ```nu > true | into binary diff --git a/commands/docs/into_bool.md b/commands/docs/into_bool.md index 5eb9aa85f42..4e1b9de7a10 100644 --- a/commands/docs/into_bool.md +++ b/commands/docs/into_bool.md @@ -2,7 +2,7 @@ title: into bool categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to boolean. usage: | diff --git a/commands/docs/into_cell-path.md b/commands/docs/into_cell-path.md index efb380f9abf..1df2fba811c 100644 --- a/commands/docs/into_cell-path.md +++ b/commands/docs/into_cell-path.md @@ -2,7 +2,7 @@ title: into cell-path categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to a cell-path. usage: | diff --git a/commands/docs/into_datetime.md b/commands/docs/into_datetime.md index 232d650d80d..d7200283004 100644 --- a/commands/docs/into_datetime.md +++ b/commands/docs/into_datetime.md @@ -2,7 +2,7 @@ title: into datetime categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert text or timestamp into a datetime. usage: | @@ -42,7 +42,6 @@ contributors: false | list<string> | list<datetime> | | table | table | | nothing | table | -| record | any | | record | record | | record | datetime | | any | table | @@ -93,7 +92,7 @@ Sat, 27 Feb 2021 13:55:40 +0000 (4 years ago) Using a record as input ```nu > {year: 2025, month: 3, day: 30, hour: 12, minute: 15, second: 59, timezone: '+02:00'} | into datetime -Sun, 30 Mar 2025 10:15:59 +0000 (3 months ago) +Sun, 30 Mar 2025 10:15:59 +0000 (5 months ago) ``` Convert list of timestamps to datetimes diff --git a/commands/docs/into_duration.md b/commands/docs/into_duration.md index 2eb8174e8ac..1432fce2ba3 100644 --- a/commands/docs/into_duration.md +++ b/commands/docs/into_duration.md @@ -2,7 +2,7 @@ title: into duration categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to duration. usage: | @@ -37,7 +37,6 @@ contributors: false | float | duration | | string | duration | | duration | duration | -| record | any | | record | record | | record | duration | | table | table | diff --git a/commands/docs/into_filesize.md b/commands/docs/into_filesize.md index c7881365e27..3a6b0405068 100644 --- a/commands/docs/into_filesize.md +++ b/commands/docs/into_filesize.md @@ -2,7 +2,7 @@ title: into filesize categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to filesize. usage: | diff --git a/commands/docs/into_float.md b/commands/docs/into_float.md index 62ee7940546..44ac5dc59a4 100644 --- a/commands/docs/into_float.md +++ b/commands/docs/into_float.md @@ -2,7 +2,7 @@ title: into float categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert data into floating point number. usage: | diff --git a/commands/docs/into_glob.md b/commands/docs/into_glob.md index dbe9a222234..e5c42148d84 100644 --- a/commands/docs/into_glob.md +++ b/commands/docs/into_glob.md @@ -2,7 +2,7 @@ title: into glob categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to glob. usage: | diff --git a/commands/docs/into_int.md b/commands/docs/into_int.md index 86cf46d2a53..39cc37f06ae 100644 --- a/commands/docs/into_int.md +++ b/commands/docs/into_int.md @@ -2,7 +2,7 @@ title: into int categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to integer. usage: | diff --git a/commands/docs/into_record.md b/commands/docs/into_record.md index bf373d5c9b9..4766ea3fdca 100644 --- a/commands/docs/into_record.md +++ b/commands/docs/into_record.md @@ -2,7 +2,7 @@ title: into record categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to record. usage: | diff --git a/commands/docs/into_sqlite.md b/commands/docs/into_sqlite.md index db5ae3da084..0c7db52cb43 100644 --- a/commands/docs/into_sqlite.md +++ b/commands/docs/into_sqlite.md @@ -2,7 +2,7 @@ title: into sqlite categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert table into a SQLite database. usage: | @@ -60,3 +60,16 @@ Insert a single record into a SQLite database > { foo: bar, baz: quux } | into sqlite filename.db ``` + +Insert data that contains records, lists or tables, that will be stored as JSONB columns +These columns will be automatically turned back into nu objects when read directly via cell-path +```nu +> {a_record: {foo: bar, baz: quux}, a_list: [1 2 3], a_table: [[a b]; [0 1] [2 3]]} | into sqlite filename.db -t my_table +(open filename.db).my_table.0.a_list +╭───┬───╮ +│ 0 │ 1 │ +│ 1 │ 2 │ +│ 2 │ 3 │ +╰───┴───╯ + +``` diff --git a/commands/docs/into_string.md b/commands/docs/into_string.md index 6d222d6e44e..91de5938faa 100644 --- a/commands/docs/into_string.md +++ b/commands/docs/into_string.md @@ -2,7 +2,7 @@ title: into string categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Convert value to string. usage: | diff --git a/commands/docs/into_value.md b/commands/docs/into_value.md index 371e77935dd..a958d9af722 100644 --- a/commands/docs/into_value.md +++ b/commands/docs/into_value.md @@ -2,7 +2,7 @@ title: into value categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Infer Nushell datatype for each cell. usage: | diff --git a/commands/docs/is-admin.md b/commands/docs/is-admin.md index 8901e31113e..cf6e120bb84 100644 --- a/commands/docs/is-admin.md +++ b/commands/docs/is-admin.md @@ -2,7 +2,7 @@ title: is-admin categories: | core -version: 0.106.0 +version: 0.107.0 core: | Check if nushell is running with administrator or root privileges. usage: | diff --git a/commands/docs/is-empty.md b/commands/docs/is-empty.md index ed76f4e5d69..27e306e8ddb 100644 --- a/commands/docs/is-empty.md +++ b/commands/docs/is-empty.md @@ -2,7 +2,7 @@ title: is-empty categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Check for empty values. usage: | diff --git a/commands/docs/is-not-empty.md b/commands/docs/is-not-empty.md index 906cab71bd0..3aab7944b3e 100644 --- a/commands/docs/is-not-empty.md +++ b/commands/docs/is-not-empty.md @@ -2,7 +2,7 @@ title: is-not-empty categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Check for non-empty values. usage: | diff --git a/commands/docs/is-terminal.md b/commands/docs/is-terminal.md index d261261fa57..cb37f4e4a6d 100644 --- a/commands/docs/is-terminal.md +++ b/commands/docs/is-terminal.md @@ -2,7 +2,7 @@ title: is-terminal categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Check if stdin, stdout, or stderr is a terminal. usage: | diff --git a/commands/docs/items.md b/commands/docs/items.md index 2afe1f94449..6e2d0068a82 100644 --- a/commands/docs/items.md +++ b/commands/docs/items.md @@ -2,7 +2,7 @@ title: items categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Given a record, iterate on each pair of column name and associated value. usage: | diff --git a/commands/docs/job.md b/commands/docs/job.md index c4a330bf908..8ae446ea1cb 100644 --- a/commands/docs/job.md +++ b/commands/docs/job.md @@ -2,7 +2,7 @@ title: job categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Various commands for working with background jobs. usage: | diff --git a/commands/docs/job_flush.md b/commands/docs/job_flush.md index 8f3bb87515f..bd106128cc9 100644 --- a/commands/docs/job_flush.md +++ b/commands/docs/job_flush.md @@ -2,7 +2,7 @@ title: job flush categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Clear this job's mailbox. usage: | diff --git a/commands/docs/job_id.md b/commands/docs/job_id.md index d8f0dcdb1fa..569f0606b26 100644 --- a/commands/docs/job_id.md +++ b/commands/docs/job_id.md @@ -2,7 +2,7 @@ title: job id categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Get id of current job. usage: | diff --git a/commands/docs/job_kill.md b/commands/docs/job_kill.md index a098c643c7f..9fd9072d60d 100644 --- a/commands/docs/job_kill.md +++ b/commands/docs/job_kill.md @@ -2,7 +2,7 @@ title: job kill categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Kill a background job. usage: | diff --git a/commands/docs/job_list.md b/commands/docs/job_list.md index d10399cd84b..52f18f93d98 100644 --- a/commands/docs/job_list.md +++ b/commands/docs/job_list.md @@ -2,7 +2,7 @@ title: job list categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | List background jobs. usage: | diff --git a/commands/docs/job_recv.md b/commands/docs/job_recv.md index b9dd7f93a35..dc22f3bffc7 100644 --- a/commands/docs/job_recv.md +++ b/commands/docs/job_recv.md @@ -2,7 +2,7 @@ title: job recv categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Read a message from the mailbox. usage: | @@ -51,6 +51,12 @@ Get a message or fail if no message is available immediately ``` +Receive a message from a newly-spawned job +```nu +> job spawn { sleep 1sec; 'hi' | job send 0 }; job recv + +``` + ## Notes When messages are sent to the current process, they get stored in what is called the "mailbox". This commands reads and returns a message from the mailbox, in a first-in-first-out fashion. diff --git a/commands/docs/job_send.md b/commands/docs/job_send.md index 91470439639..01a800e18d7 100644 --- a/commands/docs/job_send.md +++ b/commands/docs/job_send.md @@ -2,7 +2,7 @@ title: job send categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Send a message to the mailbox of a job. usage: | @@ -36,12 +36,18 @@ contributors: false | any | nothing | ## Examples -Send a message to a newly spawned job +Send a message from the main thread to a newly-spawned job ```nu > let id = job spawn { job recv | save sent.txt }; 'hi' | job send $id ``` +Send a message from a newly-spawned job to the main thread (which always has an ID of 0) +```nu +> job spawn { sleep 1sec; 'hi' | job send 0 }; job recv + +``` + ## Notes This command sends a message to a background job, which can then read sent messages diff --git a/commands/docs/job_spawn.md b/commands/docs/job_spawn.md index 46f08ab4878..4657b11e2f6 100644 --- a/commands/docs/job_spawn.md +++ b/commands/docs/job_spawn.md @@ -2,7 +2,7 @@ title: job spawn categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Spawn a background job and retrieve its ID. usage: | diff --git a/commands/docs/job_tag.md b/commands/docs/job_tag.md index 947bb5695da..5e66b9118d8 100644 --- a/commands/docs/job_tag.md +++ b/commands/docs/job_tag.md @@ -2,7 +2,7 @@ title: job tag categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Add a description tag to a background job. usage: | diff --git a/commands/docs/job_unfreeze.md b/commands/docs/job_unfreeze.md index 6a230959a63..42f43f166f5 100644 --- a/commands/docs/job_unfreeze.md +++ b/commands/docs/job_unfreeze.md @@ -2,7 +2,7 @@ title: job unfreeze categories: | experimental -version: 0.106.0 +version: 0.107.0 experimental: | Unfreeze a frozen process job in foreground. usage: | diff --git a/commands/docs/join.md b/commands/docs/join.md index bbfb45cca6e..82d6333161b 100644 --- a/commands/docs/join.md +++ b/commands/docs/join.md @@ -2,7 +2,7 @@ title: join categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Join two tables. usage: | diff --git a/commands/docs/keybindings.md b/commands/docs/keybindings.md index 0c5a9d43929..e88b818082f 100644 --- a/commands/docs/keybindings.md +++ b/commands/docs/keybindings.md @@ -2,7 +2,7 @@ title: keybindings categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Keybindings related commands. usage: | diff --git a/commands/docs/keybindings_default.md b/commands/docs/keybindings_default.md index 5cf505773f0..8740192357c 100644 --- a/commands/docs/keybindings_default.md +++ b/commands/docs/keybindings_default.md @@ -2,7 +2,7 @@ title: keybindings default categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | List default keybindings. usage: | diff --git a/commands/docs/keybindings_list.md b/commands/docs/keybindings_list.md index 8464ac10631..544f4e7d188 100644 --- a/commands/docs/keybindings_list.md +++ b/commands/docs/keybindings_list.md @@ -2,7 +2,7 @@ title: keybindings list categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | List available options that can be used to create keybindings. usage: | diff --git a/commands/docs/keybindings_listen.md b/commands/docs/keybindings_listen.md index b56baef10a9..ce0af853e8e 100644 --- a/commands/docs/keybindings_listen.md +++ b/commands/docs/keybindings_listen.md @@ -2,7 +2,7 @@ title: keybindings listen categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Get input from the user. usage: | diff --git a/commands/docs/kill.md b/commands/docs/kill.md index 3724a938e24..45dfc21cce0 100644 --- a/commands/docs/kill.md +++ b/commands/docs/kill.md @@ -2,7 +2,7 @@ title: kill categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Kill a process using the process id. usage: | diff --git a/commands/docs/last.md b/commands/docs/last.md index 97a3b65cac2..b9531563525 100644 --- a/commands/docs/last.md +++ b/commands/docs/last.md @@ -2,7 +2,7 @@ title: last categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Return only the last several rows of the input. Counterpart of `first`. Opposite of `drop`. usage: | diff --git a/commands/docs/length.md b/commands/docs/length.md index 499ebebbe57..e60856b20d2 100644 --- a/commands/docs/length.md +++ b/commands/docs/length.md @@ -2,7 +2,7 @@ title: length categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Count the number of items in an input list, rows in a table, or bytes in binary data. usage: | diff --git a/commands/docs/let-env.md b/commands/docs/let-env.md index 508f32fffb2..3734c4c33bc 100644 --- a/commands/docs/let-env.md +++ b/commands/docs/let-env.md @@ -2,7 +2,7 @@ title: let-env categories: | removed -version: 0.106.0 +version: 0.107.0 removed: | `let-env FOO = ...` has been removed, use `$env.FOO = ...` instead. usage: | diff --git a/commands/docs/let.md b/commands/docs/let.md index 2ed6eb29173..0b73b17bc36 100644 --- a/commands/docs/let.md +++ b/commands/docs/let.md @@ -2,7 +2,7 @@ title: let categories: | core -version: 0.106.0 +version: 0.107.0 core: | Create a variable and give it a value. usage: | diff --git a/commands/docs/lines.md b/commands/docs/lines.md index 895d09a84f6..20bc5c613fe 100644 --- a/commands/docs/lines.md +++ b/commands/docs/lines.md @@ -2,7 +2,7 @@ title: lines categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Converts input to lines. usage: | diff --git a/commands/docs/load-env.md b/commands/docs/load-env.md index 0dedba66179..45d2c69f192 100644 --- a/commands/docs/load-env.md +++ b/commands/docs/load-env.md @@ -2,7 +2,7 @@ title: load-env categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Loads an environment update from a record. usage: | diff --git a/commands/docs/loop.md b/commands/docs/loop.md index f8374197520..5e3bc916a11 100644 --- a/commands/docs/loop.md +++ b/commands/docs/loop.md @@ -2,7 +2,7 @@ title: loop categories: | core -version: 0.106.0 +version: 0.107.0 core: | Run a block in a loop. usage: | diff --git a/commands/docs/ls.md b/commands/docs/ls.md index aa83f5f5d24..d0bd63eebcc 100644 --- a/commands/docs/ls.md +++ b/commands/docs/ls.md @@ -2,7 +2,7 @@ title: ls categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | List the filenames, sizes, and modification times of items in a directory. usage: | diff --git a/commands/docs/match.md b/commands/docs/match.md index e09df119b9b..036965dfbc8 100644 --- a/commands/docs/match.md +++ b/commands/docs/match.md @@ -2,7 +2,7 @@ title: match categories: | core -version: 0.106.0 +version: 0.107.0 core: | Conditionally run a block on a matched value. usage: | diff --git a/commands/docs/math.md b/commands/docs/math.md index 111bd4b813d..72c6740000f 100644 --- a/commands/docs/math.md +++ b/commands/docs/math.md @@ -2,7 +2,7 @@ title: math categories: | math -version: 0.106.0 +version: 0.107.0 math: | Use mathematical functions as aggregate functions on a list of numbers or tables. usage: | diff --git a/commands/docs/math_abs.md b/commands/docs/math_abs.md index 8bfd4c7d31c..321fbde836c 100644 --- a/commands/docs/math_abs.md +++ b/commands/docs/math_abs.md @@ -2,7 +2,7 @@ title: math abs categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the absolute value of a number. usage: | diff --git a/commands/docs/math_arccos.md b/commands/docs/math_arccos.md index b92f48fae2d..179fbcd5787 100644 --- a/commands/docs/math_arccos.md +++ b/commands/docs/math_arccos.md @@ -2,7 +2,7 @@ title: math arccos categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the arccosine of the number. usage: | diff --git a/commands/docs/math_arccosh.md b/commands/docs/math_arccosh.md index 251a7641fa5..07fe815b9b7 100644 --- a/commands/docs/math_arccosh.md +++ b/commands/docs/math_arccosh.md @@ -2,7 +2,7 @@ title: math arccosh categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the inverse of the hyperbolic cosine function. usage: | diff --git a/commands/docs/math_arcsin.md b/commands/docs/math_arcsin.md index d300dd17646..329fa7125e3 100644 --- a/commands/docs/math_arcsin.md +++ b/commands/docs/math_arcsin.md @@ -2,7 +2,7 @@ title: math arcsin categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the arcsine of the number. usage: | diff --git a/commands/docs/math_arcsinh.md b/commands/docs/math_arcsinh.md index 4b2046f6443..cc681d5fd13 100644 --- a/commands/docs/math_arcsinh.md +++ b/commands/docs/math_arcsinh.md @@ -2,7 +2,7 @@ title: math arcsinh categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the inverse of the hyperbolic sine function. usage: | diff --git a/commands/docs/math_arctan.md b/commands/docs/math_arctan.md index 824b2721784..a24b0db1198 100644 --- a/commands/docs/math_arctan.md +++ b/commands/docs/math_arctan.md @@ -2,7 +2,7 @@ title: math arctan categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the arctangent of the number. usage: | diff --git a/commands/docs/math_arctanh.md b/commands/docs/math_arctanh.md index ad54182096f..cebf1ea50e0 100644 --- a/commands/docs/math_arctanh.md +++ b/commands/docs/math_arctanh.md @@ -2,7 +2,7 @@ title: math arctanh categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the inverse of the hyperbolic tangent function. usage: | diff --git a/commands/docs/math_avg.md b/commands/docs/math_avg.md index 78ccb602e08..8531f4b9042 100644 --- a/commands/docs/math_avg.md +++ b/commands/docs/math_avg.md @@ -2,7 +2,7 @@ title: math avg categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the average of a list of numbers. usage: | diff --git a/commands/docs/math_ceil.md b/commands/docs/math_ceil.md index 118a4014622..e7f550fb43f 100644 --- a/commands/docs/math_ceil.md +++ b/commands/docs/math_ceil.md @@ -2,7 +2,7 @@ title: math ceil categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the ceil of a number (smallest integer greater than or equal to that number). usage: | diff --git a/commands/docs/math_cos.md b/commands/docs/math_cos.md index 90b5c875a9c..561b3ad53eb 100644 --- a/commands/docs/math_cos.md +++ b/commands/docs/math_cos.md @@ -2,7 +2,7 @@ title: math cos categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the cosine of the number. usage: | diff --git a/commands/docs/math_cosh.md b/commands/docs/math_cosh.md index 49d7ea5e9a7..8c27213fe09 100644 --- a/commands/docs/math_cosh.md +++ b/commands/docs/math_cosh.md @@ -2,7 +2,7 @@ title: math cosh categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the hyperbolic cosine of the number. usage: | diff --git a/commands/docs/math_exp.md b/commands/docs/math_exp.md index b15989164ee..3a1cc427ac7 100644 --- a/commands/docs/math_exp.md +++ b/commands/docs/math_exp.md @@ -2,7 +2,7 @@ title: math exp categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns e raised to the power of x. usage: | diff --git a/commands/docs/math_floor.md b/commands/docs/math_floor.md index 91fbe0cc22e..180bad4be23 100644 --- a/commands/docs/math_floor.md +++ b/commands/docs/math_floor.md @@ -2,7 +2,7 @@ title: math floor categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the floor of a number (largest integer less than or equal to that number). usage: | diff --git a/commands/docs/math_ln.md b/commands/docs/math_ln.md index 92ab6674d89..a79e0b8ccd3 100644 --- a/commands/docs/math_ln.md +++ b/commands/docs/math_ln.md @@ -2,7 +2,7 @@ title: math ln categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the natural logarithm. Base: (math e). usage: | diff --git a/commands/docs/math_log.md b/commands/docs/math_log.md index 7db584f1155..9c1d27051a1 100644 --- a/commands/docs/math_log.md +++ b/commands/docs/math_log.md @@ -2,7 +2,7 @@ title: math log categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the logarithm for an arbitrary base. usage: | diff --git a/commands/docs/math_max.md b/commands/docs/math_max.md index 421b9fb5833..cda8270b440 100644 --- a/commands/docs/math_max.md +++ b/commands/docs/math_max.md @@ -2,7 +2,7 @@ title: math max categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the maximum of a list of values, or of columns in a table. usage: | diff --git a/commands/docs/math_median.md b/commands/docs/math_median.md index 248935706c8..7793e1bad81 100644 --- a/commands/docs/math_median.md +++ b/commands/docs/math_median.md @@ -2,7 +2,7 @@ title: math median categories: | math -version: 0.106.0 +version: 0.107.0 math: | Computes the median of a list of numbers. usage: | diff --git a/commands/docs/math_min.md b/commands/docs/math_min.md index f6df9052473..11abde97400 100644 --- a/commands/docs/math_min.md +++ b/commands/docs/math_min.md @@ -2,7 +2,7 @@ title: math min categories: | math -version: 0.106.0 +version: 0.107.0 math: | Finds the minimum within a list of values or tables. usage: | diff --git a/commands/docs/math_mode.md b/commands/docs/math_mode.md index 3b91336633e..ad5774af723 100644 --- a/commands/docs/math_mode.md +++ b/commands/docs/math_mode.md @@ -2,7 +2,7 @@ title: math mode categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the most frequent element(s) from a list of numbers or tables. usage: | diff --git a/commands/docs/math_product.md b/commands/docs/math_product.md index 95d960cfff2..9dafe26d6c7 100644 --- a/commands/docs/math_product.md +++ b/commands/docs/math_product.md @@ -2,7 +2,7 @@ title: math product categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the product of a list of numbers or the products of each column of a table. usage: | diff --git a/commands/docs/math_round.md b/commands/docs/math_round.md index 72591c080e8..3ed1744ce92 100644 --- a/commands/docs/math_round.md +++ b/commands/docs/math_round.md @@ -2,7 +2,7 @@ title: math round categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the input number rounded to the specified precision. usage: | diff --git a/commands/docs/math_sin.md b/commands/docs/math_sin.md index 40b0e76b158..2bd15ef4c26 100644 --- a/commands/docs/math_sin.md +++ b/commands/docs/math_sin.md @@ -2,7 +2,7 @@ title: math sin categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the sine of the number. usage: | diff --git a/commands/docs/math_sinh.md b/commands/docs/math_sinh.md index 72560f6ded9..dfbd65b62cb 100644 --- a/commands/docs/math_sinh.md +++ b/commands/docs/math_sinh.md @@ -2,7 +2,7 @@ title: math sinh categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the hyperbolic sine of the number. usage: | diff --git a/commands/docs/math_sqrt.md b/commands/docs/math_sqrt.md index 59a42038ae1..77556cb2bf6 100644 --- a/commands/docs/math_sqrt.md +++ b/commands/docs/math_sqrt.md @@ -2,7 +2,7 @@ title: math sqrt categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the square root of the input number. usage: | diff --git a/commands/docs/math_stddev.md b/commands/docs/math_stddev.md index 6df1303d54d..e05583c8252 100644 --- a/commands/docs/math_stddev.md +++ b/commands/docs/math_stddev.md @@ -2,7 +2,7 @@ title: math stddev categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the standard deviation of a list of numbers, or of each column in a table. usage: | diff --git a/commands/docs/math_sum.md b/commands/docs/math_sum.md index b2c0930ec0b..c3d7704156f 100644 --- a/commands/docs/math_sum.md +++ b/commands/docs/math_sum.md @@ -2,7 +2,7 @@ title: math sum categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the sum of a list of numbers or of each column in a table. usage: | diff --git a/commands/docs/math_tan.md b/commands/docs/math_tan.md index 5ade44cec29..84bfb4f13f5 100644 --- a/commands/docs/math_tan.md +++ b/commands/docs/math_tan.md @@ -2,7 +2,7 @@ title: math tan categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the tangent of the number. usage: | diff --git a/commands/docs/math_tanh.md b/commands/docs/math_tanh.md index 40f104e8eac..50f5ee4aa2d 100644 --- a/commands/docs/math_tanh.md +++ b/commands/docs/math_tanh.md @@ -2,7 +2,7 @@ title: math tanh categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the hyperbolic tangent of the number. usage: | diff --git a/commands/docs/math_variance.md b/commands/docs/math_variance.md index 5624e90a00c..ce7f51aafa5 100644 --- a/commands/docs/math_variance.md +++ b/commands/docs/math_variance.md @@ -2,7 +2,7 @@ title: math variance categories: | math -version: 0.106.0 +version: 0.107.0 math: | Returns the variance of a list of numbers or of each column in a table. usage: | diff --git a/commands/docs/merge.md b/commands/docs/merge.md index 11f1a4c7b2f..7ff508e6315 100644 --- a/commands/docs/merge.md +++ b/commands/docs/merge.md @@ -2,7 +2,7 @@ title: merge categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Merge the input with a record or table, overwriting values in matching columns. usage: | diff --git a/commands/docs/merge_deep.md b/commands/docs/merge_deep.md index a980c392d61..71ec87365a8 100644 --- a/commands/docs/merge_deep.md +++ b/commands/docs/merge_deep.md @@ -2,7 +2,7 @@ title: merge deep categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Merge the input with a record or table, recursively merging values in matching columns. usage: | diff --git a/commands/docs/metadata.md b/commands/docs/metadata.md index 9467c662084..0948fc0c039 100644 --- a/commands/docs/metadata.md +++ b/commands/docs/metadata.md @@ -2,7 +2,7 @@ title: metadata categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Get the metadata for items in the stream. usage: | diff --git a/commands/docs/metadata_access.md b/commands/docs/metadata_access.md index cfcc9810b34..fbd62cd3292 100644 --- a/commands/docs/metadata_access.md +++ b/commands/docs/metadata_access.md @@ -2,7 +2,7 @@ title: metadata access categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Access the metadata for the input stream within a closure. usage: | diff --git a/commands/docs/metadata_set.md b/commands/docs/metadata_set.md index 92bff92c2ac..454629ef6af 100644 --- a/commands/docs/metadata_set.md +++ b/commands/docs/metadata_set.md @@ -2,7 +2,7 @@ title: metadata set categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Set the metadata for items in the stream. usage: | diff --git a/commands/docs/mkdir.md b/commands/docs/mkdir.md index 13e0eecbfbf..f957a5d3ee2 100644 --- a/commands/docs/mkdir.md +++ b/commands/docs/mkdir.md @@ -2,7 +2,7 @@ title: mkdir categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Create directories, with intermediary directories if required using uutils/coreutils mkdir. usage: | diff --git a/commands/docs/mktemp.md b/commands/docs/mktemp.md index dd70d46c416..e74a5c86d63 100644 --- a/commands/docs/mktemp.md +++ b/commands/docs/mktemp.md @@ -2,7 +2,7 @@ title: mktemp categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Create temporary files or directories using uutils/coreutils mktemp. usage: | diff --git a/commands/docs/module.md b/commands/docs/module.md index 3d6e94fa408..a48c664e18f 100644 --- a/commands/docs/module.md +++ b/commands/docs/module.md @@ -2,7 +2,7 @@ title: module categories: | core -version: 0.106.0 +version: 0.107.0 core: | Define a custom module. usage: | diff --git a/commands/docs/move.md b/commands/docs/move.md index 24404e4b230..3e9e51bcbe0 100644 --- a/commands/docs/move.md +++ b/commands/docs/move.md @@ -2,7 +2,7 @@ title: move categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Moves columns relative to other columns or make them the first/last columns. Flags are mutually exclusive. usage: | diff --git a/commands/docs/mut.md b/commands/docs/mut.md index 20831946732..bbf18e4e5f6 100644 --- a/commands/docs/mut.md +++ b/commands/docs/mut.md @@ -2,7 +2,7 @@ title: mut categories: | core -version: 0.106.0 +version: 0.107.0 core: | Create a mutable variable and give it a value. usage: | diff --git a/commands/docs/mv.md b/commands/docs/mv.md index 7c3d59e1fa5..b6ffa3e2847 100644 --- a/commands/docs/mv.md +++ b/commands/docs/mv.md @@ -2,7 +2,7 @@ title: mv categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Move files or directories using uutils/coreutils mv. usage: | diff --git a/commands/docs/nu-check.md b/commands/docs/nu-check.md index 37ba4da4891..d660482a404 100644 --- a/commands/docs/nu-check.md +++ b/commands/docs/nu-check.md @@ -2,7 +2,7 @@ title: nu-check categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Validate and parse input content. usage: | diff --git a/commands/docs/nu-highlight.md b/commands/docs/nu-highlight.md index e3bb7acbb1c..89088d64dca 100644 --- a/commands/docs/nu-highlight.md +++ b/commands/docs/nu-highlight.md @@ -2,7 +2,7 @@ title: nu-highlight categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Syntax highlight the input string. usage: | diff --git a/commands/docs/open.md b/commands/docs/open.md index 19d91180992..9dadb38ce4f 100644 --- a/commands/docs/open.md +++ b/commands/docs/open.md @@ -2,7 +2,7 @@ title: open categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Load a file into a cell, converting to table if possible (avoid by appending '--raw'). usage: | diff --git a/commands/docs/overlay.md b/commands/docs/overlay.md index 8467ad6bbdb..2eedfd75473 100644 --- a/commands/docs/overlay.md +++ b/commands/docs/overlay.md @@ -2,7 +2,7 @@ title: overlay categories: | core -version: 0.106.0 +version: 0.107.0 core: | Commands for manipulating overlays. usage: | @@ -37,6 +37,6 @@ This command is a parser keyword. For details, check: | name | description | type | | ------------------------------------------------ | -------------------------------------------- | -------- | | [`overlay hide`](/commands/docs/overlay_hide.md) | Hide an active overlay. | keyword | -| [`overlay list`](/commands/docs/overlay_list.md) | List all active overlays. | built-in | +| [`overlay list`](/commands/docs/overlay_list.md) | List all overlays with their active status. | built-in | | [`overlay new`](/commands/docs/overlay_new.md) | Create an empty overlay. | keyword | | [`overlay use`](/commands/docs/overlay_use.md) | Use definitions from a module as an overlay. | keyword | \ No newline at end of file diff --git a/commands/docs/overlay_hide.md b/commands/docs/overlay_hide.md index fef9c706ca0..0dd7aa7b1b6 100644 --- a/commands/docs/overlay_hide.md +++ b/commands/docs/overlay_hide.md @@ -2,7 +2,7 @@ title: overlay hide categories: | core -version: 0.106.0 +version: 0.107.0 core: | Hide an active overlay. usage: | diff --git a/commands/docs/overlay_list.md b/commands/docs/overlay_list.md index 68c887fe6b5..b744dcd03f7 100644 --- a/commands/docs/overlay_list.md +++ b/commands/docs/overlay_list.md @@ -2,11 +2,11 @@ title: overlay list categories: | core -version: 0.106.0 +version: 0.107.0 core: | - List all active overlays. + List all overlays with their active status. usage: | - List all active overlays. + List all overlays with their active status. editLink: false contributors: false --- @@ -14,7 +14,7 @@ contributors: false # `overlay list` for [core](/commands/categories/core.md) -
List all active overlays.
+
List all overlays with their active status.
## Signature @@ -23,18 +23,37 @@ contributors: false ## Input/output types: -| input | output | -| ------- | ------------ | -| nothing | list<string> | +| input | output | +| ------- | --------------------------------- | +| nothing | table<name: string, active: bool> | ## Examples -Get the last activated overlay +List all overlays with their active status ```nu > module spam { export def foo [] { "foo" } } overlay use spam - overlay list | last -spam + overlay list +╭───┬──────┬────────╮ +│ # │ name │ active │ +├───┼──────┼────────┤ +│ 0 │ spam │ true │ +╰───┴──────┴────────╯ + +``` + +Get overlay status after hiding +```nu +> module spam { export def foo [] { "foo" } } + overlay use spam + overlay hide spam + overlay list | where name == "spam" +╭───┬──────┬────────╮ +│ # │ name │ active │ +├───┼──────┼────────┤ +│ 0 │ spam │ false │ +╰───┴──────┴────────╯ + ``` ## Notes -The overlays are listed in the order they were activated. \ No newline at end of file +The overlays are listed in the order they were activated. Hidden overlays are listed first, followed by active overlays listed in the order that they were activated. `last` command will always give the top active overlay \ No newline at end of file diff --git a/commands/docs/overlay_new.md b/commands/docs/overlay_new.md index 18ca3710b22..8f992a603f5 100644 --- a/commands/docs/overlay_new.md +++ b/commands/docs/overlay_new.md @@ -2,7 +2,7 @@ title: overlay new categories: | core -version: 0.106.0 +version: 0.107.0 core: | Create an empty overlay. usage: | diff --git a/commands/docs/overlay_use.md b/commands/docs/overlay_use.md index a545e7db0a3..616d1148a59 100644 --- a/commands/docs/overlay_use.md +++ b/commands/docs/overlay_use.md @@ -2,7 +2,7 @@ title: overlay use categories: | core -version: 0.106.0 +version: 0.107.0 core: | Use definitions from a module as an overlay. usage: | diff --git a/commands/docs/panic.md b/commands/docs/panic.md index 139a65b6f4a..bde5a2ed65e 100644 --- a/commands/docs/panic.md +++ b/commands/docs/panic.md @@ -2,7 +2,7 @@ title: panic categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Causes nushell to panic. usage: | diff --git a/commands/docs/par-each.md b/commands/docs/par-each.md index 90dd0644248..67869be3658 100644 --- a/commands/docs/par-each.md +++ b/commands/docs/par-each.md @@ -2,7 +2,7 @@ title: par-each categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Run a closure on each row of the input list in parallel, creating a new list with the results. usage: | diff --git a/commands/docs/parse.md b/commands/docs/parse.md index 407f95c3894..e52773af2b7 100644 --- a/commands/docs/parse.md +++ b/commands/docs/parse.md @@ -2,7 +2,7 @@ title: parse categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Parse columns from string data using a simple pattern or a supplied regular expression. usage: | diff --git a/commands/docs/path.md b/commands/docs/path.md index 91d6ce2547f..2b9842ce688 100644 --- a/commands/docs/path.md +++ b/commands/docs/path.md @@ -2,7 +2,7 @@ title: path categories: | path -version: 0.106.0 +version: 0.107.0 path: | Explore and manipulate paths. usage: | diff --git a/commands/docs/path_basename.md b/commands/docs/path_basename.md index 87cc0ef7435..9c4775bad4d 100644 --- a/commands/docs/path_basename.md +++ b/commands/docs/path_basename.md @@ -2,7 +2,7 @@ title: path basename categories: | path -version: 0.106.0 +version: 0.107.0 path: | Get the final component of a path. usage: | diff --git a/commands/docs/path_dirname.md b/commands/docs/path_dirname.md index e6465bedf15..21e4b4f813e 100644 --- a/commands/docs/path_dirname.md +++ b/commands/docs/path_dirname.md @@ -2,7 +2,7 @@ title: path dirname categories: | path -version: 0.106.0 +version: 0.107.0 path: | Get the parent directory of a path. usage: | diff --git a/commands/docs/path_exists.md b/commands/docs/path_exists.md index 69f4c31b72b..7879440bc49 100644 --- a/commands/docs/path_exists.md +++ b/commands/docs/path_exists.md @@ -2,7 +2,7 @@ title: path exists categories: | path -version: 0.106.0 +version: 0.107.0 path: | Check whether a path exists. usage: | diff --git a/commands/docs/path_expand.md b/commands/docs/path_expand.md index 434747ff54c..bc925ff60fc 100644 --- a/commands/docs/path_expand.md +++ b/commands/docs/path_expand.md @@ -2,7 +2,7 @@ title: path expand categories: | path -version: 0.106.0 +version: 0.107.0 path: | Try to expand a path to its absolute form. usage: | diff --git a/commands/docs/path_join.md b/commands/docs/path_join.md index ba7fdcf744d..8ebaf6da602 100644 --- a/commands/docs/path_join.md +++ b/commands/docs/path_join.md @@ -2,7 +2,7 @@ title: path join categories: | path -version: 0.106.0 +version: 0.107.0 path: | Join a structured path or a list of path parts. usage: | diff --git a/commands/docs/path_parse.md b/commands/docs/path_parse.md index b6f0bf54972..dcdfe5a8a92 100644 --- a/commands/docs/path_parse.md +++ b/commands/docs/path_parse.md @@ -2,7 +2,7 @@ title: path parse categories: | path -version: 0.106.0 +version: 0.107.0 path: | Convert a path into structured data. usage: | diff --git a/commands/docs/path_relative-to.md b/commands/docs/path_relative-to.md index e8d882c1693..fa54b85e05e 100644 --- a/commands/docs/path_relative-to.md +++ b/commands/docs/path_relative-to.md @@ -2,7 +2,7 @@ title: path relative-to categories: | path -version: 0.106.0 +version: 0.107.0 path: | Express a path as relative to another path. usage: | diff --git a/commands/docs/path_self.md b/commands/docs/path_self.md index 529d74d574f..820cb88cfbc 100644 --- a/commands/docs/path_self.md +++ b/commands/docs/path_self.md @@ -2,7 +2,7 @@ title: path self categories: | path -version: 0.106.0 +version: 0.107.0 path: | Get the absolute path of the script or module containing this command at parse time. usage: | diff --git a/commands/docs/path_split.md b/commands/docs/path_split.md index 8b7ae2febc0..da094beb1f4 100644 --- a/commands/docs/path_split.md +++ b/commands/docs/path_split.md @@ -2,7 +2,7 @@ title: path split categories: | path -version: 0.106.0 +version: 0.107.0 path: | Split a path into a list based on the system's path separator. usage: | diff --git a/commands/docs/path_type.md b/commands/docs/path_type.md index a5715e7fa06..0e564f8883f 100644 --- a/commands/docs/path_type.md +++ b/commands/docs/path_type.md @@ -2,7 +2,7 @@ title: path type categories: | path -version: 0.106.0 +version: 0.107.0 path: | Get the type of the object a path refers to (e.g., file, dir, symlink). usage: | diff --git a/commands/docs/plugin.md b/commands/docs/plugin.md index 64341c685c0..79d739b71ae 100644 --- a/commands/docs/plugin.md +++ b/commands/docs/plugin.md @@ -2,7 +2,7 @@ title: plugin categories: | plugin -version: 0.106.0 +version: 0.107.0 plugin: | Commands for managing plugins. usage: | diff --git a/commands/docs/plugin_add.md b/commands/docs/plugin_add.md index afe207f7854..db0cee0efe5 100644 --- a/commands/docs/plugin_add.md +++ b/commands/docs/plugin_add.md @@ -2,7 +2,7 @@ title: plugin add categories: | plugin -version: 0.106.0 +version: 0.107.0 plugin: | Add a plugin to the plugin registry file. usage: | diff --git a/commands/docs/plugin_list.md b/commands/docs/plugin_list.md index a9939911023..25f706905e2 100644 --- a/commands/docs/plugin_list.md +++ b/commands/docs/plugin_list.md @@ -2,7 +2,7 @@ title: plugin list categories: | plugin -version: 0.106.0 +version: 0.107.0 plugin: | List loaded and installed plugins. usage: | @@ -37,13 +37,13 @@ contributors: false List installed plugins. ```nu > plugin list -╭───┬──────┬────────────────────┬─────────┬────────┬───────────────────────────────┬───────┬─────────────╮ -│ # │ name │ version │ status │ pid │ filename │ shell │ commands │ -├───┼──────┼────────────────────┼─────────┼────────┼───────────────────────────────┼───────┼─────────────┤ -│ 0 │ inc │ 0.106.0 │ running │ 106480 │ /opt/nu/plugins/nu_plugin_inc │ │ ╭───┬─────╮ │ -│ │ │ │ │ │ │ │ │ 0 │ inc │ │ -│ │ │ │ │ │ │ │ ╰───┴─────╯ │ -╰───┴──────┴────────────────────┴─────────┴────────┴───────────────────────────────┴───────┴─────────────╯ +╭───┬──────┬─────────┬─────────┬────────┬───────────────────────────────┬───────┬─────────────╮ +│ # │ name │ version │ status │ pid │ filename │ shell │ commands │ +├───┼──────┼─────────┼─────────┼────────┼───────────────────────────────┼───────┼─────────────┤ +│ 0 │ inc │ 0.107.0 │ running │ 106480 │ /opt/nu/plugins/nu_plugin_inc │ │ ╭───┬─────╮ │ +│ │ │ │ │ │ │ │ │ 0 │ inc │ │ +│ │ │ │ │ │ │ │ ╰───┴─────╯ │ +╰───┴──────┴─────────┴─────────┴────────┴───────────────────────────────┴───────┴─────────────╯ ``` diff --git a/commands/docs/plugin_rm.md b/commands/docs/plugin_rm.md index 766f65c5ca0..7df532299b6 100644 --- a/commands/docs/plugin_rm.md +++ b/commands/docs/plugin_rm.md @@ -2,7 +2,7 @@ title: plugin rm categories: | plugin -version: 0.106.0 +version: 0.107.0 plugin: | Remove a plugin from the plugin registry file. usage: | diff --git a/commands/docs/plugin_stop.md b/commands/docs/plugin_stop.md index 6a3465bb001..d17945b1aaa 100644 --- a/commands/docs/plugin_stop.md +++ b/commands/docs/plugin_stop.md @@ -2,7 +2,7 @@ title: plugin stop categories: | plugin -version: 0.106.0 +version: 0.107.0 plugin: | Stop an installed plugin if it was running. usage: | diff --git a/commands/docs/plugin_use.md b/commands/docs/plugin_use.md index 815413f023f..9fd41d1071e 100644 --- a/commands/docs/plugin_use.md +++ b/commands/docs/plugin_use.md @@ -2,7 +2,7 @@ title: plugin use categories: | plugin -version: 0.106.0 +version: 0.107.0 plugin: | Load a plugin from the plugin registry file into scope. usage: | diff --git a/commands/docs/polars.md b/commands/docs/polars.md index b4d6bdd5d44..967803aa90e 100644 --- a/commands/docs/polars.md +++ b/commands/docs/polars.md @@ -2,7 +2,7 @@ title: polars categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Operate with data in a dataframe format. usage: | diff --git a/commands/docs/polars_agg-groups.md b/commands/docs/polars_agg-groups.md index 5d1aa4d7891..a73df422140 100644 --- a/commands/docs/polars_agg-groups.md +++ b/commands/docs/polars_agg-groups.md @@ -2,7 +2,7 @@ title: polars agg-groups categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates an agg_groups expression. usage: | diff --git a/commands/docs/polars_agg.md b/commands/docs/polars_agg.md index e426f311400..9e085efc8a5 100644 --- a/commands/docs/polars_agg.md +++ b/commands/docs/polars_agg.md @@ -2,7 +2,7 @@ title: polars agg categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Performs a series of aggregations from a group-by. usage: | diff --git a/commands/docs/polars_all-false.md b/commands/docs/polars_all-false.md index 8cf4bf49364..b17015db686 100644 --- a/commands/docs/polars_all-false.md +++ b/commands/docs/polars_all-false.md @@ -2,7 +2,7 @@ title: polars all-false categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns true if all values are false. usage: | diff --git a/commands/docs/polars_all-true.md b/commands/docs/polars_all-true.md index aeb8591dc35..9be85cb28ff 100644 --- a/commands/docs/polars_all-true.md +++ b/commands/docs/polars_all-true.md @@ -2,7 +2,7 @@ title: polars all-true categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns true if all values are true. usage: | diff --git a/commands/docs/polars_append.md b/commands/docs/polars_append.md index 982d64835cc..9f7fdcb32e3 100644 --- a/commands/docs/polars_append.md +++ b/commands/docs/polars_append.md @@ -2,7 +2,7 @@ title: polars append categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Appends a new dataframe. usage: | diff --git a/commands/docs/polars_arg-max.md b/commands/docs/polars_arg-max.md index c537fcb58fc..49bb88c08ce 100644 --- a/commands/docs/polars_arg-max.md +++ b/commands/docs/polars_arg-max.md @@ -2,7 +2,7 @@ title: polars arg-max categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Return index for max value in series. usage: | diff --git a/commands/docs/polars_arg-min.md b/commands/docs/polars_arg-min.md index 475b5f896d3..7c3ff7036a0 100644 --- a/commands/docs/polars_arg-min.md +++ b/commands/docs/polars_arg-min.md @@ -2,7 +2,7 @@ title: polars arg-min categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Return index for min value in series. usage: | diff --git a/commands/docs/polars_arg-sort.md b/commands/docs/polars_arg-sort.md index b75ea5eb2ef..8d2a87b6050 100644 --- a/commands/docs/polars_arg-sort.md +++ b/commands/docs/polars_arg-sort.md @@ -2,7 +2,7 @@ title: polars arg-sort categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns indexes for a sorted series. usage: | diff --git a/commands/docs/polars_arg-true.md b/commands/docs/polars_arg-true.md index c3ead594954..0475448d1d6 100644 --- a/commands/docs/polars_arg-true.md +++ b/commands/docs/polars_arg-true.md @@ -2,7 +2,7 @@ title: polars arg-true categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns indexes where values are true. usage: | diff --git a/commands/docs/polars_arg-unique.md b/commands/docs/polars_arg-unique.md index 364a2e2c2f2..950167c9dfc 100644 --- a/commands/docs/polars_arg-unique.md +++ b/commands/docs/polars_arg-unique.md @@ -2,7 +2,7 @@ title: polars arg-unique categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns indexes for unique values. usage: | diff --git a/commands/docs/polars_arg-where.md b/commands/docs/polars_arg-where.md index ed6ba392a31..013c42a1ebd 100644 --- a/commands/docs/polars_arg-where.md +++ b/commands/docs/polars_arg-where.md @@ -2,7 +2,7 @@ title: polars arg-where categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates an expression that returns the arguments where expression is true. usage: | diff --git a/commands/docs/polars_as-date.md b/commands/docs/polars_as-date.md index cc5f0371817..5c40975c007 100644 --- a/commands/docs/polars_as-date.md +++ b/commands/docs/polars_as-date.md @@ -2,7 +2,7 @@ title: polars as-date categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Converts string to date. usage: | diff --git a/commands/docs/polars_as-datetime.md b/commands/docs/polars_as-datetime.md index 0cbaa6ca931..2a1cdd8da1b 100644 --- a/commands/docs/polars_as-datetime.md +++ b/commands/docs/polars_as-datetime.md @@ -2,7 +2,7 @@ title: polars as-datetime categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Converts string to datetime. usage: | @@ -92,10 +92,10 @@ Converts string to datetime using the `--not-exact` flag even with excessive sym ╭───┬─────────────╮ │ # │ datetime │ ├───┼─────────────┤ -│ 0 │ in 3 months │ -│ 1 │ in 3 months │ -│ 2 │ in 3 months │ -│ 3 │ in 3 months │ +│ 0 │ in 2 months │ +│ 1 │ in 2 months │ +│ 2 │ in 2 months │ +│ 3 │ in 2 months │ ╰───┴─────────────╯ ``` diff --git a/commands/docs/polars_as.md b/commands/docs/polars_as.md index 035e7118d1a..274d9127fbc 100644 --- a/commands/docs/polars_as.md +++ b/commands/docs/polars_as.md @@ -2,7 +2,7 @@ title: polars as categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates an alias expression. usage: | diff --git a/commands/docs/polars_cache.md b/commands/docs/polars_cache.md index baa1ce37022..bf1c1ede666 100644 --- a/commands/docs/polars_cache.md +++ b/commands/docs/polars_cache.md @@ -2,7 +2,7 @@ title: polars cache categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Caches operations in a new LazyFrame. usage: | diff --git a/commands/docs/polars_cast.md b/commands/docs/polars_cast.md index 7fb29b6b39e..cf1782de125 100644 --- a/commands/docs/polars_cast.md +++ b/commands/docs/polars_cast.md @@ -2,7 +2,7 @@ title: polars cast categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Cast a column to a different dtype. usage: | diff --git a/commands/docs/polars_col.md b/commands/docs/polars_col.md index 784d0d8a981..a4cc72775f0 100644 --- a/commands/docs/polars_col.md +++ b/commands/docs/polars_col.md @@ -2,7 +2,7 @@ title: polars col categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates a named column expression. usage: | diff --git a/commands/docs/polars_collect.md b/commands/docs/polars_collect.md index 1f9fcaafb93..640d967fb5c 100644 --- a/commands/docs/polars_collect.md +++ b/commands/docs/polars_collect.md @@ -2,7 +2,7 @@ title: polars collect categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Collect lazy dataframe into eager dataframe. usage: | diff --git a/commands/docs/polars_columns.md b/commands/docs/polars_columns.md index b4898f680ff..f53e9f247ea 100644 --- a/commands/docs/polars_columns.md +++ b/commands/docs/polars_columns.md @@ -2,7 +2,7 @@ title: polars columns categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Show dataframe columns. usage: | diff --git a/commands/docs/polars_concat-str.md b/commands/docs/polars_concat-str.md index edd62ce8dff..0ce428ca8e6 100644 --- a/commands/docs/polars_concat-str.md +++ b/commands/docs/polars_concat-str.md @@ -2,7 +2,7 @@ title: polars concat-str categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates a concat string expression. usage: | diff --git a/commands/docs/polars_concat.md b/commands/docs/polars_concat.md index b71d4deb117..333ee1b6e7f 100644 --- a/commands/docs/polars_concat.md +++ b/commands/docs/polars_concat.md @@ -2,7 +2,7 @@ title: polars concat categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Concatenate two or more dataframes. usage: | diff --git a/commands/docs/polars_contains.md b/commands/docs/polars_contains.md index 6cc2de4cf28..67672907b42 100644 --- a/commands/docs/polars_contains.md +++ b/commands/docs/polars_contains.md @@ -2,7 +2,7 @@ title: polars contains categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Checks if a pattern is contained in a string. usage: | diff --git a/commands/docs/polars_convert-time-zone.md b/commands/docs/polars_convert-time-zone.md index ad43ca94b13..185cb592a62 100644 --- a/commands/docs/polars_convert-time-zone.md +++ b/commands/docs/polars_convert-time-zone.md @@ -2,7 +2,7 @@ title: polars convert-time-zone categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Convert datetime to target timezone. usage: | @@ -47,8 +47,8 @@ Convert timezone for timezone-aware datetime ╭───┬──────────────╮ │ # │ datetime │ ├───┼──────────────┤ -│ 0 │ 3 months ago │ -│ 1 │ 3 months ago │ +│ 0 │ 4 months ago │ +│ 1 │ 4 months ago │ ╰───┴──────────────╯ ``` @@ -61,8 +61,8 @@ Timezone conversions for timezone-naive datetime will assume the original timezo ╭───┬──────────────╮ │ # │ datetime │ ├───┼──────────────┤ -│ 0 │ 3 months ago │ -│ 1 │ 3 months ago │ +│ 0 │ 4 months ago │ +│ 1 │ 4 months ago │ ╰───┴──────────────╯ ``` diff --git a/commands/docs/polars_count-null.md b/commands/docs/polars_count-null.md index 2e6e4e068ad..46704c68d7f 100644 --- a/commands/docs/polars_count-null.md +++ b/commands/docs/polars_count-null.md @@ -2,7 +2,7 @@ title: polars count-null categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Counts null values. usage: | diff --git a/commands/docs/polars_count.md b/commands/docs/polars_count.md index 66344dda427..ba9749304a8 100644 --- a/commands/docs/polars_count.md +++ b/commands/docs/polars_count.md @@ -2,7 +2,7 @@ title: polars count categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns the number of non-null values in the column. usage: | diff --git a/commands/docs/polars_cumulative.md b/commands/docs/polars_cumulative.md index 43c3708c007..b8d7885d0a3 100644 --- a/commands/docs/polars_cumulative.md +++ b/commands/docs/polars_cumulative.md @@ -2,7 +2,7 @@ title: polars cumulative categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Cumulative calculation for a column or series. usage: | diff --git a/commands/docs/polars_cut.md b/commands/docs/polars_cut.md index 4ee9e22c3d9..20a78368967 100644 --- a/commands/docs/polars_cut.md +++ b/commands/docs/polars_cut.md @@ -2,7 +2,7 @@ title: polars cut categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Bin continuous values into discrete categories for a series. usage: | diff --git a/commands/docs/polars_datepart.md b/commands/docs/polars_datepart.md index 9321c7289ce..d6ab29def5d 100644 --- a/commands/docs/polars_datepart.md +++ b/commands/docs/polars_datepart.md @@ -2,7 +2,7 @@ title: polars datepart categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates an expression for capturing the specified datepart in a column. usage: | diff --git a/commands/docs/polars_decimal.md b/commands/docs/polars_decimal.md index ac9a7380d68..cba75896841 100644 --- a/commands/docs/polars_decimal.md +++ b/commands/docs/polars_decimal.md @@ -2,7 +2,7 @@ title: polars decimal categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Converts a string column into a decimal column usage: | diff --git a/commands/docs/polars_drop-duplicates.md b/commands/docs/polars_drop-duplicates.md index d80ddc4a2ca..b1541ba58ba 100644 --- a/commands/docs/polars_drop-duplicates.md +++ b/commands/docs/polars_drop-duplicates.md @@ -2,7 +2,7 @@ title: polars drop-duplicates categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Drops duplicate values in dataframe. usage: | diff --git a/commands/docs/polars_drop-nulls.md b/commands/docs/polars_drop-nulls.md index 2e772576975..c1f4cd59f3b 100644 --- a/commands/docs/polars_drop-nulls.md +++ b/commands/docs/polars_drop-nulls.md @@ -2,7 +2,7 @@ title: polars drop-nulls categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Drops null values in dataframe. usage: | diff --git a/commands/docs/polars_drop.md b/commands/docs/polars_drop.md index 18b7204a26a..ca96b4f53a9 100644 --- a/commands/docs/polars_drop.md +++ b/commands/docs/polars_drop.md @@ -2,7 +2,7 @@ title: polars drop categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a new dataframe by dropping the selected columns. usage: | diff --git a/commands/docs/polars_dummies.md b/commands/docs/polars_dummies.md index 3e59826c0d7..3e08e73927a 100644 --- a/commands/docs/polars_dummies.md +++ b/commands/docs/polars_dummies.md @@ -2,7 +2,7 @@ title: polars dummies categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a new dataframe with dummy variables. usage: | diff --git a/commands/docs/polars_explode.md b/commands/docs/polars_explode.md index 5b2fd8e8a35..7f9c3becfd3 100644 --- a/commands/docs/polars_explode.md +++ b/commands/docs/polars_explode.md @@ -2,7 +2,7 @@ title: polars explode categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Explodes a dataframe or creates a explode expression. usage: | diff --git a/commands/docs/polars_expr-not.md b/commands/docs/polars_expr-not.md index c274fb21483..12a5bbd45eb 100644 --- a/commands/docs/polars_expr-not.md +++ b/commands/docs/polars_expr-not.md @@ -2,7 +2,7 @@ title: polars expr-not categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a not expression. usage: | diff --git a/commands/docs/polars_fetch.md b/commands/docs/polars_fetch.md index 59a77b5cad1..ef9ab2bc44b 100644 --- a/commands/docs/polars_fetch.md +++ b/commands/docs/polars_fetch.md @@ -2,7 +2,7 @@ title: polars fetch categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Collects the lazyframe to the selected rows. usage: | diff --git a/commands/docs/polars_fill-nan.md b/commands/docs/polars_fill-nan.md index c75aee094a0..a314cf600b1 100644 --- a/commands/docs/polars_fill-nan.md +++ b/commands/docs/polars_fill-nan.md @@ -2,7 +2,7 @@ title: polars fill-nan categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Replaces NaN values with the given expression. usage: | diff --git a/commands/docs/polars_fill-null.md b/commands/docs/polars_fill-null.md index 7ea89992a01..885a638d14e 100644 --- a/commands/docs/polars_fill-null.md +++ b/commands/docs/polars_fill-null.md @@ -2,7 +2,7 @@ title: polars fill-null categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Replaces NULL values with the given expression. usage: | @@ -34,9 +34,10 @@ See the [Plugins](/book/plugins.html) chapter in the book for more information. ## Input/output types: -| input | output | -| --------- | --------- | -| dataframe | dataframe | +| input | output | +| ---------- | ---------- | +| dataframe | dataframe | +| expression | expression | ## Examples Fills the null values by 0 @@ -53,3 +54,21 @@ Fills the null values by 0 ╰───┴───╯ ``` + +Fills the null values in expression +```nu +> [[a]; [1] [2] [2] [3] [3]] + | polars into-df + | polars select (polars col a | polars shift 2 | polars fill-null 0) + | polars collect +╭───┬───╮ +│ # │ a │ +├───┼───┤ +│ 0 │ 0 │ +│ 1 │ 0 │ +│ 2 │ 1 │ +│ 3 │ 2 │ +│ 4 │ 2 │ +╰───┴───╯ + +``` diff --git a/commands/docs/polars_filter-with.md b/commands/docs/polars_filter-with.md index 6ddf5a05df0..84545bc3857 100644 --- a/commands/docs/polars_filter-with.md +++ b/commands/docs/polars_filter-with.md @@ -2,7 +2,7 @@ title: polars filter-with categories: | dataframe or lazyframe -version: 0.106.0 +version: 0.107.0 dataframe_or_lazyframe: | Filters dataframe using a mask or expression as reference. usage: | diff --git a/commands/docs/polars_filter.md b/commands/docs/polars_filter.md index 1055335c435..26a49f90062 100644 --- a/commands/docs/polars_filter.md +++ b/commands/docs/polars_filter.md @@ -2,7 +2,7 @@ title: polars filter categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Filter dataframe based in expression. usage: | @@ -58,8 +58,8 @@ Filter dataframe for rows where dt is within the last 2 days of the maximum dt v ╭───┬──────────────┬─────╮ │ # │ dt │ val │ ├───┼──────────────┼─────┤ -│ 0 │ 3 months ago │ 3 │ -│ 1 │ 3 months ago │ 4 │ +│ 0 │ 5 months ago │ 3 │ +│ 1 │ 5 months ago │ 4 │ ╰───┴──────────────┴─────╯ ``` diff --git a/commands/docs/polars_first.md b/commands/docs/polars_first.md index 105dba65a9d..c0c4a926c5c 100644 --- a/commands/docs/polars_first.md +++ b/commands/docs/polars_first.md @@ -2,7 +2,7 @@ title: polars first categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Show only the first number of rows or create a first expression usage: | diff --git a/commands/docs/polars_flatten.md b/commands/docs/polars_flatten.md index dde608d56c7..fce6ad1c29e 100644 --- a/commands/docs/polars_flatten.md +++ b/commands/docs/polars_flatten.md @@ -2,7 +2,7 @@ title: polars flatten categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | An alias for polars explode. usage: | diff --git a/commands/docs/polars_get-day.md b/commands/docs/polars_get-day.md index 991456d2c30..1b8a31c012a 100644 --- a/commands/docs/polars_get-day.md +++ b/commands/docs/polars_get-day.md @@ -2,7 +2,7 @@ title: polars get-day categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets day from date. usage: | diff --git a/commands/docs/polars_get-hour.md b/commands/docs/polars_get-hour.md index d446200202e..773079b7bf8 100644 --- a/commands/docs/polars_get-hour.md +++ b/commands/docs/polars_get-hour.md @@ -2,7 +2,7 @@ title: polars get-hour categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets hour from datetime. usage: | diff --git a/commands/docs/polars_get-minute.md b/commands/docs/polars_get-minute.md index 19ac32c2e97..859c4e088b8 100644 --- a/commands/docs/polars_get-minute.md +++ b/commands/docs/polars_get-minute.md @@ -2,7 +2,7 @@ title: polars get-minute categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets minute from date. usage: | diff --git a/commands/docs/polars_get-month.md b/commands/docs/polars_get-month.md index d9013b8dbe7..089025ebe4b 100644 --- a/commands/docs/polars_get-month.md +++ b/commands/docs/polars_get-month.md @@ -2,7 +2,7 @@ title: polars get-month categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets month from date. usage: | diff --git a/commands/docs/polars_get-nanosecond.md b/commands/docs/polars_get-nanosecond.md index 791d22fd4b2..7d41d66ef65 100644 --- a/commands/docs/polars_get-nanosecond.md +++ b/commands/docs/polars_get-nanosecond.md @@ -2,7 +2,7 @@ title: polars get-nanosecond categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets nanosecond from date. usage: | diff --git a/commands/docs/polars_get-ordinal.md b/commands/docs/polars_get-ordinal.md index f0dfd4e2558..87ffb80b3d4 100644 --- a/commands/docs/polars_get-ordinal.md +++ b/commands/docs/polars_get-ordinal.md @@ -2,7 +2,7 @@ title: polars get-ordinal categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets ordinal from date. usage: | diff --git a/commands/docs/polars_get-second.md b/commands/docs/polars_get-second.md index bda24253955..22179a66bfa 100644 --- a/commands/docs/polars_get-second.md +++ b/commands/docs/polars_get-second.md @@ -2,7 +2,7 @@ title: polars get-second categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets second from date. usage: | diff --git a/commands/docs/polars_get-week.md b/commands/docs/polars_get-week.md index d107a933390..352f66f1ffd 100644 --- a/commands/docs/polars_get-week.md +++ b/commands/docs/polars_get-week.md @@ -2,7 +2,7 @@ title: polars get-week categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets week from date. usage: | diff --git a/commands/docs/polars_get-weekday.md b/commands/docs/polars_get-weekday.md index 96145a9b2d5..12e143cc054 100644 --- a/commands/docs/polars_get-weekday.md +++ b/commands/docs/polars_get-weekday.md @@ -2,7 +2,7 @@ title: polars get-weekday categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets weekday from date. usage: | diff --git a/commands/docs/polars_get-year.md b/commands/docs/polars_get-year.md index 9dd484001a6..921953ad956 100644 --- a/commands/docs/polars_get-year.md +++ b/commands/docs/polars_get-year.md @@ -2,7 +2,7 @@ title: polars get-year categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets year from date. usage: | diff --git a/commands/docs/polars_get.md b/commands/docs/polars_get.md index 69016657d18..155f0ccf87d 100644 --- a/commands/docs/polars_get.md +++ b/commands/docs/polars_get.md @@ -2,7 +2,7 @@ title: polars get categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates dataframe with the selected columns. usage: | diff --git a/commands/docs/polars_group-by.md b/commands/docs/polars_group-by.md index 645884aa6a9..b0adf8778f0 100644 --- a/commands/docs/polars_group-by.md +++ b/commands/docs/polars_group-by.md @@ -2,7 +2,7 @@ title: polars group-by categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Creates a group-by object that can be used for other aggregations. usage: | diff --git a/commands/docs/polars_horizontal.md b/commands/docs/polars_horizontal.md index 3be364746d0..30fac5f7d50 100644 --- a/commands/docs/polars_horizontal.md +++ b/commands/docs/polars_horizontal.md @@ -2,7 +2,7 @@ title: polars horizontal categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Horizontal calculation across multiple columns. usage: | diff --git a/commands/docs/polars_implode.md b/commands/docs/polars_implode.md index c22093cfd7e..07ab55d5bab 100644 --- a/commands/docs/polars_implode.md +++ b/commands/docs/polars_implode.md @@ -2,7 +2,7 @@ title: polars implode categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Aggregates values into a list. usage: | diff --git a/commands/docs/polars_integer.md b/commands/docs/polars_integer.md index 9f5bc85a17b..584f44d7ff8 100644 --- a/commands/docs/polars_integer.md +++ b/commands/docs/polars_integer.md @@ -2,7 +2,7 @@ title: polars integer categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Converts a string column into a integer column usage: | diff --git a/commands/docs/polars_into-df.md b/commands/docs/polars_into-df.md index 100dd8de908..edaf06294a5 100644 --- a/commands/docs/polars_into-df.md +++ b/commands/docs/polars_into-df.md @@ -2,7 +2,7 @@ title: polars into-df categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Converts a list, table or record into a dataframe. usage: | diff --git a/commands/docs/polars_into-dtype.md b/commands/docs/polars_into-dtype.md index 64051c8f31e..cfaa464aadf 100644 --- a/commands/docs/polars_into-dtype.md +++ b/commands/docs/polars_into-dtype.md @@ -2,7 +2,7 @@ title: polars into-dtype categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Convert a string to a specific datatype. usage: | diff --git a/commands/docs/polars_into-lazy.md b/commands/docs/polars_into-lazy.md index bdbed84bd29..9628c1077f0 100644 --- a/commands/docs/polars_into-lazy.md +++ b/commands/docs/polars_into-lazy.md @@ -2,7 +2,7 @@ title: polars into-lazy categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Converts a dataframe into a lazy dataframe. usage: | diff --git a/commands/docs/polars_into-nu.md b/commands/docs/polars_into-nu.md index 8beb510b23c..30cf606f72a 100644 --- a/commands/docs/polars_into-nu.md +++ b/commands/docs/polars_into-nu.md @@ -2,7 +2,7 @@ title: polars into-nu categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Converts a dataframe or an expression into nushell value for access and exploration. usage: | diff --git a/commands/docs/polars_into-repr.md b/commands/docs/polars_into-repr.md index 31e54152b65..d26c8fc3a04 100644 --- a/commands/docs/polars_into-repr.md +++ b/commands/docs/polars_into-repr.md @@ -2,7 +2,7 @@ title: polars into-repr categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Display a dataframe in its repr format. usage: | diff --git a/commands/docs/polars_into-schema.md b/commands/docs/polars_into-schema.md index 6396c4312be..5e6720a7ebb 100644 --- a/commands/docs/polars_into-schema.md +++ b/commands/docs/polars_into-schema.md @@ -2,7 +2,7 @@ title: polars into-schema categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Convert a value to a polars schema object usage: | diff --git a/commands/docs/polars_is-duplicated.md b/commands/docs/polars_is-duplicated.md index b79fd2d0dc6..9dd5660044e 100644 --- a/commands/docs/polars_is-duplicated.md +++ b/commands/docs/polars_is-duplicated.md @@ -2,7 +2,7 @@ title: polars is-duplicated categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates mask indicating duplicated values. usage: | diff --git a/commands/docs/polars_is-in.md b/commands/docs/polars_is-in.md index 799c0ee4999..92bff3d499e 100644 --- a/commands/docs/polars_is-in.md +++ b/commands/docs/polars_is-in.md @@ -2,7 +2,7 @@ title: polars is-in categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates an is-in expression or checks to see if the elements are contained in the right series usage: | diff --git a/commands/docs/polars_is-not-null.md b/commands/docs/polars_is-not-null.md index cc34e0d5b4a..96d41e09b85 100644 --- a/commands/docs/polars_is-not-null.md +++ b/commands/docs/polars_is-not-null.md @@ -2,7 +2,7 @@ title: polars is-not-null categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates mask where value is not null. usage: | diff --git a/commands/docs/polars_is-null.md b/commands/docs/polars_is-null.md index 120e2440938..369b0a89ad7 100644 --- a/commands/docs/polars_is-null.md +++ b/commands/docs/polars_is-null.md @@ -2,7 +2,7 @@ title: polars is-null categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates mask where value is null. usage: | diff --git a/commands/docs/polars_is-unique.md b/commands/docs/polars_is-unique.md index 22ee2d43f36..dc2606c2573 100644 --- a/commands/docs/polars_is-unique.md +++ b/commands/docs/polars_is-unique.md @@ -2,7 +2,7 @@ title: polars is-unique categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates mask indicating unique values. usage: | diff --git a/commands/docs/polars_join-where.md b/commands/docs/polars_join-where.md index 75549b05853..7e3a9d446a2 100644 --- a/commands/docs/polars_join-where.md +++ b/commands/docs/polars_join-where.md @@ -2,7 +2,7 @@ title: polars join-where categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Joins a lazy frame with other lazy frame based on conditions. usage: | diff --git a/commands/docs/polars_join.md b/commands/docs/polars_join.md index 4e81f5f8c61..f97ecebf3c5 100644 --- a/commands/docs/polars_join.md +++ b/commands/docs/polars_join.md @@ -2,7 +2,7 @@ title: polars join categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Joins a lazy frame with other lazy frame. usage: | diff --git a/commands/docs/polars_last.md b/commands/docs/polars_last.md index 9ca179e93ca..93e0476a9ae 100644 --- a/commands/docs/polars_last.md +++ b/commands/docs/polars_last.md @@ -2,7 +2,7 @@ title: polars last categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates new dataframe with tail rows or creates a last expression. usage: | diff --git a/commands/docs/polars_len.md b/commands/docs/polars_len.md index 424637c5eb7..36c605874a4 100644 --- a/commands/docs/polars_len.md +++ b/commands/docs/polars_len.md @@ -2,7 +2,7 @@ title: polars len categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Return the number of rows in the context. This is similar to COUNT(*) in SQL. usage: | diff --git a/commands/docs/polars_list-contains.md b/commands/docs/polars_list-contains.md index 3432b712cfb..4a22dd6f21b 100644 --- a/commands/docs/polars_list-contains.md +++ b/commands/docs/polars_list-contains.md @@ -2,7 +2,7 @@ title: polars list-contains categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Checks if an element is contained in a list. usage: | diff --git a/commands/docs/polars_lit.md b/commands/docs/polars_lit.md index db889165881..f12cbbdf438 100644 --- a/commands/docs/polars_lit.md +++ b/commands/docs/polars_lit.md @@ -2,7 +2,7 @@ title: polars lit categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates a literal expression. usage: | diff --git a/commands/docs/polars_lowercase.md b/commands/docs/polars_lowercase.md index 641eaf8c0af..759caaba192 100644 --- a/commands/docs/polars_lowercase.md +++ b/commands/docs/polars_lowercase.md @@ -2,7 +2,7 @@ title: polars lowercase categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Lowercase the strings in the column. usage: | diff --git a/commands/docs/polars_math.md b/commands/docs/polars_math.md index d52571fdd54..b1b19740148 100644 --- a/commands/docs/polars_math.md +++ b/commands/docs/polars_math.md @@ -2,7 +2,7 @@ title: polars math categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Collection of math functions to be applied on one or more column expressions usage: | diff --git a/commands/docs/polars_max.md b/commands/docs/polars_max.md index 7729473f96f..3dfd56afe47 100644 --- a/commands/docs/polars_max.md +++ b/commands/docs/polars_max.md @@ -2,7 +2,7 @@ title: polars max categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a max expression or aggregates columns to their max value. usage: | diff --git a/commands/docs/polars_mean.md b/commands/docs/polars_mean.md index 605464a95f4..cd4b05f2c7a 100644 --- a/commands/docs/polars_mean.md +++ b/commands/docs/polars_mean.md @@ -2,7 +2,7 @@ title: polars mean categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a mean expression for an aggregation or aggregates columns to their mean value. usage: | diff --git a/commands/docs/polars_median.md b/commands/docs/polars_median.md index 461fd344612..3e8913aa3e2 100644 --- a/commands/docs/polars_median.md +++ b/commands/docs/polars_median.md @@ -2,7 +2,7 @@ title: polars median categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Median value from columns in a dataframe or creates expression for an aggregation usage: | diff --git a/commands/docs/polars_min.md b/commands/docs/polars_min.md index 634e30dac1e..95e252e974f 100644 --- a/commands/docs/polars_min.md +++ b/commands/docs/polars_min.md @@ -2,7 +2,7 @@ title: polars min categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a min expression or aggregates columns to their min value. usage: | diff --git a/commands/docs/polars_n-unique.md b/commands/docs/polars_n-unique.md index 91e42fcc1f9..48b25799497 100644 --- a/commands/docs/polars_n-unique.md +++ b/commands/docs/polars_n-unique.md @@ -2,7 +2,7 @@ title: polars n-unique categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Counts unique values. usage: | diff --git a/commands/docs/polars_not.md b/commands/docs/polars_not.md index e58b56c95d2..19652bd8d5f 100644 --- a/commands/docs/polars_not.md +++ b/commands/docs/polars_not.md @@ -2,7 +2,7 @@ title: polars not categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Inverts boolean mask. usage: | diff --git a/commands/docs/polars_open.md b/commands/docs/polars_open.md index 5d176a5e6f7..e7f58f54e82 100644 --- a/commands/docs/polars_open.md +++ b/commands/docs/polars_open.md @@ -2,7 +2,7 @@ title: polars open categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Opens CSV, JSON, NDJSON/JSON lines, arrow, avro, or parquet file to create dataframe. A lazy dataframe will be created by default, if supported. usage: | diff --git a/commands/docs/polars_otherwise.md b/commands/docs/polars_otherwise.md index c5da0a22e4c..03baffc2f50 100644 --- a/commands/docs/polars_otherwise.md +++ b/commands/docs/polars_otherwise.md @@ -2,7 +2,7 @@ title: polars otherwise categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Completes a when expression. usage: | diff --git a/commands/docs/polars_over.md b/commands/docs/polars_over.md index b13150e6342..8d7919e2566 100644 --- a/commands/docs/polars_over.md +++ b/commands/docs/polars_over.md @@ -2,7 +2,7 @@ title: polars over categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Compute expressions over a window group defined by partition expressions. usage: | diff --git a/commands/docs/polars_pivot.md b/commands/docs/polars_pivot.md index 1a12dd169b8..4aeebfc5881 100644 --- a/commands/docs/polars_pivot.md +++ b/commands/docs/polars_pivot.md @@ -2,7 +2,7 @@ title: polars pivot categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Pivot a DataFrame from long to wide format. usage: | @@ -51,8 +51,8 @@ Perform a pivot in order to show individuals test score by subject ╭───┬───────┬──────────────┬───────┬─────────╮ │ # │ name │ date │ maths │ physics │ ├───┼───────┼──────────────┼───────┼─────────┤ -│ 0 │ Cady │ 3 months ago │ 98 │ 99 │ -│ 1 │ Karen │ 3 months ago │ 61 │ 58 │ +│ 0 │ Cady │ 5 months ago │ 98 │ 99 │ +│ 1 │ Karen │ 5 months ago │ 61 │ 58 │ ╰───┴───────┴──────────────┴───────┴─────────╯ ``` diff --git a/commands/docs/polars_profile.md b/commands/docs/polars_profile.md index 62579863f31..2ce5eda007c 100644 --- a/commands/docs/polars_profile.md +++ b/commands/docs/polars_profile.md @@ -2,7 +2,7 @@ title: polars profile categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Profile a lazy dataframe. usage: | diff --git a/commands/docs/polars_qcut.md b/commands/docs/polars_qcut.md index 59500ee0a6b..b561b5ce735 100644 --- a/commands/docs/polars_qcut.md +++ b/commands/docs/polars_qcut.md @@ -2,7 +2,7 @@ title: polars qcut categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Bin continuous values into discrete categories based on their quantiles for a series. usage: | diff --git a/commands/docs/polars_quantile.md b/commands/docs/polars_quantile.md index 5ae70b4889c..aeaea14f153 100644 --- a/commands/docs/polars_quantile.md +++ b/commands/docs/polars_quantile.md @@ -2,7 +2,7 @@ title: polars quantile categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Aggregates the columns to the selected quantile. usage: | diff --git a/commands/docs/polars_query.md b/commands/docs/polars_query.md index 973385c81b4..ecf180b0f7f 100644 --- a/commands/docs/polars_query.md +++ b/commands/docs/polars_query.md @@ -2,7 +2,7 @@ title: polars query categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Query dataframe using SQL. Note: The dataframe is always named 'df' in your query's from clause. usage: | diff --git a/commands/docs/polars_rename.md b/commands/docs/polars_rename.md index c80e09a8cdb..04dc3861712 100644 --- a/commands/docs/polars_rename.md +++ b/commands/docs/polars_rename.md @@ -2,7 +2,7 @@ title: polars rename categories: | dataframe or lazyframe -version: 0.106.0 +version: 0.107.0 dataframe_or_lazyframe: | Rename a dataframe column. usage: | diff --git a/commands/docs/polars_replace-time-zone.md b/commands/docs/polars_replace-time-zone.md index 7c1db573222..7becbdded10 100644 --- a/commands/docs/polars_replace-time-zone.md +++ b/commands/docs/polars_replace-time-zone.md @@ -2,7 +2,7 @@ title: polars replace-time-zone categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Replace the timezone information in a datetime column. usage: | @@ -71,10 +71,10 @@ Apply timezone with ambiguous datetime ╭───┬─────────────╮ │ # │ datetime │ ├───┼─────────────┤ -│ 0 │ in 3 months │ +│ 0 │ in 2 months │ │ 1 │ │ -│ 2 │ in 3 months │ -│ 3 │ in 3 months │ +│ 2 │ in 2 months │ +│ 3 │ in 2 months │ ╰───┴─────────────╯ ``` @@ -88,10 +88,10 @@ Apply timezone with nonexistent datetime ╭───┬──────────────╮ │ # │ datetime │ ├───┼──────────────┤ -│ 0 │ 4 months ago │ +│ 0 │ 5 months ago │ │ 1 │ │ -│ 2 │ 4 months ago │ -│ 3 │ 4 months ago │ +│ 2 │ 5 months ago │ +│ 3 │ 5 months ago │ ╰───┴──────────────╯ ``` diff --git a/commands/docs/polars_replace.md b/commands/docs/polars_replace.md index 5515e8adb2c..07bb9f0b688 100644 --- a/commands/docs/polars_replace.md +++ b/commands/docs/polars_replace.md @@ -2,7 +2,7 @@ title: polars replace categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Create an expression that replaces old values with new values usage: | diff --git a/commands/docs/polars_reverse.md b/commands/docs/polars_reverse.md index 342c5434bd1..6d61eec953b 100644 --- a/commands/docs/polars_reverse.md +++ b/commands/docs/polars_reverse.md @@ -2,7 +2,7 @@ title: polars reverse categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Reverses the LazyFrame usage: | diff --git a/commands/docs/polars_rolling.md b/commands/docs/polars_rolling.md index b96939f5be3..cee42766755 100644 --- a/commands/docs/polars_rolling.md +++ b/commands/docs/polars_rolling.md @@ -2,7 +2,7 @@ title: polars rolling categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Rolling calculation for a series. usage: | diff --git a/commands/docs/polars_sample.md b/commands/docs/polars_sample.md index 6368aa1db69..2cdf4aee7d3 100644 --- a/commands/docs/polars_sample.md +++ b/commands/docs/polars_sample.md @@ -2,7 +2,7 @@ title: polars sample categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Create sample dataframe. usage: | diff --git a/commands/docs/polars_save.md b/commands/docs/polars_save.md index 818ce81bd63..8573fdd9122 100644 --- a/commands/docs/polars_save.md +++ b/commands/docs/polars_save.md @@ -2,7 +2,7 @@ title: polars save categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Saves a dataframe to disk. For lazy dataframes a sink operation will be used if the file type supports it (parquet, ipc/arrow, csv, and ndjson). usage: | diff --git a/commands/docs/polars_schema.md b/commands/docs/polars_schema.md index 2dd8dda842f..6dcb16cf747 100644 --- a/commands/docs/polars_schema.md +++ b/commands/docs/polars_schema.md @@ -2,7 +2,7 @@ title: polars schema categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Show schema for a dataframe. usage: | diff --git a/commands/docs/polars_select.md b/commands/docs/polars_select.md index da5939cc2aa..d45f3ef4d50 100644 --- a/commands/docs/polars_select.md +++ b/commands/docs/polars_select.md @@ -2,7 +2,7 @@ title: polars select categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Selects columns from lazyframe. usage: | diff --git a/commands/docs/polars_set-with-idx.md b/commands/docs/polars_set-with-idx.md index bf29e0e8a6c..185f8bccb06 100644 --- a/commands/docs/polars_set-with-idx.md +++ b/commands/docs/polars_set-with-idx.md @@ -2,7 +2,7 @@ title: polars set-with-idx categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Sets value in the given index. usage: | diff --git a/commands/docs/polars_set.md b/commands/docs/polars_set.md index b70048af450..438924ba025 100644 --- a/commands/docs/polars_set.md +++ b/commands/docs/polars_set.md @@ -2,7 +2,7 @@ title: polars set categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Sets value where given mask is true. usage: | diff --git a/commands/docs/polars_shape.md b/commands/docs/polars_shape.md index ef3732e152f..9361d151382 100644 --- a/commands/docs/polars_shape.md +++ b/commands/docs/polars_shape.md @@ -2,7 +2,7 @@ title: polars shape categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Shows column and row size for a dataframe. usage: | diff --git a/commands/docs/polars_shift.md b/commands/docs/polars_shift.md index e2dc7cb7856..3c394ef4628 100644 --- a/commands/docs/polars_shift.md +++ b/commands/docs/polars_shift.md @@ -2,7 +2,7 @@ title: polars shift categories: | dataframe or lazyframe -version: 0.106.0 +version: 0.107.0 dataframe_or_lazyframe: | Shifts the values by a given period. usage: | diff --git a/commands/docs/polars_slice.md b/commands/docs/polars_slice.md index a27316df8df..0ea8de75af2 100644 --- a/commands/docs/polars_slice.md +++ b/commands/docs/polars_slice.md @@ -2,7 +2,7 @@ title: polars slice categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates new dataframe from a slice of rows. usage: | diff --git a/commands/docs/polars_sort-by.md b/commands/docs/polars_sort-by.md index 62de6df5a6f..49edf26efd4 100644 --- a/commands/docs/polars_sort-by.md +++ b/commands/docs/polars_sort-by.md @@ -2,7 +2,7 @@ title: polars sort-by categories: | lazyframe -version: 0.106.0 +version: 0.107.0 lazyframe: | Sorts a lazy dataframe based on expression(s). usage: | diff --git a/commands/docs/polars_std.md b/commands/docs/polars_std.md index f0a041d72bc..78a3c6da20a 100644 --- a/commands/docs/polars_std.md +++ b/commands/docs/polars_std.md @@ -2,7 +2,7 @@ title: polars std categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a std expression for an aggregation of std value from columns in a dataframe. usage: | diff --git a/commands/docs/polars_store-get.md b/commands/docs/polars_store-get.md index 9eea16288cf..affa1eb3053 100644 --- a/commands/docs/polars_store-get.md +++ b/commands/docs/polars_store-get.md @@ -2,7 +2,7 @@ title: polars store-get categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Gets a Dataframe or other object from the plugin cache. usage: | diff --git a/commands/docs/polars_store-ls.md b/commands/docs/polars_store-ls.md index 114152b0f5a..26a37339d6c 100644 --- a/commands/docs/polars_store-ls.md +++ b/commands/docs/polars_store-ls.md @@ -2,7 +2,7 @@ title: polars store-ls categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Lists stored polars objects. usage: | diff --git a/commands/docs/polars_store-rm.md b/commands/docs/polars_store-rm.md index 5d036a07726..abc18423c88 100644 --- a/commands/docs/polars_store-rm.md +++ b/commands/docs/polars_store-rm.md @@ -2,7 +2,7 @@ title: polars store-rm categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Removes a stored Dataframe or other object from the plugin cache. usage: | diff --git a/commands/docs/polars_str-join.md b/commands/docs/polars_str-join.md index c63a17035ed..8f99964d3e0 100644 --- a/commands/docs/polars_str-join.md +++ b/commands/docs/polars_str-join.md @@ -2,7 +2,7 @@ title: polars str-join categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Concatenates strings within a column or dataframes usage: | diff --git a/commands/docs/polars_str-lengths.md b/commands/docs/polars_str-lengths.md index 1d0fb55bd25..9f08e1f1c31 100644 --- a/commands/docs/polars_str-lengths.md +++ b/commands/docs/polars_str-lengths.md @@ -2,7 +2,7 @@ title: polars str-lengths categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Get lengths of all strings. usage: | diff --git a/commands/docs/polars_str-replace-all.md b/commands/docs/polars_str-replace-all.md index cc94e7995ad..600ddbbc577 100644 --- a/commands/docs/polars_str-replace-all.md +++ b/commands/docs/polars_str-replace-all.md @@ -2,7 +2,7 @@ title: polars str-replace-all categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Replace all (sub)strings by a regex pattern. usage: | diff --git a/commands/docs/polars_str-replace.md b/commands/docs/polars_str-replace.md index 96e3e2f16c3..bff0b3df2e7 100644 --- a/commands/docs/polars_str-replace.md +++ b/commands/docs/polars_str-replace.md @@ -2,7 +2,7 @@ title: polars str-replace categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Replace the leftmost (sub)string by a regex pattern. usage: | diff --git a/commands/docs/polars_str-slice.md b/commands/docs/polars_str-slice.md index 616f839e401..ffd319c2507 100644 --- a/commands/docs/polars_str-slice.md +++ b/commands/docs/polars_str-slice.md @@ -2,7 +2,7 @@ title: polars str-slice categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Slices the string from the start position until the selected length. usage: | diff --git a/commands/docs/polars_str-split.md b/commands/docs/polars_str-split.md index d93443451bf..fbbd22f14c1 100644 --- a/commands/docs/polars_str-split.md +++ b/commands/docs/polars_str-split.md @@ -2,7 +2,7 @@ title: polars str-split categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Split the string by a substring. The resulting dtype is list. usage: | diff --git a/commands/docs/polars_str-strip-chars.md b/commands/docs/polars_str-strip-chars.md index 7de92147156..436fa5569a7 100644 --- a/commands/docs/polars_str-strip-chars.md +++ b/commands/docs/polars_str-strip-chars.md @@ -2,7 +2,7 @@ title: polars str-strip-chars categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Strips specified characters from strings in a column usage: | diff --git a/commands/docs/polars_strftime.md b/commands/docs/polars_strftime.md index 698903099dd..da0477a62f2 100644 --- a/commands/docs/polars_strftime.md +++ b/commands/docs/polars_strftime.md @@ -2,7 +2,7 @@ title: polars strftime categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Formats date based on string rule. usage: | diff --git a/commands/docs/polars_struct-json-encode.md b/commands/docs/polars_struct-json-encode.md index 25fcf6780be..7ba82d7e5e1 100644 --- a/commands/docs/polars_struct-json-encode.md +++ b/commands/docs/polars_struct-json-encode.md @@ -2,7 +2,7 @@ title: polars struct-json-encode categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Convert this struct to a string column with json values. usage: | diff --git a/commands/docs/polars_sum.md b/commands/docs/polars_sum.md index 7a979cf8953..606f015260c 100644 --- a/commands/docs/polars_sum.md +++ b/commands/docs/polars_sum.md @@ -2,7 +2,7 @@ title: polars sum categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates a sum expression for an aggregation or aggregates columns to their sum value. usage: | diff --git a/commands/docs/polars_summary.md b/commands/docs/polars_summary.md index ff9f8ec4aef..8709d2158d1 100644 --- a/commands/docs/polars_summary.md +++ b/commands/docs/polars_summary.md @@ -2,7 +2,7 @@ title: polars summary categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | For a dataframe, produces descriptive statistics (summary statistics) for its numeric columns. usage: | diff --git a/commands/docs/polars_take.md b/commands/docs/polars_take.md index df62c6378cb..e03239e8406 100644 --- a/commands/docs/polars_take.md +++ b/commands/docs/polars_take.md @@ -2,7 +2,7 @@ title: polars take categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Creates new dataframe using the given indices. usage: | diff --git a/commands/docs/polars_truncate.md b/commands/docs/polars_truncate.md index 93aacf2448c..5b25d0a957e 100644 --- a/commands/docs/polars_truncate.md +++ b/commands/docs/polars_truncate.md @@ -2,7 +2,7 @@ title: polars truncate categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Divide the date/datetime range into buckets. usage: | @@ -45,10 +45,10 @@ Truncate a series of dates by period length ╭───┬──────────────┬──────────────╮ │ # │ datetime │ truncated │ ├───┼──────────────┼──────────────┤ -│ 0 │ 6 months ago │ 6 months ago │ -│ 1 │ 5 months ago │ 5 months ago │ -│ 2 │ 3 months ago │ 4 months ago │ -│ 3 │ 2 months ago │ 2 months ago │ +│ 0 │ 8 months ago │ 8 months ago │ +│ 1 │ 6 months ago │ 6 months ago │ +│ 2 │ 5 months ago │ 5 months ago │ +│ 3 │ 3 months ago │ 4 months ago │ ╰───┴──────────────┴──────────────╯ ``` diff --git a/commands/docs/polars_unique.md b/commands/docs/polars_unique.md index 15289099921..e144d7f5861 100644 --- a/commands/docs/polars_unique.md +++ b/commands/docs/polars_unique.md @@ -2,7 +2,7 @@ title: polars unique categories: | dataframe or lazyframe -version: 0.106.0 +version: 0.107.0 dataframe_or_lazyframe: | Returns unique values from a dataframe. usage: | diff --git a/commands/docs/polars_unnest.md b/commands/docs/polars_unnest.md index 569959fb32e..f8a7691657d 100644 --- a/commands/docs/polars_unnest.md +++ b/commands/docs/polars_unnest.md @@ -2,7 +2,7 @@ title: polars unnest categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Decompose struct columns into separate columns for each of their fields. The new columns will be inserted into the dataframe at the location of the struct column. usage: | diff --git a/commands/docs/polars_unpivot.md b/commands/docs/polars_unpivot.md index 9951c8b6074..dd11cc16ff5 100644 --- a/commands/docs/polars_unpivot.md +++ b/commands/docs/polars_unpivot.md @@ -2,7 +2,7 @@ title: polars unpivot categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Unpivot a DataFrame from wide to long format. usage: | diff --git a/commands/docs/polars_uppercase.md b/commands/docs/polars_uppercase.md index e018aed23f2..8a3d2dbdbe6 100644 --- a/commands/docs/polars_uppercase.md +++ b/commands/docs/polars_uppercase.md @@ -2,7 +2,7 @@ title: polars uppercase categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Uppercase the strings in the column. usage: | diff --git a/commands/docs/polars_value-counts.md b/commands/docs/polars_value-counts.md index bc8984743b4..662f0402d82 100644 --- a/commands/docs/polars_value-counts.md +++ b/commands/docs/polars_value-counts.md @@ -2,7 +2,7 @@ title: polars value-counts categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Returns a dataframe with the counts for unique values in series. usage: | diff --git a/commands/docs/polars_var.md b/commands/docs/polars_var.md index a42187dbd59..2f4709b7f85 100644 --- a/commands/docs/polars_var.md +++ b/commands/docs/polars_var.md @@ -2,7 +2,7 @@ title: polars var categories: | dataframe -version: 0.106.0 +version: 0.107.0 dataframe: | Create a var expression for an aggregation. usage: | diff --git a/commands/docs/polars_when.md b/commands/docs/polars_when.md index fc81ac0dc49..f81f50a166c 100644 --- a/commands/docs/polars_when.md +++ b/commands/docs/polars_when.md @@ -2,7 +2,7 @@ title: polars when categories: | expression -version: 0.106.0 +version: 0.107.0 expression: | Creates and modifies a when expression. usage: | diff --git a/commands/docs/polars_with-column.md b/commands/docs/polars_with-column.md index f1610215e0a..85d6249cd45 100644 --- a/commands/docs/polars_with-column.md +++ b/commands/docs/polars_with-column.md @@ -2,7 +2,7 @@ title: polars with-column categories: | dataframe or lazyframe -version: 0.106.0 +version: 0.107.0 dataframe_or_lazyframe: | Adds a series to the dataframe. usage: | diff --git a/commands/docs/port.md b/commands/docs/port.md index 430ff00c8e9..23c926b8b47 100644 --- a/commands/docs/port.md +++ b/commands/docs/port.md @@ -2,7 +2,7 @@ title: port categories: | network -version: 0.106.0 +version: 0.107.0 network: | Get a free port from system. usage: | diff --git a/commands/docs/prepend.md b/commands/docs/prepend.md index 192fd429bdf..64307b1237e 100644 --- a/commands/docs/prepend.md +++ b/commands/docs/prepend.md @@ -2,7 +2,7 @@ title: prepend categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Prepend any number of rows to a table. usage: | diff --git a/commands/docs/print.md b/commands/docs/print.md index b16e4616c9d..2273c3969e2 100644 --- a/commands/docs/print.md +++ b/commands/docs/print.md @@ -2,7 +2,7 @@ title: print categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Print the given values to stdout. usage: | diff --git a/commands/docs/ps.md b/commands/docs/ps.md index 0eb07dd2802..4e63c98e80e 100644 --- a/commands/docs/ps.md +++ b/commands/docs/ps.md @@ -2,7 +2,7 @@ title: ps categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about system processes. usage: | diff --git a/commands/docs/pwd.md b/commands/docs/pwd.md index 42a059f71ae..c35a3831c0b 100644 --- a/commands/docs/pwd.md +++ b/commands/docs/pwd.md @@ -2,7 +2,7 @@ title: pwd categories: | default -version: 0.106.0 +version: 0.107.0 default: | Return the current working directory usage: | diff --git a/commands/docs/query.md b/commands/docs/query.md index d2e64613bca..19cc58c1c33 100644 --- a/commands/docs/query.md +++ b/commands/docs/query.md @@ -2,7 +2,7 @@ title: query categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Show all the query commands usage: | @@ -36,4 +36,4 @@ See the [Plugins](/book/plugins.html) chapter in the book for more information. | [`query json`](/commands/docs/query_json.md) | execute json query on json file (open --raw \ | query json 'query string') | plugin | | [`query web`](/commands/docs/query_web.md) | execute selector query on html/web | plugin | | [`query webpage-info`](/commands/docs/query_webpage-info.md) | uses the webpage crate to extract info from html: title, description, language, links, RSS feeds, Opengraph, Schema.org, and more | plugin | -| [`query xml`](/commands/docs/query_xml.md) | execute xpath query on xml | plugin | \ No newline at end of file +| [`query xml`](/commands/docs/query_xml.md) | Execute XPath 1.0 query on XML input | plugin | \ No newline at end of file diff --git a/commands/docs/query_db.md b/commands/docs/query_db.md index 661c97f4b40..68b357cefc9 100644 --- a/commands/docs/query_db.md +++ b/commands/docs/query_db.md @@ -2,7 +2,7 @@ title: query db categories: | database -version: 0.106.0 +version: 0.107.0 database: | Query a database using SQL. usage: | @@ -45,7 +45,7 @@ Execute SQL against a SQLite database Execute a SQL statement with parameters ```nu > stor create -t my_table -c { first: str, second: int } -stor open | query db "INSERT INTO my_table VALUES (?, ?)" -p [hello 123] + stor open | query db "INSERT INTO my_table VALUES (?, ?)" -p [hello 123] ``` @@ -61,3 +61,38 @@ stor open | query db "SELECT * FROM my_table WHERE second = :search_second" -p { ╰───┴───────┴────────╯ ``` + +Execute a SQL query, selecting a declared JSON(B) column that will automatically be parsed +```nu +> stor create -t my_table -c {data: jsonb} +[{data: {name: Albert, age: 40}} {data: {name: Barnaby, age: 54}}] | stor insert -t my_table +stor open | query db "SELECT data FROM my_table WHERE data->>'age' < 45" +╭───┬───────────────────╮ +│ # │ data │ +├───┼───────────────────┤ +│ 0 │ ╭──────┬────────╮ │ +│ │ │ name │ Albert │ │ +│ │ │ age │ 40 │ │ +│ │ ╰──────┴────────╯ │ +╰───┴───────────────────╯ + +``` + +Execute a SQL query selecting a sub-field of a JSON(B) column. +In this case, results must be parsed afterwards because SQLite does not +return declaration types when a JSON(B) column is not directly selected +```nu +> stor create -t my_table -c {data: jsonb} +stor insert -t my_table -d {data: {foo: foo, bar: 12, baz: [0 1 2]}} +stor open | query db "SELECT data->'baz' AS baz FROM my_table" | update baz {from json} +╭───┬───────────╮ +│ # │ baz │ +├───┼───────────┤ +│ 0 │ ╭───┬───╮ │ +│ │ │ 0 │ 0 │ │ +│ │ │ 1 │ 1 │ │ +│ │ │ 2 │ 2 │ │ +│ │ ╰───┴───╯ │ +╰───┴───────────╯ + +``` diff --git a/commands/docs/query_json.md b/commands/docs/query_json.md index 20837bab83a..1d85be3d366 100644 --- a/commands/docs/query_json.md +++ b/commands/docs/query_json.md @@ -2,7 +2,7 @@ title: query json categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | execute json query on json file (open --raw | query json 'query string') usage: | diff --git a/commands/docs/query_web.md b/commands/docs/query_web.md index 0e4a93ec8cd..fa5cb8f79a5 100644 --- a/commands/docs/query_web.md +++ b/commands/docs/query_web.md @@ -2,7 +2,7 @@ title: query web categories: | network -version: 0.106.0 +version: 0.107.0 network: | execute selector query on html/web usage: | diff --git a/commands/docs/query_webpage-info.md b/commands/docs/query_webpage-info.md index 861d2fd12c1..35fd912032e 100644 --- a/commands/docs/query_webpage-info.md +++ b/commands/docs/query_webpage-info.md @@ -2,7 +2,7 @@ title: query webpage-info categories: | network -version: 0.106.0 +version: 0.107.0 network: | uses the webpage crate to extract info from html: title, description, language, links, RSS feeds, Opengraph, Schema.org, and more usage: | diff --git a/commands/docs/query_xml.md b/commands/docs/query_xml.md index 2450dafaa16..d4dda4e9e5f 100644 --- a/commands/docs/query_xml.md +++ b/commands/docs/query_xml.md @@ -2,11 +2,11 @@ title: query xml categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | - execute xpath query on xml + Execute XPath 1.0 query on XML input usage: | - execute xpath query on xml + Execute XPath 1.0 query on XML input editLink: false contributors: false --- @@ -14,7 +14,7 @@ contributors: false # `query xml` for [filters](/commands/categories/filters.md) -
execute xpath query on xml
+
Execute XPath 1.0 query on XML input
::: warning This command requires a plugin The `query xml` command resides in the `query` plugin. @@ -30,7 +30,56 @@ See the [Plugins](/book/plugins.html) chapter in the book for more information. ## Flags - `--namespaces, -n {record}`: map of prefixes to namespace URIs + - `--output-string-value`: Include `string_value` in the nodeset output. On by default. + - `--output-type`: Include `type` in the nodeset output. Off by default. + - `--output-names`: Include `local_name`, `prefixed_name`, and `namespace` in the nodeset output. Off by default. ## Parameters - `query`: xpath query + + +## Input/output types: + +| input | output | +| ------ | ------ | +| string | any | +## Examples + +Query namespaces on the root element of an SVG file +```nu +> http get --raw https://www.w3.org/TR/SVG/images/conform/smiley.svg + | query xml '/svg:svg/namespace::*' --output-string-value --output-names --output-type --namespaces {svg: "http://www.w3.org/2000/svg"} + +``` + +Query the language of Nushell blog (`xml:` prefix is always available) +```nu +> http get --raw https://www.nushell.sh/atom.xml + | query xml 'string(/*/@xml:lang)' + +``` + +Query all XLink targets in SVG document +```nu +> http get --raw https://www.w3.org/TR/SVG/images/conform/smiley.svg + | query xml '//*/@xlink:href' --namespaces {xlink: "http://www.w3.org/1999/xlink"} + +``` + +Get recent Nushell news +```nu +> http get --raw https://www.nushell.sh/atom.xml + | query xml '//atom:entry/atom:title|//atom:entry/atom:link/@href' --namespaces {atom: "http://www.w3.org/2005/Atom"} + | window 2 --stride 2 + | each { {title: $in.0.string_value, link: $in.1.string_value} } + +``` + +## Notes +Scalar results (Number, String, Boolean) are returned as nu scalars. +Output of the nodeset results depends on the flags used: + - No flags: returns a table with `string_value` column. + - You have to specify `--output-string-value` to include `string_value` in the output when using any other `--output-*` flags. + - `--output-type` includes `type` column with node type. + - `--output-names` includes `local_name`, `prefixed_name`, and `namespace` columns. diff --git a/commands/docs/random.md b/commands/docs/random.md index dbc0f6f65a2..4ab0c94a6af 100644 --- a/commands/docs/random.md +++ b/commands/docs/random.md @@ -2,7 +2,7 @@ title: random categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate a random value. usage: | diff --git a/commands/docs/random_binary.md b/commands/docs/random_binary.md index f02a97315c6..170c08bafc7 100644 --- a/commands/docs/random_binary.md +++ b/commands/docs/random_binary.md @@ -2,7 +2,7 @@ title: random binary categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate random bytes. usage: | diff --git a/commands/docs/random_bool.md b/commands/docs/random_bool.md index 7d89855b6e6..a94983b45c7 100644 --- a/commands/docs/random_bool.md +++ b/commands/docs/random_bool.md @@ -2,7 +2,7 @@ title: random bool categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate a random boolean value. usage: | diff --git a/commands/docs/random_chars.md b/commands/docs/random_chars.md index 13949e9ca40..1deb813743f 100644 --- a/commands/docs/random_chars.md +++ b/commands/docs/random_chars.md @@ -2,7 +2,7 @@ title: random chars categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate random chars uniformly distributed over ASCII letters and numbers: a-z, A-Z and 0-9. usage: | diff --git a/commands/docs/random_dice.md b/commands/docs/random_dice.md index 61cca0035eb..b24a630956d 100644 --- a/commands/docs/random_dice.md +++ b/commands/docs/random_dice.md @@ -2,7 +2,7 @@ title: random dice categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate a random dice roll. usage: | diff --git a/commands/docs/random_float.md b/commands/docs/random_float.md index a3840b7a738..124310e5f42 100644 --- a/commands/docs/random_float.md +++ b/commands/docs/random_float.md @@ -2,7 +2,7 @@ title: random float categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate a random float within a range [min..max]. usage: | diff --git a/commands/docs/random_int.md b/commands/docs/random_int.md index e81fd82e2ee..ef2adae43f0 100644 --- a/commands/docs/random_int.md +++ b/commands/docs/random_int.md @@ -2,7 +2,7 @@ title: random int categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate a random integer [min..max]. usage: | diff --git a/commands/docs/random_uuid.md b/commands/docs/random_uuid.md index bd6459e4857..a1853005bad 100644 --- a/commands/docs/random_uuid.md +++ b/commands/docs/random_uuid.md @@ -2,7 +2,7 @@ title: random uuid categories: | random -version: 0.106.0 +version: 0.107.0 random: | Generate a random uuid string of the specified version. usage: | diff --git a/commands/docs/reduce.md b/commands/docs/reduce.md index 31e4acfe7b2..3396feae854 100644 --- a/commands/docs/reduce.md +++ b/commands/docs/reduce.md @@ -2,7 +2,7 @@ title: reduce categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Aggregate a list (starting from the left) to a single value using an accumulator closure. usage: | diff --git a/commands/docs/registry_query.md b/commands/docs/registry_query.md index 0245abec1c1..1bd7a212658 100644 --- a/commands/docs/registry_query.md +++ b/commands/docs/registry_query.md @@ -2,7 +2,7 @@ title: registry query categories: | system -version: 0.106.0 +version: 0.107.0 system: | Query the Windows registry. usage: | @@ -60,4 +60,4 @@ Query the HKEY_LOCAL_MACHINE hive ``` ## Notes -Currently supported only on Windows systems. \ No newline at end of file +Currently supported only on Windows systems. diff --git a/commands/docs/reject.md b/commands/docs/reject.md index 7557ab40b73..4168e8a54a7 100644 --- a/commands/docs/reject.md +++ b/commands/docs/reject.md @@ -2,7 +2,7 @@ title: reject categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Remove the given columns or rows from the table. Opposite of `select`. usage: | @@ -23,6 +23,7 @@ contributors: false ## Flags - `--optional, -o`: make all cell path members optional + - `--ignore-case`: make all cell path members case insensitive - `--ignore-errors, -i`: ignore missing data (make all cell path members optional) (deprecated) ## Parameters diff --git a/commands/docs/rename.md b/commands/docs/rename.md index 76d38dad99c..6a094de6113 100644 --- a/commands/docs/rename.md +++ b/commands/docs/rename.md @@ -2,7 +2,7 @@ title: rename categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Creates a new table with columns renamed. usage: | diff --git a/commands/docs/return.md b/commands/docs/return.md index eb7b17c1295..749732a4499 100644 --- a/commands/docs/return.md +++ b/commands/docs/return.md @@ -2,7 +2,7 @@ title: return categories: | core -version: 0.106.0 +version: 0.107.0 core: | Return early from a custom command. usage: | diff --git a/commands/docs/reverse.md b/commands/docs/reverse.md index 84964294362..27a70cb1d2b 100644 --- a/commands/docs/reverse.md +++ b/commands/docs/reverse.md @@ -2,7 +2,7 @@ title: reverse categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Reverses the input list or table. usage: | diff --git a/commands/docs/rm.md b/commands/docs/rm.md index 8fafdd16c7d..cffa6a330c9 100644 --- a/commands/docs/rm.md +++ b/commands/docs/rm.md @@ -2,7 +2,7 @@ title: rm categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Remove files and directories. usage: | diff --git a/commands/docs/roll.md b/commands/docs/roll.md index 4d7860d2411..13dd6c1473a 100644 --- a/commands/docs/roll.md +++ b/commands/docs/roll.md @@ -2,7 +2,7 @@ title: roll categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Rolling commands for tables. usage: | diff --git a/commands/docs/roll_down.md b/commands/docs/roll_down.md index 21a997bbe71..4152dfc7b1d 100644 --- a/commands/docs/roll_down.md +++ b/commands/docs/roll_down.md @@ -2,7 +2,7 @@ title: roll down categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Roll table rows down. usage: | diff --git a/commands/docs/roll_left.md b/commands/docs/roll_left.md index af82a63f757..7289b8806a7 100644 --- a/commands/docs/roll_left.md +++ b/commands/docs/roll_left.md @@ -2,7 +2,7 @@ title: roll left categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Roll record or table columns left. usage: | diff --git a/commands/docs/roll_right.md b/commands/docs/roll_right.md index 374851a9736..49c0b560ac9 100644 --- a/commands/docs/roll_right.md +++ b/commands/docs/roll_right.md @@ -2,7 +2,7 @@ title: roll right categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Roll table columns right. usage: | diff --git a/commands/docs/roll_up.md b/commands/docs/roll_up.md index c52dac61c21..a06a0f2cb9e 100644 --- a/commands/docs/roll_up.md +++ b/commands/docs/roll_up.md @@ -2,7 +2,7 @@ title: roll up categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Roll table rows up. usage: | diff --git a/commands/docs/rotate.md b/commands/docs/rotate.md index 42e209644f6..08f912d4cd4 100644 --- a/commands/docs/rotate.md +++ b/commands/docs/rotate.md @@ -2,7 +2,7 @@ title: rotate categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Rotates a table or record clockwise (default) or counter-clockwise (use --ccw flag). usage: | diff --git a/commands/docs/run-external.md b/commands/docs/run-external.md index 159ae6ebd04..281abb287ac 100644 --- a/commands/docs/run-external.md +++ b/commands/docs/run-external.md @@ -2,7 +2,7 @@ title: run-external categories: | system -version: 0.106.0 +version: 0.107.0 system: | Runs external command. usage: | @@ -49,3 +49,7 @@ Redirect stderr from an external command into the pipeline > run-external "nu" "-c" "print -e hello" e>| split chars ``` + +## Notes +All externals are run with this command, whether you call it directly with `run-external external` or use `external` or `^external`. +If you create a custom command with this name, that will be used instead. \ No newline at end of file diff --git a/commands/docs/save.md b/commands/docs/save.md index b2d60948665..3dbea452b29 100644 --- a/commands/docs/save.md +++ b/commands/docs/save.md @@ -2,7 +2,7 @@ title: save categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Save a file. usage: | diff --git a/commands/docs/schema.md b/commands/docs/schema.md index c2512f63640..a419f1dd9cb 100644 --- a/commands/docs/schema.md +++ b/commands/docs/schema.md @@ -2,7 +2,7 @@ title: schema categories: | database -version: 0.106.0 +version: 0.107.0 database: | Show the schema of a SQLite database. usage: | diff --git a/commands/docs/scope.md b/commands/docs/scope.md index 0f240f9cf47..4f00aaff902 100644 --- a/commands/docs/scope.md +++ b/commands/docs/scope.md @@ -2,7 +2,7 @@ title: scope categories: | core -version: 0.106.0 +version: 0.107.0 core: | Commands for getting info about what is in scope. usage: | diff --git a/commands/docs/scope_aliases.md b/commands/docs/scope_aliases.md index 2f103071552..2fa28b4f02d 100644 --- a/commands/docs/scope_aliases.md +++ b/commands/docs/scope_aliases.md @@ -2,7 +2,7 @@ title: scope aliases categories: | core -version: 0.106.0 +version: 0.107.0 core: | Output info on the aliases in the current scope. usage: | diff --git a/commands/docs/scope_commands.md b/commands/docs/scope_commands.md index cb58c04c872..a282215945a 100644 --- a/commands/docs/scope_commands.md +++ b/commands/docs/scope_commands.md @@ -2,7 +2,7 @@ title: scope commands categories: | core -version: 0.106.0 +version: 0.107.0 core: | Output info on the commands in the current scope. usage: | diff --git a/commands/docs/scope_engine-stats.md b/commands/docs/scope_engine-stats.md index d911d1c03be..985b438d9df 100644 --- a/commands/docs/scope_engine-stats.md +++ b/commands/docs/scope_engine-stats.md @@ -2,7 +2,7 @@ title: scope engine-stats categories: | core -version: 0.106.0 +version: 0.107.0 core: | Output stats on the engine in the current state. usage: | diff --git a/commands/docs/scope_externs.md b/commands/docs/scope_externs.md index 1d3eab0071c..6814d257492 100644 --- a/commands/docs/scope_externs.md +++ b/commands/docs/scope_externs.md @@ -2,7 +2,7 @@ title: scope externs categories: | core -version: 0.106.0 +version: 0.107.0 core: | Output info on the known externals in the current scope. usage: | diff --git a/commands/docs/scope_modules.md b/commands/docs/scope_modules.md index 54003bf499c..bd30e999d73 100644 --- a/commands/docs/scope_modules.md +++ b/commands/docs/scope_modules.md @@ -2,7 +2,7 @@ title: scope modules categories: | core -version: 0.106.0 +version: 0.107.0 core: | Output info on the modules in the current scope. usage: | diff --git a/commands/docs/scope_variables.md b/commands/docs/scope_variables.md index 17401880ae0..282555d2089 100644 --- a/commands/docs/scope_variables.md +++ b/commands/docs/scope_variables.md @@ -2,7 +2,7 @@ title: scope variables categories: | core -version: 0.106.0 +version: 0.107.0 core: | Output info on the variables in the current scope. usage: | diff --git a/commands/docs/select.md b/commands/docs/select.md index 7d406fd6477..a23df4dae5d 100644 --- a/commands/docs/select.md +++ b/commands/docs/select.md @@ -2,7 +2,7 @@ title: select categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Select only these columns or rows from the input. Opposite of `reject`. usage: | @@ -23,6 +23,7 @@ contributors: false ## Flags - `--optional, -o`: make all cell path members optional (returns `null` for missing values) + - `--ignore-case`: make all cell path members case insensitive - `--ignore-errors, -i`: ignore missing data (make all cell path members optional) (deprecated) ## Parameters @@ -50,6 +51,18 @@ Select a column in a table ``` +Select a column even if some rows are missing that column +```nu +> [{a: a0 b: b0} {b: b1}] | select -o a +╭───┬────╮ +│ # │ a │ +├───┼────┤ +│ 0 │ a0 │ +│ 1 │ │ +╰───┴────╯ + +``` + Select a field in a record ```nu > {a: a b: b} | select a diff --git a/commands/docs/seq.md b/commands/docs/seq.md index 960407aa929..e37eff5fc56 100644 --- a/commands/docs/seq.md +++ b/commands/docs/seq.md @@ -2,7 +2,7 @@ title: seq categories: | generators -version: 0.106.0 +version: 0.107.0 generators: | Output sequences of numbers. usage: | diff --git a/commands/docs/seq_char.md b/commands/docs/seq_char.md index d6f385abefe..6567a27ae9e 100644 --- a/commands/docs/seq_char.md +++ b/commands/docs/seq_char.md @@ -2,7 +2,7 @@ title: seq char categories: | generators -version: 0.106.0 +version: 0.107.0 generators: | Print a sequence of ASCII characters. usage: | diff --git a/commands/docs/seq_date.md b/commands/docs/seq_date.md index c00828a479d..491dfe2ce3c 100644 --- a/commands/docs/seq_date.md +++ b/commands/docs/seq_date.md @@ -2,7 +2,7 @@ title: seq date categories: | generators -version: 0.106.0 +version: 0.107.0 generators: | Print sequences of dates. usage: | diff --git a/commands/docs/shuffle.md b/commands/docs/shuffle.md index 0daa7c5075e..cfee8b84e3d 100644 --- a/commands/docs/shuffle.md +++ b/commands/docs/shuffle.md @@ -2,7 +2,7 @@ title: shuffle categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Shuffle rows randomly. usage: | diff --git a/commands/docs/skip.md b/commands/docs/skip.md index 7db2209d86b..fa5a0bcdc29 100644 --- a/commands/docs/skip.md +++ b/commands/docs/skip.md @@ -2,7 +2,7 @@ title: skip categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Skip the first several rows of the input. Counterpart of `drop`. Opposite of `first`. usage: | diff --git a/commands/docs/skip_until.md b/commands/docs/skip_until.md index 9729c4b55f8..a4b771bb8e3 100644 --- a/commands/docs/skip_until.md +++ b/commands/docs/skip_until.md @@ -2,7 +2,7 @@ title: skip until categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Skip elements of the input until a predicate is true. usage: | diff --git a/commands/docs/skip_while.md b/commands/docs/skip_while.md index 52d70104f7f..719676632f7 100644 --- a/commands/docs/skip_while.md +++ b/commands/docs/skip_while.md @@ -2,7 +2,7 @@ title: skip while categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Skip elements of the input while a predicate is true. usage: | diff --git a/commands/docs/sleep.md b/commands/docs/sleep.md index f6c0e311e98..455209c0f80 100644 --- a/commands/docs/sleep.md +++ b/commands/docs/sleep.md @@ -2,7 +2,7 @@ title: sleep categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Delay for a specified amount of time. usage: | diff --git a/commands/docs/slice.md b/commands/docs/slice.md index 265c80e87f9..d4b4ab1ff22 100644 --- a/commands/docs/slice.md +++ b/commands/docs/slice.md @@ -2,7 +2,7 @@ title: slice categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Return only the selected rows. usage: | diff --git a/commands/docs/sort-by.md b/commands/docs/sort-by.md index ce8826b1a07..df75a9ad06d 100644 --- a/commands/docs/sort-by.md +++ b/commands/docs/sort-by.md @@ -2,7 +2,7 @@ title: sort-by categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Sort by the given cell path or closure. usage: | diff --git a/commands/docs/sort.md b/commands/docs/sort.md index 0e975293ad4..a8865060ff1 100644 --- a/commands/docs/sort.md +++ b/commands/docs/sort.md @@ -2,7 +2,7 @@ title: sort categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Sort in increasing order. usage: | diff --git a/commands/docs/source-env.md b/commands/docs/source-env.md index 947a004ac8e..9a82bc27ac9 100644 --- a/commands/docs/source-env.md +++ b/commands/docs/source-env.md @@ -2,7 +2,7 @@ title: source-env categories: | core -version: 0.106.0 +version: 0.107.0 core: | Source the environment from a source file into the current environment. usage: | diff --git a/commands/docs/source.md b/commands/docs/source.md index f0467c2f987..8091077393e 100644 --- a/commands/docs/source.md +++ b/commands/docs/source.md @@ -2,7 +2,7 @@ title: source categories: | core -version: 0.106.0 +version: 0.107.0 core: | Runs a script file in the current context. usage: | diff --git a/commands/docs/split.md b/commands/docs/split.md index 04bde9cd11b..5aa017745cf 100644 --- a/commands/docs/split.md +++ b/commands/docs/split.md @@ -2,7 +2,7 @@ title: split categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Split contents across desired subcommand (like row, column) via the separator. usage: | diff --git a/commands/docs/split_cell-path.md b/commands/docs/split_cell-path.md index dac4a72cfc1..8b5f2388f9d 100644 --- a/commands/docs/split_cell-path.md +++ b/commands/docs/split_cell-path.md @@ -2,7 +2,7 @@ title: split cell-path categories: | conversions -version: 0.106.0 +version: 0.107.0 conversions: | Split a cell-path into its components. usage: | diff --git a/commands/docs/split_chars.md b/commands/docs/split_chars.md index 550933b90a1..36f131e9b21 100644 --- a/commands/docs/split_chars.md +++ b/commands/docs/split_chars.md @@ -2,7 +2,7 @@ title: split chars categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Split a string into a list of characters. usage: | diff --git a/commands/docs/split_column.md b/commands/docs/split_column.md index 683b4cd4a33..58e58beeecd 100644 --- a/commands/docs/split_column.md +++ b/commands/docs/split_column.md @@ -2,7 +2,7 @@ title: split column categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Split a string into multiple columns using a separator. usage: | diff --git a/commands/docs/split_list.md b/commands/docs/split_list.md index 9baedcd6637..67f3a504e8c 100644 --- a/commands/docs/split_list.md +++ b/commands/docs/split_list.md @@ -2,7 +2,7 @@ title: split list categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Split a list into multiple lists using a separator. usage: | diff --git a/commands/docs/split_row.md b/commands/docs/split_row.md index b4675f4d098..31a6835d9c5 100644 --- a/commands/docs/split_row.md +++ b/commands/docs/split_row.md @@ -2,7 +2,7 @@ title: split row categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Split a string into multiple rows using a separator. usage: | diff --git a/commands/docs/split_words.md b/commands/docs/split_words.md index 49575f81ca2..7f8eee98b73 100644 --- a/commands/docs/split_words.md +++ b/commands/docs/split_words.md @@ -2,7 +2,7 @@ title: split words categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Split a string's words into separate rows. usage: | diff --git a/commands/docs/start.md b/commands/docs/start.md index 7e67a18b3e8..b6fb591a855 100644 --- a/commands/docs/start.md +++ b/commands/docs/start.md @@ -2,7 +2,7 @@ title: start categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Open a folder, file, or website in the default application or viewer. usage: | diff --git a/commands/docs/stor.md b/commands/docs/stor.md index 9c3c0b2e4ef..70ddffd25b5 100644 --- a/commands/docs/stor.md +++ b/commands/docs/stor.md @@ -2,7 +2,7 @@ title: stor categories: | database -version: 0.106.0 +version: 0.107.0 database: | Various commands for working with the in-memory sqlite database. usage: | diff --git a/commands/docs/stor_create.md b/commands/docs/stor_create.md index 79e84b04604..873daa9cf53 100644 --- a/commands/docs/stor_create.md +++ b/commands/docs/stor_create.md @@ -2,7 +2,7 @@ title: stor create categories: | database -version: 0.106.0 +version: 0.107.0 database: | Create a table in the in-memory sqlite database. usage: | @@ -38,3 +38,9 @@ Create an in-memory sqlite database with specified table name, column names, and > stor create --table-name nudb --columns {bool1: bool, int1: int, float1: float, str1: str, datetime1: datetime} ``` + +Create an in-memory sqlite database with a json column +```nu +> stor create --table-name files_with_md --columns {file: str, metadata: jsonb} + +``` diff --git a/commands/docs/stor_delete.md b/commands/docs/stor_delete.md index 2a51f7a2d57..f2bc5966e23 100644 --- a/commands/docs/stor_delete.md +++ b/commands/docs/stor_delete.md @@ -2,7 +2,7 @@ title: stor delete categories: | database -version: 0.106.0 +version: 0.107.0 database: | Delete a table or specified rows in the in-memory sqlite database. usage: | diff --git a/commands/docs/stor_export.md b/commands/docs/stor_export.md index bf1849a5c26..86785f4fde0 100644 --- a/commands/docs/stor_export.md +++ b/commands/docs/stor_export.md @@ -2,7 +2,7 @@ title: stor export categories: | database -version: 0.106.0 +version: 0.107.0 database: | Export the in-memory sqlite database to a sqlite database file. usage: | diff --git a/commands/docs/stor_import.md b/commands/docs/stor_import.md index f9344c56386..5abed85e706 100644 --- a/commands/docs/stor_import.md +++ b/commands/docs/stor_import.md @@ -2,7 +2,7 @@ title: stor import categories: | database -version: 0.106.0 +version: 0.107.0 database: | Import a sqlite database file into the in-memory sqlite database. usage: | diff --git a/commands/docs/stor_insert.md b/commands/docs/stor_insert.md index b016d49a44a..8a7703006e3 100644 --- a/commands/docs/stor_insert.md +++ b/commands/docs/stor_insert.md @@ -2,7 +2,7 @@ title: stor insert categories: | database -version: 0.106.0 +version: 0.107.0 database: | Insert information into a specified table in the in-memory sqlite database. usage: | @@ -59,3 +59,9 @@ Insert ls entries > ls | stor insert --table-name files ``` + +Insert nu records as json data +```nu +> ls -l | each {{file: $in.name, metadata: ($in | reject name)}} | stor insert --table-name files_with_md + +``` diff --git a/commands/docs/stor_open.md b/commands/docs/stor_open.md index 06045dbac97..1b348fb7667 100644 --- a/commands/docs/stor_open.md +++ b/commands/docs/stor_open.md @@ -2,7 +2,7 @@ title: stor open categories: | database -version: 0.106.0 +version: 0.107.0 database: | Opens the in-memory sqlite database. usage: | diff --git a/commands/docs/stor_reset.md b/commands/docs/stor_reset.md index f92466ae42c..6f14885b1a8 100644 --- a/commands/docs/stor_reset.md +++ b/commands/docs/stor_reset.md @@ -2,7 +2,7 @@ title: stor reset categories: | database -version: 0.106.0 +version: 0.107.0 database: | Reset the in-memory database by dropping all tables. usage: | diff --git a/commands/docs/stor_update.md b/commands/docs/stor_update.md index 65129d1ab5a..425ee281567 100644 --- a/commands/docs/stor_update.md +++ b/commands/docs/stor_update.md @@ -2,7 +2,7 @@ title: stor update categories: | database -version: 0.106.0 +version: 0.107.0 database: | Update information in a specified table in the in-memory sqlite database. usage: | diff --git a/commands/docs/str.md b/commands/docs/str.md index a7f6c7bf59b..e849bd01085 100644 --- a/commands/docs/str.md +++ b/commands/docs/str.md @@ -2,7 +2,7 @@ title: str categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Various commands for working with string data. usage: | diff --git a/commands/docs/str_camel-case.md b/commands/docs/str_camel-case.md index a9e54a9d53b..a8ef1f1ed98 100644 --- a/commands/docs/str_camel-case.md +++ b/commands/docs/str_camel-case.md @@ -2,7 +2,7 @@ title: str camel-case categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Convert a string to camelCase. usage: | diff --git a/commands/docs/str_capitalize.md b/commands/docs/str_capitalize.md index 17af54aab5f..6b0a43e5a99 100644 --- a/commands/docs/str_capitalize.md +++ b/commands/docs/str_capitalize.md @@ -2,7 +2,7 @@ title: str capitalize categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Capitalize first letter of text. usage: | diff --git a/commands/docs/str_contains.md b/commands/docs/str_contains.md index 6a6a632d64d..6d3497ec2b0 100644 --- a/commands/docs/str_contains.md +++ b/commands/docs/str_contains.md @@ -2,7 +2,7 @@ title: str contains categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Checks if string input contains a substring. usage: | diff --git a/commands/docs/str_distance.md b/commands/docs/str_distance.md index c17092a4a0a..1088e7aa017 100644 --- a/commands/docs/str_distance.md +++ b/commands/docs/str_distance.md @@ -2,7 +2,7 @@ title: str distance categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Compare two strings and return the edit distance/Levenshtein distance. usage: | diff --git a/commands/docs/str_downcase.md b/commands/docs/str_downcase.md index 79eaeec6bda..f83d84c1116 100644 --- a/commands/docs/str_downcase.md +++ b/commands/docs/str_downcase.md @@ -2,7 +2,7 @@ title: str downcase categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Make text lowercase. usage: | diff --git a/commands/docs/str_ends-with.md b/commands/docs/str_ends-with.md index 3bda1e8fa9b..82924b89462 100644 --- a/commands/docs/str_ends-with.md +++ b/commands/docs/str_ends-with.md @@ -2,7 +2,7 @@ title: str ends-with categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Check if an input ends with a string. usage: | diff --git a/commands/docs/str_expand.md b/commands/docs/str_expand.md index faf56bcc0cf..55104913094 100644 --- a/commands/docs/str_expand.md +++ b/commands/docs/str_expand.md @@ -2,7 +2,7 @@ title: str expand categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Generates all possible combinations defined in brace expansion syntax. usage: | diff --git a/commands/docs/str_index-of.md b/commands/docs/str_index-of.md index aa88851eaa0..f3dd8474b41 100644 --- a/commands/docs/str_index-of.md +++ b/commands/docs/str_index-of.md @@ -2,7 +2,7 @@ title: str index-of categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Returns start index of first occurrence of string in input, or -1 if no match. usage: | diff --git a/commands/docs/str_join.md b/commands/docs/str_join.md index bf5214b6236..0a8ed85a4ed 100644 --- a/commands/docs/str_join.md +++ b/commands/docs/str_join.md @@ -2,7 +2,7 @@ title: str join categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Concatenate multiple strings into a single string, with an optional separator between each. usage: | diff --git a/commands/docs/str_kebab-case.md b/commands/docs/str_kebab-case.md index 76c1857ca5b..4f6edb41f35 100644 --- a/commands/docs/str_kebab-case.md +++ b/commands/docs/str_kebab-case.md @@ -2,7 +2,7 @@ title: str kebab-case categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Convert a string to kebab-case. usage: | diff --git a/commands/docs/str_length.md b/commands/docs/str_length.md index f80bb23c174..446f37eeddd 100644 --- a/commands/docs/str_length.md +++ b/commands/docs/str_length.md @@ -2,7 +2,7 @@ title: str length categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Output the length of any strings in the pipeline. usage: | diff --git a/commands/docs/str_pascal-case.md b/commands/docs/str_pascal-case.md index 0d9c63c557f..94751833248 100644 --- a/commands/docs/str_pascal-case.md +++ b/commands/docs/str_pascal-case.md @@ -2,7 +2,7 @@ title: str pascal-case categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Convert a string to PascalCase. usage: | diff --git a/commands/docs/str_replace.md b/commands/docs/str_replace.md index 211b56c9a6b..33e43638922 100644 --- a/commands/docs/str_replace.md +++ b/commands/docs/str_replace.md @@ -2,7 +2,7 @@ title: str replace categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Find and replace text. usage: | diff --git a/commands/docs/str_reverse.md b/commands/docs/str_reverse.md index efefd674130..ffe90670930 100644 --- a/commands/docs/str_reverse.md +++ b/commands/docs/str_reverse.md @@ -2,7 +2,7 @@ title: str reverse categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Reverse every string in the pipeline. usage: | diff --git a/commands/docs/str_screaming-snake-case.md b/commands/docs/str_screaming-snake-case.md index 9c4fe6a165f..70413a08e3b 100644 --- a/commands/docs/str_screaming-snake-case.md +++ b/commands/docs/str_screaming-snake-case.md @@ -2,7 +2,7 @@ title: str screaming-snake-case categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Convert a string to SCREAMING_SNAKE_CASE. usage: | diff --git a/commands/docs/str_snake-case.md b/commands/docs/str_snake-case.md index 7e663c13f4f..7d11bd80ab9 100644 --- a/commands/docs/str_snake-case.md +++ b/commands/docs/str_snake-case.md @@ -2,7 +2,7 @@ title: str snake-case categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Convert a string to snake_case. usage: | diff --git a/commands/docs/str_starts-with.md b/commands/docs/str_starts-with.md index 6c737a133ea..3621376b5e4 100644 --- a/commands/docs/str_starts-with.md +++ b/commands/docs/str_starts-with.md @@ -2,7 +2,7 @@ title: str starts-with categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Check if an input starts with a string. usage: | diff --git a/commands/docs/str_stats.md b/commands/docs/str_stats.md index ec952740e49..b94967cbb12 100644 --- a/commands/docs/str_stats.md +++ b/commands/docs/str_stats.md @@ -2,7 +2,7 @@ title: str stats categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Gather word count statistics on the text. usage: | diff --git a/commands/docs/str_substring.md b/commands/docs/str_substring.md index e6cca264cf9..2406349b4fb 100644 --- a/commands/docs/str_substring.md +++ b/commands/docs/str_substring.md @@ -2,7 +2,7 @@ title: str substring categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Get part of a string. Note that the first character of a string is index 0. usage: | diff --git a/commands/docs/str_title-case.md b/commands/docs/str_title-case.md index 400373cdeb6..efd286b5c83 100644 --- a/commands/docs/str_title-case.md +++ b/commands/docs/str_title-case.md @@ -2,7 +2,7 @@ title: str title-case categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Convert a string to Title Case. usage: | diff --git a/commands/docs/str_trim.md b/commands/docs/str_trim.md index e5833ac5065..ba5e064e8c2 100644 --- a/commands/docs/str_trim.md +++ b/commands/docs/str_trim.md @@ -2,7 +2,7 @@ title: str trim categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Trim whitespace or specific character. usage: | diff --git a/commands/docs/str_upcase.md b/commands/docs/str_upcase.md index 1c42a15bad6..11260a0d360 100644 --- a/commands/docs/str_upcase.md +++ b/commands/docs/str_upcase.md @@ -2,7 +2,7 @@ title: str upcase categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Make text uppercase. usage: | diff --git a/commands/docs/sys.md b/commands/docs/sys.md index d6ec0cc3630..66d5d5f0a97 100644 --- a/commands/docs/sys.md +++ b/commands/docs/sys.md @@ -2,7 +2,7 @@ title: sys categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the system. usage: | diff --git a/commands/docs/sys_cpu.md b/commands/docs/sys_cpu.md index ded4f5e5722..13b779dff3b 100644 --- a/commands/docs/sys_cpu.md +++ b/commands/docs/sys_cpu.md @@ -2,7 +2,7 @@ title: sys cpu categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the system CPUs. usage: | diff --git a/commands/docs/sys_disks.md b/commands/docs/sys_disks.md index 5ec93973d84..190c5c7b565 100644 --- a/commands/docs/sys_disks.md +++ b/commands/docs/sys_disks.md @@ -2,7 +2,7 @@ title: sys disks categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the system disks. usage: | diff --git a/commands/docs/sys_host.md b/commands/docs/sys_host.md index a54dbb012aa..c54b76e9fa3 100644 --- a/commands/docs/sys_host.md +++ b/commands/docs/sys_host.md @@ -2,7 +2,7 @@ title: sys host categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the system host. usage: | diff --git a/commands/docs/sys_mem.md b/commands/docs/sys_mem.md index 2a6ec5aeb81..548bd158613 100644 --- a/commands/docs/sys_mem.md +++ b/commands/docs/sys_mem.md @@ -2,7 +2,7 @@ title: sys mem categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the system memory. usage: | diff --git a/commands/docs/sys_net.md b/commands/docs/sys_net.md index 509ae3d28d6..5a05cec339a 100644 --- a/commands/docs/sys_net.md +++ b/commands/docs/sys_net.md @@ -2,7 +2,7 @@ title: sys net categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the system network interfaces. usage: | diff --git a/commands/docs/sys_temp.md b/commands/docs/sys_temp.md index 09f31a1c4a2..7265402dba3 100644 --- a/commands/docs/sys_temp.md +++ b/commands/docs/sys_temp.md @@ -2,7 +2,7 @@ title: sys temp categories: | system -version: 0.106.0 +version: 0.107.0 system: | View the temperatures of system components. usage: | diff --git a/commands/docs/sys_users.md b/commands/docs/sys_users.md index d89d5c992c4..3b498ab60fc 100644 --- a/commands/docs/sys_users.md +++ b/commands/docs/sys_users.md @@ -2,7 +2,7 @@ title: sys users categories: | system -version: 0.106.0 +version: 0.107.0 system: | View information about the users on the system. usage: | diff --git a/commands/docs/table.md b/commands/docs/table.md index 72ad96484e4..1450ed9bb5f 100644 --- a/commands/docs/table.md +++ b/commands/docs/table.md @@ -2,7 +2,7 @@ title: table categories: | viewers -version: 0.106.0 +version: 0.107.0 viewers: | Render the table. usage: | diff --git a/commands/docs/take.md b/commands/docs/take.md index 375c2aa4007..9aec8859820 100644 --- a/commands/docs/take.md +++ b/commands/docs/take.md @@ -2,7 +2,7 @@ title: take categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Take only the first n elements of a list, or the first n bytes of a binary value. usage: | diff --git a/commands/docs/take_until.md b/commands/docs/take_until.md index da7e4e27fa2..a0dda9e7bcd 100644 --- a/commands/docs/take_until.md +++ b/commands/docs/take_until.md @@ -2,7 +2,7 @@ title: take until categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Take elements of the input until a predicate is true. usage: | diff --git a/commands/docs/take_while.md b/commands/docs/take_while.md index 7cc69c61591..ba182f7d341 100644 --- a/commands/docs/take_while.md +++ b/commands/docs/take_while.md @@ -2,7 +2,7 @@ title: take while categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Take elements of the input while a predicate is true. usage: | diff --git a/commands/docs/tee.md b/commands/docs/tee.md index b1c55915496..e5be7cad854 100644 --- a/commands/docs/tee.md +++ b/commands/docs/tee.md @@ -2,7 +2,7 @@ title: tee categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Copy a stream to another command in parallel. usage: | diff --git a/commands/docs/term.md b/commands/docs/term.md index 0cc92fe98db..89f5543041d 100644 --- a/commands/docs/term.md +++ b/commands/docs/term.md @@ -2,7 +2,7 @@ title: term categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Commands for querying information about the terminal. usage: | diff --git a/commands/docs/term_query.md b/commands/docs/term_query.md index a17fc6a7e89..e320df46c0c 100644 --- a/commands/docs/term_query.md +++ b/commands/docs/term_query.md @@ -2,7 +2,7 @@ title: term query categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Query the terminal for information. usage: | diff --git a/commands/docs/term_size.md b/commands/docs/term_size.md index 12ba4ffe81f..23a2db52ed0 100644 --- a/commands/docs/term_size.md +++ b/commands/docs/term_size.md @@ -2,7 +2,7 @@ title: term size categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Returns a record containing the number of columns (width) and rows (height) of the terminal. usage: | diff --git a/commands/docs/timeit.md b/commands/docs/timeit.md index 47958a9acd8..efe750508b7 100644 --- a/commands/docs/timeit.md +++ b/commands/docs/timeit.md @@ -2,7 +2,7 @@ title: timeit categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Time how long it takes a closure to run. usage: | diff --git a/commands/docs/to.md b/commands/docs/to.md index 94df5470a99..a5b5b6250c4 100644 --- a/commands/docs/to.md +++ b/commands/docs/to.md @@ -2,7 +2,7 @@ title: to categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Translate structured data to a format. usage: | diff --git a/commands/docs/to_csv.md b/commands/docs/to_csv.md index df9d225ff36..19efaa60e37 100644 --- a/commands/docs/to_csv.md +++ b/commands/docs/to_csv.md @@ -2,7 +2,7 @@ title: to csv categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert table into .csv text . usage: | diff --git a/commands/docs/to_html.md b/commands/docs/to_html.md index 9f19ae3bc7e..ad47f33d8ea 100644 --- a/commands/docs/to_html.md +++ b/commands/docs/to_html.md @@ -2,7 +2,7 @@ title: to html categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert table into simple HTML. usage: | @@ -28,6 +28,7 @@ contributors: false - `--partial, -p`: only output the html for the content itself - `--theme, -t {string}`: the name of the theme to use (github, blulocolight, ...); case-insensitive - `--list, -l`: produce a color table of all available themes + - `--raw, -r`: do not escape html tags ## Input/output types: @@ -38,12 +39,18 @@ contributors: false | any | string | ## Examples -Outputs an HTML string representing the contents of this table +Outputs an HTML string representing the contents of this table ```nu > [[foo bar]; [1 2]] | to html
foobar
12
``` +Outputs an HTML string using a record of xml data +```nu +> {tag: a attributes: { style: "color: red" } content: ["hello!"] } | to xml | to html --raw +hello! +``` + Optionally, only output the html for the content itself ```nu > [[foo bar]; [1 2]] | to html --partial diff --git a/commands/docs/to_json.md b/commands/docs/to_json.md index 697328a15d5..8cf9458a289 100644 --- a/commands/docs/to_json.md +++ b/commands/docs/to_json.md @@ -2,7 +2,7 @@ title: to json categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Converts table data into JSON text. usage: | diff --git a/commands/docs/to_md.md b/commands/docs/to_md.md index 2fe87205325..43934cbb21b 100644 --- a/commands/docs/to_md.md +++ b/commands/docs/to_md.md @@ -2,7 +2,7 @@ title: to md categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert table into simple Markdown. usage: | diff --git a/commands/docs/to_msgpack.md b/commands/docs/to_msgpack.md index 4b5099c2f72..8bf00e24ec9 100644 --- a/commands/docs/to_msgpack.md +++ b/commands/docs/to_msgpack.md @@ -2,7 +2,7 @@ title: to msgpack categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert Nu values into MessagePack. usage: | diff --git a/commands/docs/to_msgpackz.md b/commands/docs/to_msgpackz.md index 75431bdad8a..3e197952b5b 100644 --- a/commands/docs/to_msgpackz.md +++ b/commands/docs/to_msgpackz.md @@ -2,7 +2,7 @@ title: to msgpackz categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert Nu values into brotli-compressed MessagePack. usage: | diff --git a/commands/docs/to_nuon.md b/commands/docs/to_nuon.md index 48097d4cb68..8654f03927c 100644 --- a/commands/docs/to_nuon.md +++ b/commands/docs/to_nuon.md @@ -2,7 +2,7 @@ title: to nuon categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Converts table data into Nuon (Nushell Object Notation) text. usage: | diff --git a/commands/docs/to_plist.md b/commands/docs/to_plist.md index 96a86c4eff1..2ee50314e9a 100644 --- a/commands/docs/to_plist.md +++ b/commands/docs/to_plist.md @@ -2,7 +2,7 @@ title: to plist categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert Nu values into plist usage: | diff --git a/commands/docs/to_text.md b/commands/docs/to_text.md index b787227553b..9cf12595e84 100644 --- a/commands/docs/to_text.md +++ b/commands/docs/to_text.md @@ -2,7 +2,7 @@ title: to text categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Converts data into simple text. usage: | diff --git a/commands/docs/to_toml.md b/commands/docs/to_toml.md index 5ce591366c4..d4571d414a3 100644 --- a/commands/docs/to_toml.md +++ b/commands/docs/to_toml.md @@ -2,7 +2,7 @@ title: to toml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert record into .toml text. usage: | diff --git a/commands/docs/to_tsv.md b/commands/docs/to_tsv.md index 8f6946dfee3..19fb118c3f4 100644 --- a/commands/docs/to_tsv.md +++ b/commands/docs/to_tsv.md @@ -2,7 +2,7 @@ title: to tsv categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert table into .tsv text. usage: | diff --git a/commands/docs/to_xml.md b/commands/docs/to_xml.md index 17b98a0ed83..96d8c333ce7 100644 --- a/commands/docs/to_xml.md +++ b/commands/docs/to_xml.md @@ -2,7 +2,7 @@ title: to xml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert special record structure into .xml text. usage: | diff --git a/commands/docs/to_yaml.md b/commands/docs/to_yaml.md index ca9f529196a..fc324cee79e 100644 --- a/commands/docs/to_yaml.md +++ b/commands/docs/to_yaml.md @@ -2,7 +2,7 @@ title: to yaml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert table into .yaml/.yml text. usage: | diff --git a/commands/docs/to_yml.md b/commands/docs/to_yml.md index 449571a6540..018d028e8d7 100644 --- a/commands/docs/to_yml.md +++ b/commands/docs/to_yml.md @@ -2,7 +2,7 @@ title: to yml categories: | formats -version: 0.106.0 +version: 0.107.0 formats: | Convert table into .yaml/.yml text. usage: | diff --git a/commands/docs/touch.md b/commands/docs/touch.md index d70cb6e2ed8..875a4c1de08 100644 --- a/commands/docs/touch.md +++ b/commands/docs/touch.md @@ -2,7 +2,7 @@ title: touch categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Creates one or more files. usage: | diff --git a/commands/docs/transpose.md b/commands/docs/transpose.md index 863263ad5dd..452e780b845 100644 --- a/commands/docs/transpose.md +++ b/commands/docs/transpose.md @@ -2,7 +2,7 @@ title: transpose categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Transposes the table contents so rows become columns and columns become rows. usage: | diff --git a/commands/docs/try.md b/commands/docs/try.md index acd801817d6..a237e2101f7 100644 --- a/commands/docs/try.md +++ b/commands/docs/try.md @@ -2,7 +2,7 @@ title: try categories: | core -version: 0.106.0 +version: 0.107.0 core: | Try to run a block, if it fails optionally run a catch closure. usage: | diff --git a/commands/docs/tutor.md b/commands/docs/tutor.md index aeca0393cd1..12c0c7ea28c 100644 --- a/commands/docs/tutor.md +++ b/commands/docs/tutor.md @@ -2,7 +2,7 @@ title: tutor categories: | misc -version: 0.106.0 +version: 0.107.0 misc: | Run the tutorial. To begin, run: tutor. usage: | diff --git a/commands/docs/ulimit.md b/commands/docs/ulimit.md index d15c32ceb19..a2c0a17fda0 100644 --- a/commands/docs/ulimit.md +++ b/commands/docs/ulimit.md @@ -2,7 +2,7 @@ title: ulimit categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Set or get resource usage limits. usage: | diff --git a/commands/docs/uname.md b/commands/docs/uname.md index dbb75a428b3..c81e9f1ace8 100644 --- a/commands/docs/uname.md +++ b/commands/docs/uname.md @@ -2,7 +2,7 @@ title: uname categories: | system -version: 0.106.0 +version: 0.107.0 system: | Print certain system information using uutils/coreutils uname. usage: | diff --git a/commands/docs/uniq-by.md b/commands/docs/uniq-by.md index c76713dd155..0873743f335 100644 --- a/commands/docs/uniq-by.md +++ b/commands/docs/uniq-by.md @@ -2,7 +2,7 @@ title: uniq-by categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Return the distinct values in the input by the given column(s). usage: | diff --git a/commands/docs/uniq.md b/commands/docs/uniq.md index f753dc429fe..6bebd798474 100644 --- a/commands/docs/uniq.md +++ b/commands/docs/uniq.md @@ -2,7 +2,7 @@ title: uniq categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Return the distinct values in the input. usage: | diff --git a/commands/docs/update.md b/commands/docs/update.md index ad34e7c0f4b..53d61605730 100644 --- a/commands/docs/update.md +++ b/commands/docs/update.md @@ -2,7 +2,7 @@ title: update categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Update an existing column to have a new value. usage: | diff --git a/commands/docs/update_cells.md b/commands/docs/update_cells.md index 3ddc98a30a4..c0a606aa006 100644 --- a/commands/docs/update_cells.md +++ b/commands/docs/update_cells.md @@ -2,7 +2,7 @@ title: update cells categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Update the table cells. usage: | diff --git a/commands/docs/upsert.md b/commands/docs/upsert.md index d4322c1ee77..b94d1c48b03 100644 --- a/commands/docs/upsert.md +++ b/commands/docs/upsert.md @@ -2,7 +2,7 @@ title: upsert categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Update an existing column to have a new value, or insert a new column. usage: | diff --git a/commands/docs/url.md b/commands/docs/url.md index 725f96ded0f..19ac87bb46f 100644 --- a/commands/docs/url.md +++ b/commands/docs/url.md @@ -2,7 +2,7 @@ title: url categories: | network -version: 0.106.0 +version: 0.107.0 network: | Various commands for working with URLs. usage: | diff --git a/commands/docs/url_build-query.md b/commands/docs/url_build-query.md index 975e2184a8b..bdec77117eb 100644 --- a/commands/docs/url_build-query.md +++ b/commands/docs/url_build-query.md @@ -2,7 +2,7 @@ title: url build-query categories: | network -version: 0.106.0 +version: 0.107.0 network: | Converts record or table into query string applying percent-encoding. usage: | diff --git a/commands/docs/url_decode.md b/commands/docs/url_decode.md index f53061a850e..48eb6cffea1 100644 --- a/commands/docs/url_decode.md +++ b/commands/docs/url_decode.md @@ -2,7 +2,7 @@ title: url decode categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Converts a percent-encoded web safe string to a string. usage: | diff --git a/commands/docs/url_encode.md b/commands/docs/url_encode.md index 36951bad71f..a1fecfc506c 100644 --- a/commands/docs/url_encode.md +++ b/commands/docs/url_encode.md @@ -2,7 +2,7 @@ title: url encode categories: | strings -version: 0.106.0 +version: 0.107.0 strings: | Converts a string to a percent encoded web safe string. usage: | diff --git a/commands/docs/url_join.md b/commands/docs/url_join.md index 5fe5525d4cf..d1a712be430 100644 --- a/commands/docs/url_join.md +++ b/commands/docs/url_join.md @@ -2,7 +2,7 @@ title: url join categories: | network -version: 0.106.0 +version: 0.107.0 network: | Converts a record to url. usage: | diff --git a/commands/docs/url_parse.md b/commands/docs/url_parse.md index 6fee0e3dc48..fc6ce957d60 100644 --- a/commands/docs/url_parse.md +++ b/commands/docs/url_parse.md @@ -2,7 +2,7 @@ title: url parse categories: | network -version: 0.106.0 +version: 0.107.0 network: | Parses a url. usage: | diff --git a/commands/docs/url_split-query.md b/commands/docs/url_split-query.md index 29884adece5..85088f9ca2e 100644 --- a/commands/docs/url_split-query.md +++ b/commands/docs/url_split-query.md @@ -2,7 +2,7 @@ title: url split-query categories: | network -version: 0.106.0 +version: 0.107.0 network: | Converts query string into table applying percent-decoding. usage: | diff --git a/commands/docs/use.md b/commands/docs/use.md index 29fcd31a597..6b50f9ffb20 100644 --- a/commands/docs/use.md +++ b/commands/docs/use.md @@ -2,7 +2,7 @@ title: use categories: | core -version: 0.106.0 +version: 0.107.0 core: | Use definitions from a module, making them available in your shell. usage: | diff --git a/commands/docs/values.md b/commands/docs/values.md index e64bb9e7692..c3d5a8c76e1 100644 --- a/commands/docs/values.md +++ b/commands/docs/values.md @@ -2,7 +2,7 @@ title: values categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Given a record or table, produce a list of its columns' values. usage: | diff --git a/commands/docs/version.md b/commands/docs/version.md index c1263ce7c87..173645f211f 100644 --- a/commands/docs/version.md +++ b/commands/docs/version.md @@ -2,7 +2,7 @@ title: version categories: | core -version: 0.106.0 +version: 0.107.0 core: | Display Nu version, and its build configuration. usage: | diff --git a/commands/docs/version_check.md b/commands/docs/version_check.md index a5183da1eb3..1e2ef757c3d 100644 --- a/commands/docs/version_check.md +++ b/commands/docs/version_check.md @@ -2,7 +2,7 @@ title: version check categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Checks to see if you have the latest version of nushell. usage: | diff --git a/commands/docs/view.md b/commands/docs/view.md index cfb33e2a754..98debe42e85 100644 --- a/commands/docs/view.md +++ b/commands/docs/view.md @@ -2,7 +2,7 @@ title: view categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | Various commands for viewing debug information. usage: | diff --git a/commands/docs/view_blocks.md b/commands/docs/view_blocks.md index b112d26c7df..f87ffbad7cb 100644 --- a/commands/docs/view_blocks.md +++ b/commands/docs/view_blocks.md @@ -2,7 +2,7 @@ title: view blocks categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | View the blocks registered in nushell's EngineState memory. usage: | diff --git a/commands/docs/view_files.md b/commands/docs/view_files.md index b0d08d86679..84e37e1b3a9 100644 --- a/commands/docs/view_files.md +++ b/commands/docs/view_files.md @@ -2,7 +2,7 @@ title: view files categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | View the files registered in nushell's EngineState memory. usage: | diff --git a/commands/docs/view_ir.md b/commands/docs/view_ir.md index f1b0d57b880..865212bc759 100644 --- a/commands/docs/view_ir.md +++ b/commands/docs/view_ir.md @@ -2,7 +2,7 @@ title: view ir categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | View the compiled IR code for a block of code. usage: | diff --git a/commands/docs/view_source.md b/commands/docs/view_source.md index 06cb3ca71f7..c961c8ba297 100644 --- a/commands/docs/view_source.md +++ b/commands/docs/view_source.md @@ -2,7 +2,7 @@ title: view source categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | View a block, module, or a definition. usage: | diff --git a/commands/docs/view_span.md b/commands/docs/view_span.md index 9cfeb4f4869..fc43436af14 100644 --- a/commands/docs/view_span.md +++ b/commands/docs/view_span.md @@ -2,7 +2,7 @@ title: view span categories: | debug -version: 0.106.0 +version: 0.107.0 debug: | View the contents of a span. usage: | diff --git a/commands/docs/watch.md b/commands/docs/watch.md index 1508bc7dc40..8475a7448aa 100644 --- a/commands/docs/watch.md +++ b/commands/docs/watch.md @@ -2,7 +2,7 @@ title: watch categories: | filesystem -version: 0.106.0 +version: 0.107.0 filesystem: | Watch for file changes and execute Nu code when they happen. usage: | @@ -22,7 +22,8 @@ contributors: false ## Flags - - `--debounce-ms, -d {int}`: Debounce changes for this many milliseconds (default: 100). Adjust if you find that single writes are reported as multiple events + - `--debounce-ms, -d {int}`: Debounce changes for this many milliseconds (default: 100). Adjust if you find that single writes are reported as multiple events (deprecated) + - `--debounce {duration}`: Debounce changes for this duration (default: 100ms). Adjust if you find that single writes are reported as multiple events - `--glob, -g {string}`: Only report changes for files that match this glob pattern (default: all files) - `--recursive, -r {bool}`: Watch all directories under `` recursively. Will be ignored if `` is a file (default: true) - `--quiet, -q`: Hide the initial status message (default: false) @@ -36,9 +37,10 @@ contributors: false ## Input/output types: -| input | output | -| ------- | ------ | -| nothing | table | +| input | output | +| ------- | -------------------------------------------------------- | +| nothing | nothing | +| nothing | table<operation: string, path: string, new_path: string> | ## Examples Run `cargo test` whenever a Rust file changes @@ -53,9 +55,20 @@ Watch all changes in the current directory ``` -Log all changes in a directory +`watch` (when run without a closure) can also emit a stream of events it detects. ```nu -> watch /foo/bar { |op, path| $"($op) - ($path)(char nl)" | save --append changes_in_bar.log } +> watch /foo/bar + | where operation == Create + | first 5 + | each {|e| $"New file!: ($e.path)" } + | to text + | save --append changes_in_bar.log + +``` + +Print file changes with a debounce time of 5 minutes +```nu +> watch /foo/bar --debounce 5min { |op, path| $"Registered ($op) on ($path)" | print } ``` @@ -64,3 +77,6 @@ Note: if you are looking to run a command every N units of time, this can be acc > loop { command; sleep duration } ``` + +## Notes +When run without a closure, `watch` returns a stream of events instead. \ No newline at end of file diff --git a/commands/docs/where.md b/commands/docs/where.md index 03ff44e87eb..10ddbc3b7b9 100644 --- a/commands/docs/where.md +++ b/commands/docs/where.md @@ -2,7 +2,7 @@ title: where categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Filter values of an input list based on a condition. usage: | diff --git a/commands/docs/which.md b/commands/docs/which.md index 4822c369af5..4bf52d68ca5 100644 --- a/commands/docs/which.md +++ b/commands/docs/which.md @@ -2,7 +2,7 @@ title: which categories: | system -version: 0.106.0 +version: 0.107.0 system: | Finds a program file, alias or custom command. usage: | diff --git a/commands/docs/while.md b/commands/docs/while.md index 8c6c88eff0b..9e86e1c17ca 100644 --- a/commands/docs/while.md +++ b/commands/docs/while.md @@ -2,7 +2,7 @@ title: while categories: | core -version: 0.106.0 +version: 0.107.0 core: | Conditionally run a block in a loop. usage: | diff --git a/commands/docs/whoami.md b/commands/docs/whoami.md index 18ede1f2dbb..47b04a8bce8 100644 --- a/commands/docs/whoami.md +++ b/commands/docs/whoami.md @@ -2,7 +2,7 @@ title: whoami categories: | platform -version: 0.106.0 +version: 0.107.0 platform: | Get the current username using uutils/coreutils whoami. usage: | diff --git a/commands/docs/window.md b/commands/docs/window.md index 1d04ef66b94..6bce3cf760f 100644 --- a/commands/docs/window.md +++ b/commands/docs/window.md @@ -2,7 +2,7 @@ title: window categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Creates a sliding window of `window_size` that slide by n rows/elements across input. usage: | diff --git a/commands/docs/with-env.md b/commands/docs/with-env.md index 28e2e089d89..1f07a68caef 100644 --- a/commands/docs/with-env.md +++ b/commands/docs/with-env.md @@ -2,7 +2,7 @@ title: with-env categories: | env -version: 0.106.0 +version: 0.107.0 env: | Runs a block with an environment variable set. usage: | diff --git a/commands/docs/wrap.md b/commands/docs/wrap.md index 3ff30eceee6..eff1ae16073 100644 --- a/commands/docs/wrap.md +++ b/commands/docs/wrap.md @@ -2,7 +2,7 @@ title: wrap categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Wrap the value into a column. usage: | diff --git a/commands/docs/zip.md b/commands/docs/zip.md index 9a9bcef2bc6..22bd5db55b5 100644 --- a/commands/docs/zip.md +++ b/commands/docs/zip.md @@ -2,7 +2,7 @@ title: zip categories: | filters -version: 0.106.0 +version: 0.107.0 filters: | Combine a stream with the input. usage: |