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

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions book/coming_from_cmd.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,3 +73,19 @@ Executing `./ver` or `ver.bat` *will* execute the local bat file though.

Note that Nushell has its own [`start` command](/commands/docs/start.md) which takes precedence.
You can call the CMD.EXE's internal `START` command with the external command syntax `^start`.

## Clearing the commandline buffer by pressing ESC

CMD.EXE features the ability to clear the commandline buffer by pressing the ESC key.

While Nu does not replicate this by default, a keybind can be added to your `config.nu` to enable similar functionality:

```nu
$env.config.keybindings ++= [{
name: 'esc_clear'
modifier: 'None'
keycode: 'Esc'
mode: ['Emacs', 'Vi_Normal']
event: {edit: 'Clear'}
}]
```
16 changes: 16 additions & 0 deletions book/coming_from_powershell.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,19 @@ This means:
| `Get-Location` or `$PWD` | `pwd` or `$env.PWD` | Show current directory |
| `Read-Host` | `let var = input` | Read user input |
| `Read-Host -AsSecureString` | `let secret = input -s` | Read secret input |

## Clearing the commandline buffer by pressing ESC

Legacy versions of PowerShell feature the ability to clear the commandline buffer by pressing the ESC key.

While Nu does not replicate this by default, a keybind can be added to your `config.nu` to enable similar functionality:

```nu
$env.config.keybindings ++= [{
name: 'esc_clear'
modifier: 'None'
keycode: 'Esc'
mode: ['Emacs', 'Vi_Normal']
event: {edit: 'Clear'}
}]
```