Commit Graph

221 Commits

Author SHA1 Message Date
Stefan Holderbach
2b5f1ee5b3
Bump version to 0.87.1 (#11056) 2023-11-15 23:50:11 +01:00
Stefan Holderbach
77a1c3c7b2
Bump version for 0.87.0 release (#11031)
# Release checklist

- [x] reedline
  - [x] released
  - [x] pinned
- [x] crate graph check
- [x] release notes
- [x] release script update (new crate `nu-lsp`)
- [ ] permission management `nu-lsp` on crates.io
2023-11-14 21:01:19 +01:00
Christopher Durham
0f600bc3f5
Improve case insensitivity consistency (#10884)
# Description

Add an extension trait `IgnoreCaseExt` to nu_utils which adds some case
insensitivity helpers, and use them throughout nu to improve the
handling of case insensitivity. Proper case folding is done via unicase,
which is already a dependency via mime_guess from nu-command.

In actuality a lot of code still does `to_lowercase`, because unicase
only provides immediate comparison and doesn't expose a `to_folded_case`
yet. And since we do a lot of `contains`/`starts_with`/`ends_with`, it's
not sufficient to just have `eq_ignore_case`. But if we get access in
the future, this makes us ready to use it with a change in one place.

Plus, it's clearer what the purpose is at the call site to call
`to_folded_case` instead of `to_lowercase` if it's exclusively for the
purpose of case insensitive comparison, even if it just does
`to_lowercase` still.

# User-Facing Changes

- Some commands that were supposed to be case insensitive remained only
insensitive to ASCII case (a-z), and now are case insensitive w.r.t.
non-ASCII characters as well.

# Tests + Formatting

- 🟢 `toolkit fmt`
- 🟢 `toolkit clippy`
- 🟢 `toolkit test`
- 🟢 `toolkit test stdlib`

---------

Co-authored-by: Stefan Holderbach <sholderbach@users.noreply.github.com>
2023-11-08 23:58:54 +01:00
stfacc
29591c97a7
Add "shape_keyword" to default config (#10922)
Keep it in sync with Rust code.
Mainly so that people know they can style keywords.

I discovered this while trying to change color of "else".
2023-11-02 19:59:17 +01:00
Antoine Stevan
f3656f7822
sync $env.config.filesize.metric (#10277)
# Description
just noticed `$env.config.filesize.metric` is not the same in
`default_config.nu` and `config.rs`

# User-Facing Changes
filesizes will show in "binary" mode by default when using the default
config files, i.e. `kib` instead of `kb`.

# Tests + Formatting

# After Submitting
2023-10-25 16:42:24 +02:00
stfacc
6445c4e7de
Do not use white text in the default light theme (#10796)
Use instead 'dark_gray', the default fg color for the other primitives.

fixes #10636
2023-10-21 16:31:46 -05:00
Stefan Holderbach
88a87158c2
Bump version to 0.86.1 (#10755)
To dev or to patch that is the question
2023-10-18 13:00:51 -05:00
Stefan Holderbach
5d8763ed1d
Bump version for 0.86.0 release (#10726)
## Release checklist:

- [x] `uu_cp` on crates.io #10725
- [x] new `reedline` released and used nushell/reedline#645
- [x] check of workspace dependency DAG
- [x] release notes ready:
https://github.com/nushell/nushell.github.io/pull/1071
2023-10-18 06:08:20 +13:00
JT
844cb1213b
Remove cd w/ abbreviations (#10588)
# Description

This removes the old style "cd with abbreviations" that would attempt to
guess what directory you wanted to `cd` to. This would sometimes have
false positives, so we left it off by default in the config.

In the current main, we have much-improved path completions
(https://github.com/nushell/nushell/pull/10543) so you can now do `cd
a/b<tab>` and get a much better experience (because you can see the
directory you're about to cd to). This removes the need for the previous
abbreviation system.

# User-Facing Changes

This does remove the old abbreviation system. It will likely mean that
old config files that have settings for abbreviations will now get
errors.

update: here's an example of the error you'll see:


![image](https://github.com/nushell/nushell/assets/547158/6847a25d-895a-4b92-8251-278a57e8d29a)

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass (on Windows make
sure to [enable developer
mode](https://learn.microsoft.com/en-us/windows/apps/get-started/developer-mode-features-and-debugging))
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-10-03 10:51:46 +13:00
Reilly Wood
7c274ad4d8
explore: remove 4 line config options (#10562)
This PR removes the `line_head_top`, `line_head_bottom`, `line_shift`,
and `line_index` configuration options from `explore`. These were
previously used to control whether the horizontal+vertical lines in this
`ls | explore -i` screenshot would be displayed:


![image](https://github.com/nushell/nushell/assets/26268125/b705e8a0-935c-40ff-be4a-f119dbae3080)

Now, all lines are displayed (same as the previous default config
values) and this is no longer configurable.

## Context

I'm continuing to chip away at `explore` when I have time. I have a
long-term goal to make `explore` simpler for users+developers. For now
I'm mostly making small incremental changes where I find underused
functionality+configuration and remove it; hopefully eventually this
will make it easier to make larger changes.

I found these specific config options a little hard to understand when
reading `explore` code, and when reading `config.nu` as a user their
behaviour+naming is not obvious. I also think that in the long term,
`explore` styling should inherit most styling from `table` instead of
having its own styling system.
2023-09-30 17:26:43 -07:00
JT
50039164f1
fix windows default prompt slash direction (#10555)
<!--
if this PR closes one or more issues, you can automatically link the PR
with
them by using one of the [*linking
keywords*](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword),
e.g.
- this PR should close #xxxx
- fixes #xxxx

you can also mention related issues, PRs or discussions!
-->

# Description

This fixes the default prompt on Windows to use the correct path
direction

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass (on Windows make
sure to [enable developer
mode](https://learn.microsoft.com/en-us/windows/apps/get-started/developer-mode-features-and-debugging))
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-09-30 08:18:14 +13:00
Antoine Stevan
cc4f8bbd82
break the definition of LS_COLORS onto multiple lines (#10538)
related to 
- https://github.com/nushell/nushell/pull/10532

# Description
i was reviewing https://github.com/nushell/nushell/pull/10532 and
thought
> wait a minute, this line is huge and it's basically impossible to
review properly...

i had to grab the diff and throw some Nushell magic at it to see that it
was valid 😱

in this PR, i just split the loooooong string on the `:`, put that in a
list, join with `.join(":")` and borrow that to get a `str` 👌

# User-Facing Changes

# Tests + Formatting

# After Submitting
2023-09-29 19:12:46 +02:00
Carson Riker
d6b9153ac5
Fix Default Prompt Tilde Insertion Logic (#10539)
This pr closes #10521.

# Description

The default prompt by nushell will replace `$nu.home-path` with `~`.
E.g. for a user named `user`, `/home/user` would become `~`. This also
works with sub paths, e.g. `/home/user/docs` would become `~/docs`.

The issue is that this replacement was a tad overzealous. A path like
`/home/user-with-suffix` would become `~-with-suffix`. This PR fixes the
issue by updating the home path detection logic.

# User-Facing Changes

The bugged behavior no longer occurs.

# Tests + Formatting

* `cargo` checks were not performed as this does not touch rust.
* The updated logic was tested against
[elvish](https://github.com/elves/elvish)'s path replacement logic, for
~10,000 randomly selected folders on a linux server. All paths were
processed the same.
2023-09-29 16:40:51 +02:00
Faïz Hernawan
7ad4c679b3
Add kitty protocol config to nushell (#10540)
# Description

Support keyboard enhancement protocol as implemented by Kitty console,
hence Kitty protocol.

This PR enables Nushell to use keybinding that is not available before,
such as Ctrl+i (that alias to Tab) or Ctrl+e (that alias to Esc, likely
I mistaken). After this PR merged and you set `use_kitty_protocol`
enabled, if your console app support Kitty protocol (WezTerm, Kitty,
etc.) you will be able to set more fine-grained keybinding.

For Colemak users, this feature is a blessing, because some Ctrl+[hjkl]
that previously unmap-able to Ctlr+[hnei] now it is.

# User-Facing Changes

This adds `use_kitty_protocol` config which defaults to false. When set
to `true`, it enables kitty protocol on the line editor when supported,
or else it warns.


---------

Co-authored-by: Stefan Holderbach <sholderbach@users.noreply.github.com>
2023-09-29 15:52:34 +02:00
Reilly Wood
78d0e1d0b8
explore: highlight selected cell using background colour instead of cursor (#10533)
More incremental `explore` improvements!

This PR removes the `show_cursor` config from the `explore` command, in
favour of always using the background colour to highlight the selected
cell. I believe this is a better default and I'd like to remove the
`show_cursor` functionality entirely as part of the effort to simplify
`explore`.

The style for selected cells is still configurable. I went with light
blue for the default background colour, it looks OK to me.

## Before:

![Screenshot from 2023-09-27
08-51-03](https://github.com/nushell/nushell/assets/26268125/798636be-a4ea-467f-b852-c0e929e4aa9d)


## After:

![Screenshot from 2023-09-27
08-50-59](https://github.com/nushell/nushell/assets/26268125/c88662e7-05b5-42a7-bf30-b03c70fba79d)
2023-09-28 20:17:56 -05:00
1256-bits
ac7263d957
Change LS_COLORS to highlight .fb2 files as text documents (#10532)
close #10396
# Description
Change LS_COLORS variable to bring the highlighting for .fb2 files in
line with other types of text documents
### Before
![ls with current LS_COLORS](https://i.imgur.com/KL0nG2y.png)
### After
![ls with changed LS_COLORS](https://i.imgur.com/ZFcLVL3.png)
2023-09-28 19:33:14 +02:00
Yash Thakur
414216edfa
Transient prompt (#10391)
## Description

This PR uses environment variables to enable and set a transient prompt,
which lets you draw a different prompt once you've entered a command and
you've moved on to the next line. This is useful if you have a fancy
two-line prompt with a bunch of info about time and git status that you
don't really need in your scrollback buffer.

Here's a screenshot. You can see how my usual prompt has two lines and
would take up a lot more space if every past command also used the full
prompt, but reducing past prompts to `🚀` or `>` makes it take up less
space.

![image](https://github.com/nushell/nushell/assets/45539777/dde8d0f5-f95f-4529-9a14-b7919bd51126)

I added the following lines to my `env.nu` to get that rocket as the
prompt initially:
```nu
$env.TRANSIENT_PROMPT_COMMAND = {|| "" }
$env.TRANSIENT_PROMPT_INDICATOR = {|| open --raw "~/.prompt-indicator" }
$env.TRANSIENT_PROMPT_INDICATOR_VI_INSERT = $env.TRANSIENT_PROMPT_INDICATOR
```

## User-Facing Changes

If you want to change a segment of the prompt, set the corresponding
`TRANSIENT_PROMPT_*` variable.

<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->

## Problems/Things to Consider:
- The transient prompt clones the `Stack` at the very beginning of the
session and keeps that around. I'm not sure if that could cause
problems, but if so, it could probably take an `Arc<State>` instead.
- This isn't truly a problem, but now there's even more environment
variables, which is kinda annoying.
- There might be some performance issues with creating a new
`NushellPrompt` object and cloning the `Stack` for every segment of the
transient prompt. What's more, the transient prompt is added to the
`Reedline` object whether or not the user has enabled transient prompt,
so if there are indeed performance issues, simply disabling the
transient prompt won't help.
- Perhaps instead of a separate `TRANSIENT_PROMPT_INDICATOR_VI_INSERT`
and `TRANSIENT_PROMPT_INDICATOR_VI_NORMAL`, `TRANSIENT_PROMPT_INDICATOR`
could be used for both (if it exists). Insert and normal mode don't
really matter for previously entered commands.
2023-09-22 14:35:09 -05:00
Maxim Zhiburt
7cfd4d2cfa
nu-table: Add table option --abbreviated (#10399)
- Added `--abbreviated`/`-a` option
- Adedd `abbreviate_if_longer_than` config opt for it.

```nu
ls | table -a 3
```

```
╭───┬────────────────────┬──────┬───────────┬──────────────╮
│ # │        name        │ type │   size    │   modified   │
├───┼────────────────────┼──────┼───────────┼──────────────┤
│ 0 │ CODE_OF_CONDUCT.md │ file │   3.4 KiB │ 4 days ago   │
│ 1 │ CONTRIBUTING.md    │ file │  18.3 KiB │ 2 weeks ago  │
│ 2 │ Cargo.lock         │ file │ 144.3 KiB │ 15 hours ago │
│ 3 │ ...                │ ...  │ ...       │ ...          │
│ 4 │ tests              │ dir  │   4.0 KiB │ 4 months ago │
│ 5 │ toolkit.nu         │ file │  14.6 KiB │ 5 days ago   │
│ 6 │ wix                │ dir  │   4.0 KiB │ 2 months ago │
╰───┴────────────────────┴──────┴───────────┴──────────────╯
```

```nu
$env | table -a 3
```

```
╭──────────────────┬──────────────────────────────────────────────────────────────────────────╮
│ BROWSER          │ firefox                                                                  │
│ CARGO            │ /home/maxim/.rustup/toolchains/1.70.0-x86_64-unknown-linux-gnu/bin/cargo │
│ CARGO_HOME       │ /home/maxim/.cargo                                                       │
│ ...              │ ...                                                                      │
│ XDG_SESSION_TYPE │ x11                                                                      │
│ XDG_VTNR         │ 7                                                                        │
│ _                │ /home/maxim/.cargo/bin/cargo                                             │
╰──────────────────┴──────────────────────────────────────────────────────────────────────────╯
```

close #10393

PS: Maybe as a separate issue (good candidate for `GOOD FIRST ISSUE`)
add a config option to change a default `...` truncation sign to a
custom? (which would be applicable not only for `--abbreviated` but all
kind of tables)

---------

Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com>
2023-09-20 12:59:08 -05:00
Stefan Holderbach
af15f794b4
Bump to 0.85.1 development version (#10431) 2023-09-20 18:38:42 +12:00
Stefan Holderbach
a6f62e05ae
Bump version for the 0.85 release (#10425) 2023-09-19 21:42:47 +03:00
nibon7
7907dda8f7
Make cursor_shape optional (#10289)
# Description
There are several cursor shape related issues #7151 #9243 #7271 #8452
#10169, you can't disable the cursor shape feature even if you comment
out the entire `cursor_shape` block in the config.nu, and even worse,
when nushell exits with an error, the cursor shape can't be restored,
that is annoying.

This PR provides an opportunity to disable setting the cursor shape.

# User-Facing Changes
If you use the default config.nu, nothing changes, but if you comment
out `cursor_shape` block or set them to `inherit`, related cursor shape
will not be set.

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass (on Windows make
sure to [enable developer
mode](https://learn.microsoft.com/en-us/windows/apps/get-started/developer-mode-features-and-debugging))
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-09-09 13:42:36 -05:00
Darren Schroeder
2f47263380
respect a users locale with the right prompt (#10273)
# Description

This PR tries to respect a person's locale setting with date/time in the
default right prompt. This also restores the right prompt so that it
does not load from the US default from reedline.

closes https://github.com/nushell/nushell/issues/9924


Here's the fromat reference if anyone thinks there's a better time
format. I could be talked into `%c` maybe.
https://docs.rs/chrono/latest/chrono/format/strftime/index.html

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass (on Windows make
sure to [enable developer
mode](https://learn.microsoft.com/en-us/windows/apps/get-started/developer-mode-features-and-debugging))
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-09-08 12:24:42 -05:00
Reilly Wood
e62a77a885
Start removing colour config from explore (#10270)
This PR removes the `explore.try.border_color` config item, and instead
always uses the `separator` colour (the one used for regular table
borders) from the current theme.

The PR also removes some unused `explore.config` bits from the default
config (I missed this in https://github.com/nushell/nushell/pull/10259).

### Future Work

This PR is intentionally small, I want to confirm that I'm on the right
track before I rip out more colour config from `explore`. If all goes
well, expect more PRs like this soon.

### Testing

I confirmed that this works by changing my `separator` colour in
`config.nu`, and also confirmed that nothing breaks if a user still has
`explore.try.border_color` in their config.
2023-09-08 07:34:47 -07:00
Darren Schroeder
664dd291eb
Restore NU_LIB_DIRS and NU_PLUGIN_DIRS defaults (#10252)
# Description

This PR reverts some changes to NU_LIB_DIRS and NU_PLUGIN_DIRS in the
default_env.config file. Our practice is to have default configs that
match if you were to run `nu -n`. I agree with this goal, but until
someone adds NU_LIB_DIRS and NU_PLUGIN_DIRS, we should revert this
change and not penalize users, breaking their scripts that run with `nu
-c blah` when `blah` is located in the default_env's NU_LIB_DIRS.


# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass (on Windows make
sure to [enable developer
mode](https://learn.microsoft.com/en-us/windows/apps/get-started/developer-mode-features-and-debugging))
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-09-06 22:00:55 +02:00
Antoine Stevan
7486850357
rename the types with spaces in them to use - (#9929)
# Description
before this PR,
```nushell
> $.a.b | describe
cell path
```
which feels inconsistent with the `cell-path` type annotation, like in
```nushell
> def foo [x: cell-path] { $x | describe }; foo $.a.b
cell path
```

this PR changes the name of the "cell path" type from `cell path` to
`cell-path`

# User-Facing Changes
`cell path` is now `cell-path` in the output of `describe`.
this might be a breaking change in some scripts.

same goes with
- `list stream` -> `list-stream`
- `match pattern` -> `match-pattern`

# Tests + Formatting
- 🟢 `toolkit fmt`
- 🟢 `toolkit clippy`
-  `toolkit test`
-  `toolkit test stdlib`

this PR adds a new `cell_path_type` test to make sure it stays equal to
`cell-path` in the future.

# After Submitting

---------

Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com>
2023-09-06 13:22:12 -05:00
Antoine Stevan
fedd879b2e
support tab completion cycling (#10199)
should close https://github.com/nushell/nushell/issues/7202

# Description
i have been annoyed enough by this missing feature, so let's add that to
Nushell without requiring any user configuration 😏

# User-Facing Changes
this PR should allow tab completion cycling everytime, without requiring
the user to use the default config files or add the following
keybindings to their config
```nushell
    {
        name: completion_menu
        modifier: none
        keycode: tab
        mode: [emacs vi_normal vi_insert]
        event: {
            until: [
                { send: menu name: completion_menu }
                { send: menunext }
                { edit: complete }
            ]
        }
    }
```

### 🧪 try it out
from the root of the repo, one can try `<tab>` in each of the following
cases:
- `cargo run -- -n` to load Nushell without any config
- `cargo run -- --config
crates/nu-utils/src/sample_config/default_config.nu --env-config
crates/nu-utils/src/sample_config/default_env.nu` to load the default
configuration
- `cargo run` to load the user configuration

## before
- `<tab>`, `ls <tab>` and `str <tab>` only work with the second `cargo
run`, i.e. when loading the default config files

## after
- `<tab>` should cycle through the available commands
- `ls <tab>` should cycle through the available files and directories
- `str <tab>` should cycle the subcommands of `str`

in all three cases

# Tests + Formatting

# After submitting
2023-09-03 19:19:39 -05:00
Mach50
844f541719
changed default env file to use $nu.home_path to find home (#10192)
# Description
Changed the default env file so that home is found using `$nu.home-path`
instead to using an if-else statement to find the os then find the
specific environment variable
2023-09-02 09:00:10 -05:00
Joaquín Triñanes
cc805f3f01
Screen reader-friendly errors (#10122)
- Hopefully closes #10120  

# Description

This PR adds a new config item, `error_style`. It will render errors in
a screen reader friendly mode when set to `"simple"`. This is done using
`miette`'s own `NarratableReportHandler`, which seamlessly replaces the
default one when needed.

Before:
```
Error: nu:🐚:external_command

  × External command failed
   ╭─[entry #2:1:1]
 1 │ doesnt exist
   · ───┬──
   ·    ╰── executable was not found
   ╰────
  help: No such file or directory (os error 2)
```

After:
```
Error: External command failed
    Diagnostic severity: error
Begin snippet for entry #4 starting at line 1, column 1

snippet line 1: doesnt exist
    label at line 1, columns 1 to 6: executable was not found
diagnostic help: No such file or directory (os error 2)
diagnostic code: nu:🐚:external_command

```

## Things to be determined

- ~Review naming. `errors.style` is not _that_ consistent with the rest
of the code. Menus use a `style` record, but table rendering mode is set
via `mode`.~ As it's a single config, we're using `error_style` for now.
- Should this kind of setting be toggable with one single parameter?
`accessibility.no_decorations` or similar, which would adjust the style
of both errors and tables accordingly.

# User-Facing Changes

No changes by default, errors will be rendered differently if
`error_style` is set to `simple`.

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass (on Windows make
sure to [enable developer
mode](https://learn.microsoft.com/en-us/windows/apps/get-started/developer-mode-features-and-debugging))
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting

There's a PR updating the docs over here
https://github.com/nushell/nushell.github.io/pull/1026
2023-08-27 06:54:15 -05:00
Darren Schroeder
3d698b74d8
bump nushell to dev version 0.84.1 (#10101)
# Description

This PR bumps nushell from release version 0.84.0 to dev version 0.84.1.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used` to
check that you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-23 15:23:27 -05:00
JT
894e0f7658
bump to 0.84 (#10093) 2023-08-22 21:23:39 +03:00
JT
4a1b3e26ef
fix default-env after latest changes (#10052)
# Description

default env.nu is currently broken after the changes to `str replace`.
This PR should help fix it.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-19 07:39:36 +12:00
Maxim Zhiburt
aa37572ddc
nu-table/ Add table.indent configuration (#9983)
Hi there.

Am I got it right?

ref: https://github.com/zhiburt/tabled/issues/358
cc: @fdncred

---------

Signed-off-by: Maxim Zhiburt <zhiburt@gmail.com>
2023-08-11 08:37:16 -05:00
Darren Schroeder
6f5bd62a97
update strip-ansi-escapes to 0.2.0 and the latest reedline (#9970)
# Description

This PR fixes the semver issues with `strip-ansi-escapes` and updates it
to 0.2.0 as well as updating to the latest reedline which just landed an
identical patch.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-09 12:33:07 -05:00
Antoine Stevan
bb3cc9e153
fix the default config for explore (#9962)
according to
0674d4960b/crates/nu-explore/src/commands/table.rs (L132-L135)

the config should be called `$env.config.explore.table.show_cursor`
instead of the current `$env.config.explore.table.cursor` 😮

this PR fixes this in the default config.
2023-08-09 08:18:12 -05:00
Darren Schroeder
85c2035016
update strip-ansi-escapes to use new api (#9958)
# Description

This PR updates `strip-ansi-escapes` to support their new API. This also
updates nushell to the latest reedline after the same fix
https://github.com/nushell/reedline/pull/617

closes #9957 

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-08 15:20:37 -05:00
JT
839010b89d
Auto-expand table based on terminal width (#9934)
# Description

This PR adds back the functionality to auto-expand tables based on the
terminal width, using the logic that if the terminal is over 100 columns
to expand.

This sets the default config value in both the Rust and the default
nushell config.

To do so, it also adds back the ability for hooks to be strings of code
and not just code blocks.

Fixed a couple tests: two which assumed that the builtin display hook
didn't use a table -e, and one that assumed a hook couldn't be a string.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-08 05:47:23 -05:00
Darren Schroeder
066790552a
add keybinding for search-history (#9930)
# Description

This PR adds a keybinding in the rust code for `search-history` aka
reverse-search as `ctrl+q` so it does not overwrite `history-search`
with `ctrl+r` as it does now.

This PR supercedes #9862. Thanks to @SUPERCILEX for bringing this to our
attention.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-06 06:59:06 -05:00
Darren Schroeder
71b74a284a
add header_on_separator options to default_config.nu (#9922)
# Description

This PR adds the `header_on_separator` table option as `false` to the
`default_config.nu` file.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-05 07:24:20 +12:00
JT
572698bf3e
Re-align how prompt indicators work (#9907)
# Description

An extra space slipped into the config alignment PR, and this fixes that
extra space.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-04 07:33:47 +12:00
WindSoilder
14bf25da14
rename from date format to format date (#9902)
# Description
Closes: #9891
I also think it's good to keep command name consistency.

And moving `date format` to deprecated.

# User-Facing Changes
Running `date format` will lead to deprecate message:
```nushell
❯ "2021-10-22 20:00:12 +01:00" | date format
Error: nu:🐚:deprecated_command

  × Deprecated command date format
   ╭─[entry #28:1:1]
 1 │ "2021-10-22 20:00:12 +01:00" | date format
   ·                                ─────┬─────
   ·                                     ╰── 'date format' is deprecated. Please use 'format date' instead.
   ╰────
```
2023-08-04 06:06:00 +12:00
JT
840b4b854b
Simplify default style and match Rust code to config (#9900)
# Description

This PR aligns the default config in the Rust code to the default config
in the nushell file.

To do so, it removes closures from the default file, opting instead to
pick a simple style as default. This allows easier maintenance of both
Rust and Nushell code without removing the ability to use closures for
styling in your configuration.

The default theme is now "dark mode" in both the Rust and nushell config
code.

Obligatory screenshot:


![image](https://github.com/nushell/nushell/assets/547158/233b11af-3b81-4513-8a69-3e7b1cac3865)


# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-08-03 08:06:51 +12:00
Darren Schroeder
955de76116
bump to dev version 0.83.2 (#9866)
# Description

This PR bumps the development version of nushell to version 0.83.2.
2023-07-30 22:16:57 +02:00
Darren Schroeder
88a890c11f
bump to dev version 0.83.1 (#9811)
# Description

This bumps nushell to the dev version of 0.83.1 and updates the default
config files with the proper version.

# User-Facing Changes
# Tests + Formatting
# After Submitting
2023-07-26 19:02:13 +02:00
JT
a33b5fe6ce
bump to 0.83 (#9802)
# Description

Bump 0.83

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-07-26 07:36:36 +12:00
Stefan Holderbach
d7ebe5fdc3
Update nu-ansi-term, lscolors, and reedline (#9787)
# Description
Now use `nu-ansi-term` 0.49
Small adjustments to accommodate breaking changes.


# User-Facing Changes
None
2023-07-24 13:16:18 +02:00
Darren Schroeder
3b9a0ac7c6
change the default of history.isolation (#9762)
# Description

This PR just fixes the default value of history.isolation and adds a few
more comments. isolation isn't available in plaintext so it should be
defaulted to off/false.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-07-21 06:40:42 -05:00
Darren Schroeder
2d557bce5d
normalize default_config/env formatting (#9731)
# Description

This PR just tried to normalize the formatting. Everything should be 4
spaces now for those people that can't live with 2 spaces in the default
config files. I also remove some unneeded line breaks and changed two
places that should've been `edit` vs `send`.

# User-Facing Changes
<!-- List of all changes that impact the user experience here. This
helps us keep track of breaking changes. -->

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- -c "use std testing; testing run-tests --path
crates/nu-std"` to run the tests for the standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-07-19 06:49:21 -05:00
Antoine Stevan
345c00aa1e
sync default config / env with default behaviour without any configuration (#9676)
related PRs and issues
- supersedes https://github.com/nushell/nushell/pull/9633
- should close https://github.com/nushell/nushell/issues/9630

# Description
this PR updates the `default_config.nu` config file and the `config.rs`
module in `nu_protocol` so that the default behaviour of Nushell,
without any config, and the one with `default_config.nu` and
`default_env.nu` are the same.

## changelog
- 3e2bfc9bb: copy the structure of `default_config.nu` inside the
implementation of `Default` in the `config.rs` module for easier check
of the default values
- e25e5ccd6: sync all the *simple* config fields, i.e. the
non-structured ones
- ae7e8111c: set the `display_output` hook to always run `table`
- a09a1c564: leave only the default menus => i've removed
`commands_menu`, `vars_menu` and `commands_with_description`

## todo
- [x] ~~check the defaults in `$env.config.explore`~~ done in 173bdbba5
and b9622084c
- [x] ~~check the defaults in `$env.config.color_config`~~ done in
c411d781d => the theme is now `{}` by default so that it's the same as
the default one with `--no-config`
- [x] ~~check the defaults `$env.config.keybindings`~~ done in 715a69797
- already available with the selected mode: `completion_previous`,
`next_page`, `undo_or_previous_page`, `yank`, `unix-line-discard` and
`kill-line`, e.g. in *vi* mode, `unlix-line-discard` is done in NORMAL
mode with either `d0` from the end of the line or `dd` from anywhere in
the line and `kill-line` is done in NORMAL mode with `shift + d`. these
bindings are available by default in *emacs* mode as well.
- previously with removed custom menus: `commands_menu`, `vars_menu` and
`commands_with_description`
- [x] ~~check `$env.config.datetime_format`~~ done in 0ced6b8ec => as
there is no *human* format for datetimes, i've commented out both
`$env.config.datetime_format` fields
- [x] ~~fix `default_env.nu`~~ done in 67c215011

# User-Facing Changes
this should not change anything, just make sure the default behaviour of
Nushell and the `default_config.nu` are in sync.

# Tests + Formatting
# After Submitting
2023-07-18 11:22:00 -05:00
JT
7e39179b7f
Move to using a safer shell integration default setting (#9600)
# Description

We're seeing some issues in a few terminals with the shell integration
support. Moving shell_integration to off by default to help with the
default user experience, but it will remain easy to re-enable for folks
who want to have the integration experience and a terminal that supports
it well.

# User-Facing Changes

This turns off shell integration by default, requiring the user to edit
the config and re-enable it.

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- crates/nu-std/tests/run.nu` to run the tests for the
standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-07-04 06:26:49 +12:00
JT
7c80067900
use an easier-to-read date format in prompt (#9585)
# Description

Switches the right prompt to use an easier-to-read date format
(YYYY-MM-DD)

It's currently using (MM-DD-YYYY) which is only used in a few countries
but it is unfortunately ambiguous with countries that use (DD-MM-YYYY)
format (most countries). While YYYY-MM-DD is used in fewer countries
than DD-MM-YYYY it's at least unambiguous to MM-DD-YYYY countries.

More info: https://en.wikipedia.org/wiki/Date_format_by_country

Alternatively, we could spell out the month name (even abbreviated) to
make it clear as well.

# User-Facing Changes

Just changes the date in the default right prompt

# Tests + Formatting
<!--
Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect -A clippy::result_large_err` to check that
you're using the standard code style
- `cargo test --workspace` to check that all tests pass
- `cargo run -- crates/nu-std/tests/run.nu` to run the tests for the
standard library

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```
-->

# After Submitting
<!-- If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
-->
2023-07-02 20:25:22 +12:00