-
Notifications
You must be signed in to change notification settings - Fork 391
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Refresh docs for nu v0.83 * Fix command docs deployment for `input listen`
- Loading branch information
Showing
493 changed files
with
1,997 additions
and
1,147 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
title: bits | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Various commands for working with bits. | ||
usage: | | ||
Various commands for working with bits. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits ``` | ||
|
||
## Notes | ||
You must use one of the following subcommands. Using this command as-is will only produce this help message. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
title: bits and | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Performs bitwise and for integers. | ||
usage: | | ||
Performs bitwise and for integers. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits and (target)``` | ||
|
||
## Parameters | ||
|
||
- `target`: target integer to perform bit and | ||
|
||
## Examples | ||
|
||
Apply bits and to two numbers | ||
```shell | ||
> 2 | bits and 2 | ||
2 | ||
``` | ||
|
||
Apply logical and to a list of numbers | ||
```shell | ||
> [4 3 2] | bits and 2 | ||
╭───┬───╮ | ||
│ 0 │ 0 │ | ||
│ 1 │ 2 │ | ||
│ 2 │ 2 │ | ||
╰───┴───╯ | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
--- | ||
title: bits not | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Performs logical negation on each bit. | ||
usage: | | ||
Performs logical negation on each bit. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits not --signed --number-bytes``` | ||
|
||
## Parameters | ||
|
||
- `--signed` `(-s)`: always treat input number as a signed number | ||
- `--number-bytes {string}`: the size of unsigned number in bytes, it can be 1, 2, 4, 8, auto | ||
|
||
## Examples | ||
|
||
Apply logical negation to a list of numbers | ||
```shell | ||
> [4 3 2] | bits not | ||
╭───┬─────────────────╮ | ||
│ 0 │ 140737488355323 │ | ||
│ 1 │ 140737488355324 │ | ||
│ 2 │ 140737488355325 │ | ||
╰───┴─────────────────╯ | ||
|
||
``` | ||
|
||
Apply logical negation to a list of numbers, treat input as 2 bytes number | ||
```shell | ||
> [4 3 2] | bits not -n '2' | ||
╭───┬───────╮ | ||
│ 0 │ 65531 │ | ||
│ 1 │ 65532 │ | ||
│ 2 │ 65533 │ | ||
╰───┴───────╯ | ||
|
||
``` | ||
|
||
Apply logical negation to a list of numbers, treat input as signed number | ||
```shell | ||
> [4 3 2] | bits not -s | ||
╭───┬────╮ | ||
│ 0 │ -5 │ | ||
│ 1 │ -4 │ | ||
│ 2 │ -3 │ | ||
╰───┴────╯ | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
title: bits or | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Performs bitwise or for integers. | ||
usage: | | ||
Performs bitwise or for integers. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits or (target)``` | ||
|
||
## Parameters | ||
|
||
- `target`: target integer to perform bit or | ||
|
||
## Examples | ||
|
||
Apply bits or to two numbers | ||
```shell | ||
> 2 | bits or 6 | ||
6 | ||
``` | ||
|
||
Apply logical or to a list of numbers | ||
```shell | ||
> [8 3 2] | bits or 2 | ||
╭───┬────╮ | ||
│ 0 │ 10 │ | ||
│ 1 │ 3 │ | ||
│ 2 │ 2 │ | ||
╰───┴────╯ | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
--- | ||
title: bits rol | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Bitwise rotate left for integers. | ||
usage: | | ||
Bitwise rotate left for integers. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits rol (bits) --signed --number-bytes``` | ||
|
||
## Parameters | ||
|
||
- `bits`: number of bits to rotate left | ||
- `--signed` `(-s)`: always treat input number as a signed number | ||
- `--number-bytes {string}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` | ||
|
||
## Examples | ||
|
||
Rotate left a number with 2 bits | ||
```shell | ||
> 17 | bits rol 2 | ||
68 | ||
``` | ||
|
||
Rotate left a list of numbers with 2 bits | ||
```shell | ||
> [5 3 2] | bits rol 2 | ||
╭───┬────╮ | ||
│ 0 │ 20 │ | ||
│ 1 │ 12 │ | ||
│ 2 │ 8 │ | ||
╰───┴────╯ | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
--- | ||
title: bits ror | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Bitwise rotate right for integers. | ||
usage: | | ||
Bitwise rotate right for integers. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits ror (bits) --signed --number-bytes``` | ||
|
||
## Parameters | ||
|
||
- `bits`: number of bits to rotate right | ||
- `--signed` `(-s)`: always treat input number as a signed number | ||
- `--number-bytes {string}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` | ||
|
||
## Examples | ||
|
||
Rotate right a number with 60 bits | ||
```shell | ||
> 17 | bits ror 60 | ||
272 | ||
``` | ||
|
||
Rotate right a list of numbers of one byte | ||
```shell | ||
> [15 33 92] | bits ror 2 -n '1' | ||
╭───┬─────╮ | ||
│ 0 │ 195 │ | ||
│ 1 │ 72 │ | ||
│ 2 │ 23 │ | ||
╰───┴─────╯ | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
--- | ||
title: bits shl | ||
categories: | | ||
bits | ||
version: 0.83.0 | ||
bits: | | ||
Bitwise shift left for integers. | ||
usage: | | ||
Bitwise shift left for integers. | ||
--- | ||
|
||
# <code>{{ $frontmatter.title }}</code> for bits | ||
|
||
<div class='command-title'>{{ $frontmatter.bits }}</div> | ||
|
||
## Signature | ||
|
||
```> bits shl (bits) --signed --number-bytes``` | ||
|
||
## Parameters | ||
|
||
- `bits`: number of bits to shift left | ||
- `--signed` `(-s)`: always treat input number as a signed number | ||
- `--number-bytes {string}`: the word size in number of bytes, it can be 1, 2, 4, 8, auto, default value `8` | ||
|
||
## Examples | ||
|
||
Shift left a number by 7 bits | ||
```shell | ||
> 2 | bits shl 7 | ||
256 | ||
``` | ||
|
||
Shift left a number with 1 byte by 7 bits | ||
```shell | ||
> 2 | bits shl 7 -n '1' | ||
0 | ||
``` | ||
|
||
Shift left a signed number by 1 bit | ||
```shell | ||
> 0x7F | bits shl 1 -s | ||
254 | ||
``` | ||
|
||
Shift left a list of numbers | ||
```shell | ||
> [5 3 2] | bits shl 2 | ||
╭───┬────╮ | ||
│ 0 │ 20 │ | ||
│ 1 │ 12 │ | ||
│ 2 │ 8 │ | ||
╰───┴────╯ | ||
|
||
``` |
Oops, something went wrong.