Skip to content

Commit a95543a

Browse files
committed
Refresh command docs for Nu v0.93
1 parent 0a7a6e8 commit a95543a

File tree

529 files changed

+1136
-633
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

529 files changed

+1136
-633
lines changed

.vuepress/configs/sidebar/command_categories.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ export const commandCategories = [
2525
'/commands/categories/network.md',
2626
'/commands/categories/path.md',
2727
'/commands/categories/platform.md',
28+
'/commands/categories/plugin.md',
2829
'/commands/categories/prompt.md',
2930
'/commands/categories/random.md',
3031
'/commands/categories/removed.md',

commands/categories/plugin.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Plugin
2+
3+
<script>
4+
import pages from '@temp/pages'
5+
export default {
6+
computed: {
7+
commands() {
8+
return pages
9+
.filter(p => p.path.includes('/commands/docs/'))
10+
.filter(p => p.frontmatter.categories.includes('plugin'))
11+
.sort((a,b) => (a.title > b.title) ? 1 : ((b.title > a.title) ? -1 : 0));
12+
}
13+
}
14+
}
15+
</script>
16+
17+
<table>
18+
<tr>
19+
<th>Command</th>
20+
<th>Description</th>
21+
</tr>
22+
<tr v-for="command in commands">
23+
<td><a :href="$withBase(command.path)">{{ command.title }}</a></td>
24+
<td style="white-space: pre-wrap;">{{ command.frontmatter.usage }}</td>
25+
</tr>
26+
</table>

commands/docs/alias.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: alias
33
categories: |
44
core
5-
version: 0.92.0
5+
version: 0.92.3
66
core: |
77
Alias a command (with optional flags) to a new name.
88
usage: |

commands/docs/all.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: all
33
categories: |
44
filters
5-
version: 0.92.0
5+
version: 0.92.3
66
filters: |
77
Test if every element of the input fulfills a predicate expression.
88
usage: |

commands/docs/ansi.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: ansi
33
categories: |
44
platform
5-
version: 0.92.0
5+
version: 0.92.3
66
platform: |
77
Output ANSI codes to change color and style of text.
88
usage: |

commands/docs/ansi_gradient.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: ansi gradient
33
categories: |
44
platform
5-
version: 0.92.0
5+
version: 0.92.3
66
platform: |
77
Add a color gradient (using ANSI color codes) to the given string.
88
usage: |

commands/docs/ansi_link.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: ansi link
33
categories: |
44
platform
5-
version: 0.92.0
5+
version: 0.92.3
66
platform: |
77
Add a link (using OSC 8 escape sequence) to the given string.
88
usage: |

commands/docs/ansi_strip.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: ansi strip
33
categories: |
44
platform
5-
version: 0.92.0
5+
version: 0.92.3
66
platform: |
77
Strip ANSI escape sequences from a string.
88
usage: |

commands/docs/any.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: any
33
categories: |
44
filters
5-
version: 0.92.0
5+
version: 0.92.3
66
filters: |
77
Tests if any element of the input fulfills a predicate expression.
88
usage: |

commands/docs/append.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: append
33
categories: |
44
filters
5-
version: 0.92.0
5+
version: 0.92.3
66
filters: |
77
Append any number of rows to a table.
88
usage: |

commands/docs/ast.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: ast
33
categories: |
44
debug
5-
version: 0.92.0
5+
version: 0.92.3
66
debug: |
77
Print the abstract syntax tree (ast) for a pipeline.
88
usage: |

commands/docs/bits.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Various commands for working with bits.
88
usage: |

commands/docs/bits_and.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits and
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Performs bitwise and for ints or binary values.
88
usage: |

commands/docs/bits_not.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits not
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Performs logical negation on each bit.
88
usage: |

commands/docs/bits_or.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits or
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Performs bitwise or for ints or binary values.
88
usage: |

commands/docs/bits_rol.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits rol
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Bitwise rotate left for ints or binary values.
88
usage: |

commands/docs/bits_ror.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits ror
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Bitwise rotate right for ints or binary values.
88
usage: |

commands/docs/bits_shl.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits shl
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Bitwise shift left for ints or binary values.
88
usage: |

commands/docs/bits_shr.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits shr
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Bitwise shift right for ints or binary values.
88
usage: |

commands/docs/bits_xor.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bits xor
33
categories: |
44
bits
5-
version: 0.92.0
5+
version: 0.92.3
66
bits: |
77
Performs bitwise xor for ints or binary values.
88
usage: |

commands/docs/break.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: break
33
categories: |
44
core
5-
version: 0.92.0
5+
version: 0.92.3
66
core: |
77
Break a loop.
88
usage: |

commands/docs/bytes.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Various commands for working with byte data.
88
usage: |

commands/docs/bytes_add.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes add
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Add specified bytes to the input.
88
usage: |

commands/docs/bytes_at.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes at
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Get bytes defined by a range.
88
usage: |

commands/docs/bytes_build.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes build
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Create bytes from the arguments.
88
usage: |

commands/docs/bytes_collect.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes collect
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Concatenate multiple binary into a single binary, with an optional separator between each.
88
usage: |

commands/docs/bytes_ends-with.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes ends-with
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Check if bytes ends with a pattern.
88
usage: |

commands/docs/bytes_index-of.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes index-of
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Returns start index of first occurrence of pattern in bytes, or -1 if no match.
88
usage: |

commands/docs/bytes_length.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes length
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Output the length of any bytes in the pipeline.
88
usage: |

commands/docs/bytes_remove.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes remove
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Remove bytes.
88
usage: |

commands/docs/bytes_replace.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes replace
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Find and replace binary.
88
usage: |

commands/docs/bytes_reverse.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes reverse
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Reverse the bytes in the pipeline.
88
usage: |

commands/docs/bytes_starts-with.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: bytes starts-with
33
categories: |
44
bytes
5-
version: 0.92.0
5+
version: 0.92.3
66
bytes: |
77
Check if bytes starts with a pattern.
88
usage: |

commands/docs/cal.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: cal
33
categories: |
44
generators
5-
version: 0.92.0
5+
version: 0.92.3
66
generators: |
77
Display a calendar.
88
usage: |
@@ -51,6 +51,6 @@ The calendar for all of 2012
5151

5252
This month's calendar with the week starting on monday
5353
```nu
54-
> cal --week-start monday
54+
> cal --week-start mo
5555
5656
```

commands/docs/cd.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: cd
33
categories: |
44
filesystem
5-
version: 0.92.0
5+
version: 0.92.3
66
filesystem: |
77
Change directory.
88
usage: |

commands/docs/char.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: char
33
categories: |
44
strings
5-
version: 0.92.0
5+
version: 0.92.3
66
strings: |
77
Output special characters (e.g., 'newline').
88
usage: |

commands/docs/clear.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: clear
33
categories: |
44
platform
5-
version: 0.92.0
5+
version: 0.92.3
66
platform: |
77
Clear the terminal.
88
usage: |

commands/docs/collect.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,26 @@
22
title: collect
33
categories: |
44
filters
5-
version: 0.92.0
5+
version: 0.92.3
66
filters: |
7-
Collect the stream and pass it to a block.
7+
Collect a stream into a value and then run a closure with the collected value as input.
88
usage: |
9-
Collect the stream and pass it to a block.
9+
Collect a stream into a value and then run a closure with the collected value as input.
1010
feature: default
1111
---
1212
<!-- This file is automatically generated. Please edit the command in https://github.com/nushell/nushell instead. -->
1313

1414
# `collect` for [filters](/commands/categories/filters.md)
1515

16-
<div class='command-title'>Collect the stream and pass it to a block.</div>
16+
<div class='command-title'>Collect a stream into a value and then run a closure with the collected value as input.</div>
1717

1818
## Signature
1919

2020
```> collect {flags} (closure)```
2121

2222
## Flags
2323

24-
- `--keep-env, -`: let the block affect environment variables
24+
- `--keep-env, -`: let the closure affect environment variables
2525

2626
## Parameters
2727

@@ -41,3 +41,9 @@ Use the second value in the stream
4141
> [1 2 3] | collect { |x| $x.1 }
4242
2
4343
```
44+
45+
Read and write to the same file
46+
```nu
47+
> open file.txt | collect { save -f file.txt }
48+
49+
```

0 commit comments

Comments
 (0)