summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-10-01Simplify the Dockerfile (#13974)HEADmainJustin Ma
<!-- 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 Works for `docker build` and `docker buildx build` For more detail about the new Dockerfile syntax: https://www.docker.com/blog/new-dockerfile-capabilities-v1-7-0/
2024-10-01Make `SpanId` and `RegId` also use new ID struct (#13963)Piepmatz
# Description In the PR #13832 I used some newtypes for the old IDs. `SpanId` and `RegId` already used newtypes, to streamline the code, I made them into the same style as the other marker-based IDs. Since `RegId` should be a bit smaller (it uses a `u32` instead of `usize`) according to @devyn, I made the `Id` type generic with `usize` as the default inner value. The question still stands how `Display` should be implemented if even. # User-Facing Changes Users of the internal values of `RegId` or `SpanId` have breaking changes but who outside nushell itself even uses these? # After Submitting The IDs will be streamlined and all type-safe.
2024-09-30allow bools to be type checked with each other (#13968)Darren Schroeder
# Description This PR allows bools to be type checked against each other. ![image](https://github.com/user-attachments/assets/64dc36f8-59bc-4e66-8380-6b693c77a2d3) I looked for test and maybe we don't have any for type checked math stuff. I didn't see any. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-30nu-exlore/ Fix :try table view (#13964)Maxim Zhiburt
Must be addressed @fdncred But I would recheck. ![image](https://github.com/user-attachments/assets/657c4f63-62ae-413d-b6cc-90e918864e69) close #13957
2024-09-30update human-date-parser crate (#13962)Darren Schroeder
# Description closes https://github.com/nushell/nushell/issues/13759 and fixes some odd behavior from the human-date-parser crate. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-30a potential solution that may fix vt processing (#13961)Darren Schroeder
# Description This PR is related #11950 and serves as another potential fix alongside rolling it back with https://github.com/nushell/nushell/pull/13959. The idea here is to try and properly setup the input and output console modes. I searched through a log of GitHub code to come up with this, including deno, wezterm, conpty, among others. It seems to work but it would be great if someone else would be able to test. I added comments from the consoleapi.h from windows to know what the other flags are in case we need to make other changes. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-30Replace raw usize IDs with new types (#13832)Piepmatz
# Description In this PR I replaced most of the raw usize IDs with [newtypes](https://doc.rust-lang.org/rust-by-example/generics/new_types.html). Some other IDs already started using new types and in this PR I did not want to touch them. To make the implementation less repetitive, I made use of a generic `Id<T>` with marker structs. If this lands I would try to move make other IDs also in this pattern. Also at some places I needed to use `cast`, I'm not sure if the type was incorrect and therefore casting not needed or if actually different ID types intermingle sometimes. # User-Facing Changes Probably few, if you got a `DeclId` via a function and placed it later again it will still work.
2024-09-29Fix issue with `ls | explore` coloring of file names (#13952)Maxim Zhiburt
close #13936 The fix seem to be exactly what you've @fdncred described. But I'd recheck that everything is good. ![image](https://github.com/user-attachments/assets/5d9ce02b-9545-4a96-9718-b19d2e5810b8) Take care. Have a great week.
2024-09-27Fix panic on too few arguments for custom function (#10395)Andreas Källberg
# Description Old code was comparing remaining positional arguments with total number of arguments, where it should've compared remaining positional with with remaining arguments of any kind. This means that if a function was given too few arguments, `calculate_end_span` would believe that it actually had too many arguments, since after parsing the first few arguments, the number of remaining arguments needed were fewer than the *total* number of arguments, of which we had used several. Fixes #9072 Fixes: https://github.com/nushell/nushell/issues/13930 Fixes: https://github.com/nushell/nushell/issues/12069 Fixes: https://github.com/nushell/nushell/issues/8385 Extracted from #10381 ## Bonus It also improves the error handling on missing positional arguments before keywords (no longer crashing since #9851). Instead of just giving the keyword to the parser for the missing positional, we give an explicit error about a missing positional argument. I would like better descriptions than "missing var_name" though, but I'm not sure if that's available without Old error ``` Error: nu::parser::parse_mismatch × Parse mismatch during operation. ╭─[entry #1:1:1] 1 │ let = if foo · ┬ · ╰── expected valid variable name ╰──── ``` New error ``` Error: nu::parser::missing_positional × Missing required positional argument. ╭─[entry #18:1:1] 1 │ let = foo · ┬ · ╰── missing var_name ╰──── help: Usage: let <var_name> = <initial_value> ``` # User-Facing Changes The program `alias = = =` is no longer accepted by the parser
2024-09-27ensure toolkit is using external cargo command (#13943)Darren Schroeder
# Description @cptpiepmatz and I ran into a problem where `toolkit check pr` and `toolkit clippy --verbose` wouldn't work. I tracked it down to me using `cargo-completions.nu` out of the nu_scripts repo. It was redefining `cargo clippy`. The fix was to ensure that all `cargo` commands in `toolkit.nu` use the external `^cargo`. Specifically, the problem with `cargo clippy` in `cargo-completions.nu` is it didn't seem to allow `-- -D blah` type parameters. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-27Expose flag truncate-ragged-lines in `polars open` (#13939)Jack Wright
# Description Introduces a new flag `--truncate-ragged-lines` for `polars open` that will truncate lines that are longer than the schema. # User-Facing Changes - Introduction of the flag `--truncate-ragged-lines` for `polars open`
2024-09-27Added command `polars len` for performing count(*) like operations. (#13941)Jack Wright
# Description This request exposes the prelude::polars::len expression. It is ended for doing fast select count(*) like operations: <img width="626" alt="Screenshot 2024-09-26 at 18 14 45" src="https://github.com/user-attachments/assets/74285fc6-f99c-46e0-9226-9a7d41738d78"> # User-Facing Changes - Introduction of the `polars len` command
2024-09-26Only ask to create config files the first time nu is started (#13857)Douglas
# Description Implements #13669 When nu is started for the first time, the directory represented by `$nu.default-config-dir` typically will not exist. In this case, Nushell will create the directory. It will then detect that either or both `config.nu`/`env.nu` don't exist and offer to create them. (Existing behavior) If the user declines, the directory will still be created (since the history file lives there as well). The `default_config.nu` and `default_env.nu` will be loaded. On subsequent launches, as long as the config directory continues to exist, the user will not be prompted to recreate the config files. Nushell will behave as if the user answered "N" to the prompt in that `default_config.nu` and `default_env.nu` will be used. The user can still create a `config.nu` or `env.nu` at any point, and that will be used. In that case, `default_config.nu` and/or `default_env.nu` will no longer be loaded (unless and until #13671 is implemented). # User-Facing Changes User will no longer be prompted to create config files if they are missing so long as the config directory exists. ## Before this change: 1. Nushell starts for the first time 2. The directory where config files are stored does not exist 3. The config files do not exist * User is asked whether they want to create `env.nu` - User says, "Y", `default_env.nu` is copied to the directory as `env.nu` (and directory is created if needed) - User says, "n", `default_env.nu` is loaded, but no file on the filesystem is created. * User is asked whether they want to create `config.nu` - User says, "Y", `default_config.nu` is copied to the directory as `config.nu` (and directory is created if needed) - User says, "n", `default_config.nu` is loaded, but no file on the filesystem is created. 4. The next time `nu` is run, if either file is missing, the user will be prompted again for that file. ## After this change: Steps 1 - 3 remains the same. 4. The next time `nu` is run, we check if the directory exists. If so: 5. Do not prompt user to create any missing files **(New Behavior)** 6. `$nu.default-config-dir/env.nu` exists? * Yes? Use it. (Normal behavior) * No? Evaluate `default_env.nu`. (Normal behavior) * No file is created on the filesystem 7. `$nu.default-config-dir/config.nu` exists? * Yes? Use it. (Normal behavior) * No? Evaluate `default_config.nu` (Normal behavior) * No file is created on the filesystem # Tests + Formatting - :green_circle: `toolkit fmt` - :green_circle: `toolkit clippy` - :green_circle: `toolkit test` - :green_circle: `toolkit test stdlib` # After Submitting This behavior isn't currently mentioned in the configuration doc. I'll probably hold off on changing anything in the doc until #13671 is implemented. Regardless, given the timing, this won't make it into a release for at least 4 weeks.
2024-09-26Fix Docker image build failure (#13938)Saurabh Shinde
## Description While building the docker image under `nushell/docker` directory, following build failure observed. ![nushell-docker-error](https://github.com/user-attachments/assets/972048d7-b001-4325-b947-93e95b98f4d1) The problem here is the following lines of code that decide which `nushell` binary to download, extract, and install https://github.com/nushell/nushell/blob/main/docker/Dockerfile#L16-L19 The issue is especially with wildcard asterisk (*) which downloads both `amd64` and `arm64` binary while building. ## Fix Introduced build arg `TARGETARCH` which will be populated implicitly by docker `build/buildx` which will help us to decide which binary to download. ## User-Facing Changes None. ## Testing Details Tested building docker image on both `amd64` and `arm64` systems. **amd64/x86_64** ![nushell-docker-amd64](https://github.com/user-attachments/assets/ea30b7e3-0664-4a5b-bb13-4c18cdae2a31) **arm64** ![nushell-docker-arm64](https://github.com/user-attachments/assets/54e47051-1ee7-4695-bc6c-1e211532a545)
2024-09-26Bump rustix from 0.38.34 to 0.38.37 (#13878)Fredrik Fornwall
Notable this gets https://github.com/bytecodealliance/rustix/pull/1147 which makes things work on Android again. Without this update latest `0.98.0` release gets stuck in a loop outputting the below error due to the `TCGETS2` usage: > Error: Os { code: 13, kind: PermissionDenied, message: "Permission denied" }
2024-09-25fix ls_colors coloring in grid and ls (#13935)Darren Schroeder
# Description After PR https://github.com/nushell/nushell/pull/12953, LS_COLORS coloring broke in the `grid` and `ls` commands because the full path to the files were not available. This PR restores the coloring. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-25Set current working directory at startup (#12953)YizhePKU
This PR sets the current working directory to the location of the Nushell executable at startup, using `std::env::set_current_dir()`. This is desirable because after PR https://github.com/nushell/nushell/pull/12922, we no longer change our current working directory even after `cd` is executed, and some OS might lock the directory where Nushell started. The location of the Nushell executable is chosen because it cannot be removed while Nushell is running anyways, so we don't have to worry about OS locking it. This PR has the side effect that it breaks buggy command even harder. I'll keep this PR as a draft until these commands are fixed, but it might be helpful to pull this PR if you're working on fixing one of those bugs. --------- Co-authored-by: Devyn Cairns <devyn.cairns@gmail.com> Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com>
2024-09-25Respect `$env.config.use_kitty_protocol` in `input listen` (#13892)Bruce Weirdan
Fixes nushell/nushell#13891 # Description `input listen` now respects `$env.config.use_kitty_protocol` This is essentially a copy-paste from `keybindings listen` where it was already implemented. # User-Facing Changes `input listen` now respects `$env.config.use_kitty_protocol` # Tests + Formatting # After Submitting --------- Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com>
2024-09-25update folder_depth algorithm for glob command (#13915)Darren Schroeder
# Description This PR updates the `folder_depth` algorithm in order to make `glob` a bit faster. The algorithm works like this. Since `folder_depth` is always used we need to set it to a value. If the glob pattern contains `**` then make `folder_depth` `usize::MAX`. If `--depth` is not provided, make it 1, otherwise use the provided value. closes #13914 # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-25fix `inspect` and `explore` panics on empty records (#13893)Solomon
# Description Fixes a couple panics: ``` > {} | inspect Error: x Main thread panicked. |-> at crates/nu-command/src/debug/inspect_table.rs:87:15 `-> attempt to divide by zero ``` ``` > {} | explore # see an empty column, press Down Error: x Main thread panicked. |-> at crates/nu-explore/src/views/cursor/mod.rs:39:9 `-> attempt to subtract with overflow ``` # User-Facing Changes `{} | inspect` now outputs an empty table: ``` ╭─────────────┬────────╮ │ description │ record │ ├─────────────┴────────┤ │ │ ├──────────────────────┤ ``` `{} | explore` opens the help menu. Both match the empty list behavior. # Tests I'm not sure how to test `explore`, as it waits for interaction.
2024-09-25update the defaults for shell_integration (#13929)Darren Schroeder
# Description This PR updates the shell_integration defaults so that they work as described in default_config.nu even when there is no config.nu file. closes #13924 # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-25add binary as input to hash commands (#13923)Darren Schroeder
# Description This allows `hash sha256` to support binary input. The code was there but the signature wasn't. closes #13916
2024-09-25Bump actions-rust-lang/setup-rust-toolchain from 1.9.0 to 1.10.0 (#13922)dependabot[bot]
Bumps [actions-rust-lang/setup-rust-toolchain](https://github.com/actions-rust-lang/setup-rust-toolchain) from 1.9.0 to 1.10.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/actions-rust-lang/setup-rust-toolchain/releases">actions-rust-lang/setup-rust-toolchain's releases</a>.</em></p> <blockquote> <h2>v1.10.0</h2> <h2>What's Changed</h2> <ul> <li>Add new parameter cache-directories that is propagated to Swatinem/rust-cache (<a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/44">#44</a> by <a href="https://github.com/pranc1ngpegasus"><code>@​pranc1ngpegasus</code></a>)</li> <li>Add new parameter cache-key that is propagated to Swatinem/rust-cache as key (<a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/41">#41</a> by <a href="https://github.com/iainlane"><code>@​iainlane</code></a>)</li> <li>Make rustup toolchain installation more robust in light of planned changes <a href="https://redirect.github.com/rust-lang/rustup/issues/3635">rust-lang/rustup#3635</a> and <a href="https://redirect.github.com/rust-lang/rustup/pull/3985">rust-lang/rustup#3985</a></li> <li>Allow installing multiple Rust toolchains by specifying multiple versions in the toolchain input parameter.</li> <li>Configure the rustup override behavior via the new override input. (<a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/38">#38</a>)</li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/pranc1ngpegasus"><code>@​pranc1ngpegasus</code></a> made their first contribution in <a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/pull/44">actions-rust-lang/setup-rust-toolchain#44</a></li> <li><a href="https://github.com/iainlane"><code>@​iainlane</code></a> made their first contribution in <a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/pull/41">actions-rust-lang/setup-rust-toolchain#41</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/actions-rust-lang/setup-rust-toolchain/compare/v1...v1.10.0">https://github.com/actions-rust-lang/setup-rust-toolchain/compare/v1...v1.10.0</a></p> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/actions-rust-lang/setup-rust-toolchain/blob/main/CHANGELOG.md">actions-rust-lang/setup-rust-toolchain's changelog</a>.</em></p> <blockquote> <h1>Changelog</h1> <p>All notable changes to this project will be documented in this file.</p> <p>The format is based on <a href="https://keepachangelog.com/en/1.0.0/">Keep a Changelog</a>, and this project adheres to <a href="https://semver.org/spec/v2.0.0.html">Semantic Versioning</a>.</p> <h2>[Unreleased]</h2> <ul> <li>Add new parameter <code>cache-directories</code> that is propagated to <code>Swatinem/rust-cache</code> (<a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/44">#44</a> by <a href="https://github.com/pranc1ngpegasus"><code>@​pranc1ngpegasus</code></a>)</li> <li>Add new parameter <code>cache-key</code> that is propagated to <code>Swatinem/rust-cache</code> as <code>key</code> (<a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/41">#41</a> by <a href="https://github.com/iainlane"><code>@​iainlane</code></a>)</li> <li>Make rustup toolchain installation more robust in light of planned changes <a href="https://redirect.github.com/rust-lang/rustup/issues/3635">rust-lang/rustup#3635</a> and <a href="https://redirect.github.com/rust-lang/rustup/pull/3985">rust-lang/rustup#3985</a></li> <li>Allow installing multiple Rust toolchains by specifying multiple versions in the <code>toolchain</code> input parameter.</li> <li>Configure the <code>rustup override</code> behavior via the new <code>override</code> input. (<a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/38">#38</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/4d1965c9142484e48d40c19de54b5cba84953a06"><code>4d1965c</code></a> Add override input parameter that controls the <code>rustup override</code> behavior</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/b31b1317f290cc8743fce262ee98435b8c2a3c5a"><code>b31b131</code></a> Allow installing multiple Rust toolchains at once.</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/9f99923fade1f569928b687ccc2858a192effa02"><code>9f99923</code></a> Add pre-commit for basic checks</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/86a2ce66737229469494d3779ce1c99c3b5b351d"><code>86a2ce6</code></a> Make toolchain install more robust</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/eb4a655afde124c3ebbd7ddebd7ef287d56ac4d6"><code>eb4a655</code></a> Document new keys and add changelog</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/a90048dfddd1feb871e378c4535c05d7525117d4"><code>a90048d</code></a> Merge pull request <a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/41">#41</a> from iainlane/iainlane/propagate-cache-key</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/597574aacb4ee305cfa0c6a3ba38e8be6f9a2eb6"><code>597574a</code></a> Update key name in README</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/634cedf365286cb557a12970c1484ea71a309524"><code>634cedf</code></a> Merge pull request <a href="https://redirect.github.com/actions-rust-lang/setup-rust-toolchain/issues/44">#44</a> from pranc1ngpegasus/feat/able-to-cache-additional-dir...</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/5d6934e965a5457a045bd6a3327b3ce9dd0c6cbf"><code>5d6934e</code></a> Able to cache additional directories</li> <li><a href="https://github.com/actions-rust-lang/setup-rust-toolchain/commit/b01657d9bb1c81c4e7a46604980d19112a4034f0"><code>b01657d</code></a> Add support for adding to cache key</li> <li>See full diff in <a href="https://github.com/actions-rust-lang/setup-rust-toolchain/compare/v1.9.0...v1.10.0">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions-rust-lang/setup-rust-toolchain&package-manager=github_actions&previous-version=1.9.0&new-version=1.10.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-25Bump rustsec/audit-check from 1.4.1 to 2.0.0 (#13921)dependabot[bot]
Bumps [rustsec/audit-check](https://github.com/rustsec/audit-check) from 1.4.1 to 2.0.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/rustsec/audit-check/releases">rustsec/audit-check's releases</a>.</em></p> <blockquote> <h2>v2.0.0</h2> <h2>What's Changed</h2> <ul> <li>Run on Node 20.x by <a href="https://github.com/clechasseur"><code>@​clechasseur</code></a> in <a href="https://redirect.github.com/rustsec/audit-check/pull/16">rustsec/audit-check#16</a></li> <li>Remove <code>generate-lockfile</code> To Prevent Overwriting Checked-In Lock Files by <a href="https://github.com/tillmann-crabnebula"><code>@​tillmann-crabnebula</code></a> in <a href="https://redirect.github.com/rustsec/audit-check/pull/20">rustsec/audit-check#20</a></li> <li>Added support for <code>working-directory</code> by <a href="https://github.com/ranger-ross"><code>@​ranger-ross</code></a> in <a href="https://redirect.github.com/rustsec/audit-check/pull/21">rustsec/audit-check#21</a></li> <li>fix: security fix for vulnerability in <code>braces</code> library by <a href="https://github.com/clechasseur"><code>@​clechasseur</code></a> in <a href="https://redirect.github.com/rustsec/audit-check/pull/23">rustsec/audit-check#23</a></li> <li>npm audit fix by <a href="https://github.com/tarcieri"><code>@​tarcieri</code></a> in <a href="https://redirect.github.com/rustsec/audit-check/pull/24">rustsec/audit-check#24</a></li> <li>v2.0.0 release prep by <a href="https://github.com/tarcieri"><code>@​tarcieri</code></a> in <a href="https://redirect.github.com/rustsec/audit-check/pull/25">rustsec/audit-check#25</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/clechasseur"><code>@​clechasseur</code></a> made their first contribution in <a href="https://redirect.github.com/rustsec/audit-check/pull/16">rustsec/audit-check#16</a></li> <li><a href="https://github.com/tillmann-crabnebula"><code>@​tillmann-crabnebula</code></a> made their first contribution in <a href="https://redirect.github.com/rustsec/audit-check/pull/20">rustsec/audit-check#20</a></li> <li><a href="https://github.com/ranger-ross"><code>@​ranger-ross</code></a> made their first contribution in <a href="https://redirect.github.com/rustsec/audit-check/pull/21">rustsec/audit-check#21</a></li> <li><a href="https://github.com/tarcieri"><code>@​tarcieri</code></a> made their first contribution in <a href="https://redirect.github.com/rustsec/audit-check/pull/24">rustsec/audit-check#24</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/rustsec/audit-check/compare/v1.4.1...v2.0.0">https://github.com/rustsec/audit-check/compare/v1.4.1...v2.0.0</a></p> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/rustsec/audit-check/blob/main/CHANGELOG.md">rustsec/audit-check's changelog</a>.</em></p> <blockquote> <h1>Changelog</h1> <p>All notable changes to this project will be documented in this file.</p> <p>The format is based on <a href="https://keepachangelog.com/en/1.0.0/">Keep a Changelog</a>, and this project adheres to <a href="https://semver.org/spec/v2.0.0.html">Semantic Versioning</a>.</p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/rustsec/audit-check/commit/69366f33c96575abad1ee0dba8212993eecbe998"><code>69366f3</code></a> Prep for v2.0.0 release (<a href="https://redirect.github.com/rustsec/audit-check/issues/25">#25</a>)</li> <li><a href="https://github.com/rustsec/audit-check/commit/7b350a127d324d9632e9049c66527484ab8fbf63"><code>7b350a1</code></a> npm audit fix (<a href="https://redirect.github.com/rustsec/audit-check/issues/24">#24</a>)</li> <li><a href="https://github.com/rustsec/audit-check/commit/286a088f1cead63b54654692f8b045680f8f805f"><code>286a088</code></a> fix: update <code>@clechasseur/rs-actions-core</code> and other dependencies (<a href="https://redirect.github.com/rustsec/audit-check/issues/23">#23</a>)</li> <li><a href="https://github.com/rustsec/audit-check/commit/b7dc4ebf0c78ffba0982f75a53d230f48c2a76e9"><code>b7dc4eb</code></a> Added support for <code>working-directory</code> (<a href="https://redirect.github.com/rustsec/audit-check/issues/21">#21</a>)</li> <li><a href="https://github.com/rustsec/audit-check/commit/6dc762e8045bad20174b22deb6c2b6493ee7ae08"><code>6dc762e</code></a> update to latest upstream and rebuild (<a href="https://redirect.github.com/rustsec/audit-check/issues/20">#20</a>)</li> <li><a href="https://github.com/rustsec/audit-check/commit/fe0359b3e165e4d83e11ffab7715e56c43cc2d76"><code>fe0359b</code></a> Run on Node 20.x (<a href="https://redirect.github.com/rustsec/audit-check/issues/16">#16</a>)</li> <li><a href="https://github.com/rustsec/audit-check/commit/4da312dd0f2a5e6b58fecaec5b19e7271ce2ec5d"><code>4da312d</code></a> docs: Update repo link</li> <li><a href="https://github.com/rustsec/audit-check/commit/d6805b6463edcabb67093cf679d55a1770f03c9f"><code>d6805b6</code></a> docs: Bump version in README</li> <li>See full diff in <a href="https://github.com/rustsec/audit-check/compare/v1.4.1...v2.0.0">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rustsec/audit-check&package-manager=github_actions&previous-version=1.4.1&new-version=2.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-24Some small tweaks to release and nightly workflow (#13912)Justin Ma
<!-- 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 <!-- Thank you for improving Nushell. Please, check our [contributing guide](../CONTRIBUTING.md) and talk to the core team before making major changes. Description of your pull request goes here. **Provide examples and/or screenshots** if your changes affect the user experience. --> # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-24update reedline to the latest 660a5074 (#13909)Darren Schroeder
# Description This PR updates nushell to the latest reedline commit 660a5074 # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-24Add threads to the `ls` command in order to increase performance in some ↵Darren Schroeder
circumstances (#13836) # Description This PR tries to allow the `ls` command to use multiple threads if so specified. The reason why you'd want to use threads is if you notice `ls` taking a long time. The one place I see that happening is from WSL. I'm not sure how real-world this test is but you can see that this simple `ls` of a folder with length takes a while 9366 ms. I've run this test many times and it ranges from about 15 seconds to about 10 seconds. But with the `--threads` parameter, it takes less time, 2744ms in this screenshot. ![image](https://github.com/user-attachments/assets/e5c4afa2-7837-4437-8e6e-5d4bc3894ae1) The only way forward I could find was to _always_ use threading and adjust the number of threads based on if the user provides a flag. That seemed the easiest way to do it after applying @devyn's interleave advice. No feelings hurt if this doesn't land. It's more of an experiment but I think it has potential. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-24Support kitty key modifiers in keybindings (#13906)replcat
# Description hi hi, this makes the parsing of modifier key combos in config more general, and adds support for additional kitty keyboard protocol modifiers. It seems that support for [kitty keys](https://sw.kovidgoyal.net/kitty/keyboard-protocol) had already been added to nushell in https://github.com/nushell/nushell/pull/10540, and this was the only missing piece to making them available in keybindings. # User-Facing Changes - keybindings in config can include the super, hyper and meta modifiers (e.g. `modifier: super`, `modifier: shift_super`, etc.), and these modifiers will work in supporting terminals (kitty, foot, wezterm, alacritty...) - all permutations of snake_cased modifier combinations now behave equivalently for the purpose of describing keybindings in config (e.g. `control_alt_shift` was previously supported where `shift_control_alt` was a config error — now they're the same) # Tests None of this looks to be tested at the moment. I only found a smoke test under the nu-cli crate, and I couldn't break tests elsewhere by stuffing around with modifier handling. Works on my machine, though! ✨🌈
2024-09-24Fix handling of stopped TUI applications on unix (#13741)nome
# Description Instead of handling a foreground process being stopped in any way, we were simply ignoring SIGTSTP (which the terminal usually sends to the foreground process group when Ctrl-Z is pressed), and propagating this to our foreground children. This works for most processes, but it generally fails for applications which put the terminal in raw mode[1] and implement their own suspension mechanism (typically TUI apps like helix[2], neovim[3], top[4] or amp[5]). In these cases, triggering suspension within the app results in the terminal getting blocked, since the application is waiting for a SIGCONT, while nushell is waiting for it to exit. Fix this by unblocking SIGTSTP for our foreground children (neovim, helix and probably others send this to themselves while trying to suspend), and displaying the following message whenever one of them gets stopped: nushell currently does not support background jobs press any key to continue Pressing any key will then send SIGCONT to the child's process group and resume waiting. This fix is probably going to be superseded by a proper background job implementation (#247) at some point, but for now it's better than completely blocking the terminal. [1] https://docs.rs/crossterm/latest/crossterm/terminal/index.html#raw-mode [2] https://helix-editor.com/ [3] https://neovim.io/ [4] https://man7.org/linux/man-pages/man1/top.1.html [5] https://amp.rs/ - fixes #1038 - fixes #7335 - fixes #10335 # User-Facing Changes While any foreground process is running, Ctrl-Z is no longer ignored. Instead, the message described above is displayed, and nushell waits for a key to be pressed. # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-23Added command `polars profile` for profiling lazy dataframes (#13904)Jack Wright
# Description Introduce a new command `polars profile` for profiling lazy dataframes: <img width="965" alt="Screenshot 2024-09-22 at 23 46 18" src="https://github.com/user-attachments/assets/11402dd3-8256-43df-a986-64241c15354f"> # User-Facing Changes - Introduces new command `polars profile`
2024-09-23Add search terms to `into value` (#13890)Douglas
# Description From [Discord today](https://discord.com/channels/601130461678272522/729071784321876040/1286904159047778316), `into value` isn't classified with `conversions` like the other `into ...` subcommands. I think this is correct, since it's a `table->table` operation, so it's a filter that has the side effect of (potentially) converting (via inference) cell values. But we should at least have some search terms that help here, so this PR adds *"conversion"* and *"convert"* to the command. # User-Facing Changes `help -f conversion` will return `into value` # Tests + Formatting - :green_circle: `toolkit fmt` - :green_circle: `toolkit clippy` - :green_circle: `toolkit test` - :green_circle: `toolkit test stdlib` # After Submitting N/A
2024-09-23Removes more quotes on external command arguments (#13883)Wind
# Description Fixes: #13662 I don't think nushell need to parse and keep nested quote on external command arguments. Some nested quote is safe to removed. After the pr, nushell will behave more likely to bash. # User-Facing Changes #### Before ``` > ^echo {a:1,b:'c',c:'d'} {a:1,b:c',c:'d} ``` #### After ``` > ^echo {a:1,b:'c',c:'d'} {a:1,b:c,c:d} ``` # Tests + Formatting Added some tests to cover the behavior
2024-09-23Fix `try` not working with `let`, etc. (#13885)Ian Manske
# Description Partialy addresses #13868. `try` does not catch non-zero exit code errors from the last command in a pipeline if the result is assigned to a variable using `let` (or `mut`). This was fixed by adding a new `OutDest::Value` case. This is used when the pipeline is in a "value" position. I.e., it will be collected into a value. This ended up replacing most of the usages of `OutDest::Capture`. So, this PR also renames `OutDest::Capture` to `OutDest::PipeSeparate` to better fit the few remaining use cases for it. # User-Facing Changes Bug fix. # Tests + Formatting Added two tests.
2024-09-23Added `polars concat` to allow concatenation of multiple dataframes (#13879)Jack Wright
# Description Provides the ability to concatenate multiple dataframes together # User-Facing Changes - Introduces new command `polars concat`
2024-09-23fix the ability to add a plugin by name instead of path (#13877)Darren Schroeder
# Description This plugin fixes the ability to do `plugin add nu_plugin_polars` and have nushell look in NU_PLUGINS_DIR to find the plugin and add it. closes #13040 # 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 toolkit.nu; toolkit test stdlib"` 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. -->
2024-09-23view source: add content_type metadata (#13859)Bahex
# Description Add content type metadata to the output of `view source`. I've gone along with the mime type used [here][xdg], but this shouldn't be merged until there is consensus #13858. `to nuon`'s output has content type `application/x-nuon` [xdg]: https://gitlab.freedesktop.org/xdg/shared-mime-info/-/merge_requests/231 # User-Facing Changes Combined with `metadata access`, allows richer display_output hooks. Might be useful with other commands that make use of content_type like the `http` commands.
2024-09-23polars: add binary type support (#13830)Skyler Hawthorne
# Description This adds support for reading and writing binary types in the polars commands. The `BinaryOffset` type can be read into a Nushell native `Value` type no problem, but unfortunately this is a lossy conversion, as there's no Nushell-native semantic equivalent to the fixed size binary type in Arrow. # User-Facing Changes `polars open` and `polars save` now work with binary types.
2024-09-22Fix `do -p` not waiting for external commands (#13881)Ian Manske
# Description Similar to #13870 (thanks @WindSoilder), this PR adds a boolean which determines whether to ignore any errors from an external command. This is in order to fix #13876. I.e., `do -p` does not wait for externals to complete before continuing. # User-Facing Changes Bug fix. # Tests + Formatting Added a test.
2024-09-22Add loongarch64-unknown-linux-gnu-gcc build target (#13895)Justin Ma
# Description Add `loongarch64-unknown-linux-gnu-gcc` build target A test release could be found here: https://github.com/nushell/nightly/releases/tag/v0.98.1 Loongarch64 workflow build result: https://github.com/nushell/nightly/actions/runs/10973523602/job/30471006104
2024-09-22Bump crate-ci/typos from 1.24.5 to 1.24.6 (#13864)dependabot[bot]
Bumps [crate-ci/typos](https://github.com/crate-ci/typos) from 1.24.5 to 1.24.6. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/crate-ci/typos/releases">crate-ci/typos's releases</a>.</em></p> <blockquote> <h2>v1.24.6</h2> <h2>[1.24.6] - 2024-09-16</h2> <h3>Fixes</h3> <ul> <li>Respect negation (<code>!</code>) in <code>extend-exclude</code></li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/crate-ci/typos/blob/master/CHANGELOG.md">crate-ci/typos's changelog</a>.</em></p> <blockquote> <h2>[1.24.6] - 2024-09-16</h2> <h3>Fixes</h3> <ul> <li>Respect negation (<code>!</code>) in <code>extend-exclude</code></li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/crate-ci/typos/commit/8e6a4285bcbde632c5d79900a7779746e8b7ea3f"><code>8e6a428</code></a> chore: Release</li> <li><a href="https://github.com/crate-ci/typos/commit/cab7c3c4a5689885b27532e5abfc2396c9115417"><code>cab7c3c</code></a> docs: Update changelog</li> <li><a href="https://github.com/crate-ci/typos/commit/c4a659223979f6ca192e71e3ea7147e0cf9b225c"><code>c4a6592</code></a> Merge pull request <a href="https://redirect.github.com/crate-ci/typos/issues/1100">#1100</a> from epage/invert</li> <li><a href="https://github.com/crate-ci/typos/commit/ad3538f7199c880c450a1ea0b5b465c187cece5c"><code>ad3538f</code></a> refactor(cli): Switch from Overrides to Gitignore</li> <li><a href="https://github.com/crate-ci/typos/commit/d9b55f966cbffa8e201ffa525cadfc608938b3d0"><code>d9b55f9</code></a> fix(cli): Allow negative expressions in extend-exclude</li> <li><a href="https://github.com/crate-ci/typos/commit/777cf42dc2d133b4dd91f2ec52cdd7347f9c3d74"><code>777cf42</code></a> refactor(cli): Be explicit in overrides</li> <li><a href="https://github.com/crate-ci/typos/commit/0e8148fbbdfdf4412219b962474ebd9672c6bc24"><code>0e8148f</code></a> test(cli): Show inverted extend-exclude behavior</li> <li>See full diff in <a href="https://github.com/crate-ci/typos/compare/v1.24.5...v1.24.6">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=crate-ci/typos&package-manager=github_actions&previous-version=1.24.5&new-version=1.24.6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-22Bump shadow-rs from 0.34.0 to 0.35.0 (#13863)dependabot[bot]
Bumps [shadow-rs](https://github.com/baoyachi/shadow-rs) from 0.34.0 to 0.35.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/baoyachi/shadow-rs/releases">shadow-rs's releases</a>.</em></p> <blockquote> <h2>v0.35.0</h2> <h2>What's Changed</h2> <ul> <li>Update time crate by <a href="https://github.com/diniamo"><code>@​diniamo</code></a> in <a href="https://redirect.github.com/baoyachi/shadow-rs/pull/182">baoyachi/shadow-rs#182</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/diniamo"><code>@​diniamo</code></a> made their first contribution in <a href="https://redirect.github.com/baoyachi/shadow-rs/pull/182">baoyachi/shadow-rs#182</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/baoyachi/shadow-rs/compare/v0.34.0...v0.35.0">https://github.com/baoyachi/shadow-rs/compare/v0.34.0...v0.35.0</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/baoyachi/shadow-rs/commit/4358b4a0949fc50e50860ee625bc4dbfdc79166a"><code>4358b4a</code></a> Update Cargo.toml</li> <li><a href="https://github.com/baoyachi/shadow-rs/commit/2851d669dd3b9caaabbf2ec4f87f46c67a642712"><code>2851d66</code></a> Merge pull request <a href="https://redirect.github.com/baoyachi/shadow-rs/issues/182">#182</a> from diniamo/update-time</li> <li><a href="https://github.com/baoyachi/shadow-rs/commit/e77dcef733ddf5f9e2fe1e44ba949073d8e531a3"><code>e77dcef</code></a> Update time crate</li> <li>See full diff in <a href="https://github.com/baoyachi/shadow-rs/compare/v0.34.0...v0.35.0">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=shadow-rs&package-manager=cargo&previous-version=0.34.0&new-version=0.35.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-22Bump unicode-segmentation from 1.11.0 to 1.12.0 (#13862)dependabot[bot]
Bumps [unicode-segmentation](https://github.com/unicode-rs/unicode-segmentation) from 1.11.0 to 1.12.0. <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/9e3f88c06ca275294ef4cb1daf0789f06a28611d"><code>9e3f88c</code></a> Publish 1.12</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/187d8b8e848b202914c13d574241a9f7219a0ae7"><code>187d8b8</code></a> Support Unicode 16.0.0 (<a href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/140">#140</a>)</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/0f55f70b445202fd9d3c101b9936e6649e808441"><code>0f55f70</code></a> Fix unwrap panic in next_boundary() (<a href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/137">#137</a>)</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/0fa7148d3bfd1b1e35e942b27f8c86d460bae896"><code>0fa7148</code></a> Merge pull request <a href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/138">#138</a> from cardigan1008/issue-overflow</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/164f787b72d044562103cd4edb2027f321d032b8"><code>164f787</code></a> fmt</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/cbb87720d2a32eefdb0a7e18184deab2727d6d2e"><code>cbb8772</code></a> fix: arithmetic overflow</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/2081c29df7cf131341f01adfeb4ba1e8c68661c4"><code>2081c29</code></a> Merge pull request <a href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/136">#136</a> from Jules-Bertholet/std-tables</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/e96ec2eb6c099b8439570d6ae8cc4343d0bc59f1"><code>e96ec2e</code></a> Use stdlib alphabetic and numeric character tables</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/592ce00a3f90d521f18ce325b9641fcd30794c21"><code>592ce00</code></a> Merge pull request <a href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/134">#134</a> from Jules-Bertholet/fix</li> <li><a href="https://github.com/unicode-rs/unicode-segmentation/commit/dce3a345cc5bdda1dd70438c1b85f733460f6a67"><code>dce3a34</code></a> Add comments to <code>handle_incb_consonant</code></li> <li>Additional commits viewable in <a href="https://github.com/unicode-rs/unicode-segmentation/compare/v1.11.0...v1.12.0">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=unicode-segmentation&package-manager=cargo&previous-version=1.11.0&new-version=1.12.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-22Bump tango-bench from 0.5.0 to 0.6.0 (#13861)dependabot[bot]
Bumps [tango-bench](https://github.com/bazhenov/tango) from 0.5.0 to 0.6.0. <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/bazhenov/tango/commit/425ddb93be2d7a4c7a9ead35b984aed381ee9b50"><code>425ddb9</code></a> v0.6.0</li> <li><a href="https://github.com/bazhenov/tango/commit/0da1bf5f3908ab4208bb809e702f56307c63b483"><code>0da1bf5</code></a> Fixing incorrect path to gnuplot graph</li> <li><a href="https://github.com/bazhenov/tango/commit/6b084ea1896689de0ce65ff68688bd6dfa58f0be"><code>6b084ea</code></a> Limit visibility of internal type</li> <li><a href="https://github.com/bazhenov/tango/commit/4ea09e22160bb40bdfa55863cac5ef2a6feb07e7"><code>4ea09e2</code></a> Solo support (<a href="https://redirect.github.com/bazhenov/tango/issues/35">#35</a>)</li> <li><a href="https://github.com/bazhenov/tango/commit/abd888cbc02dd68a620ee0c84738f1d1783475d8"><code>abd888c</code></a> toolchain file added</li> <li><a href="https://github.com/bazhenov/tango/commit/2d722474ff47b4eb015117026ddc6a1a7e419eba"><code>2d72247</code></a> Async poc (dev-branch) (<a href="https://redirect.github.com/bazhenov/tango/issues/34">#34</a>)</li> <li><a href="https://github.com/bazhenov/tango/commit/5e236aec24f93f7cc7166977119566fefac04245"><code>5e236ae</code></a> Simplify code</li> <li><a href="https://github.com/bazhenov/tango/commit/40569a9c98b3d937444f30ff7ba5eb228b3b01bf"><code>40569a9</code></a> Documentation added</li> <li><a href="https://github.com/bazhenov/tango/commit/5908909fb219251edb76dce1c999c61b5390aa78"><code>5908909</code></a> README updated</li> <li><a href="https://github.com/bazhenov/tango/commit/6fb1ebd6f692d2d6da8344f3a7bad4655a6cb714"><code>6fb1ebd</code></a> Gnuplot support (<a href="https://redirect.github.com/bazhenov/tango/issues/33">#33</a>)</li> <li>Additional commits viewable in <a href="https://github.com/bazhenov/tango/compare/v0.5.0...v0.6.0">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tango-bench&package-manager=cargo&previous-version=0.5.0&new-version=0.6.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-22Bump version to 0.98.1 (#13896)Wind
2024-09-18Bump version to `0.98.0` (#13865)0.98.0Devyn Cairns
2024-09-16Improved null handling when converting from nu -> dataframe. (#13855)Jack Wright
# Description Fixes: #12726 and #13185 Previously converting columns that contained null caused polars to force a dtype of object even when using a schema. Now: 1. When using a schema, the type the schema defines for the column will always be used. 2. When a schema is not used, the previous type is used when a value is null. # User-Facing Changes - The type defined by the schema we be respected when passing in a null value `[a]; [null] | polars into-df -s {a: str}` will create a df with an str dtype column with one null value versus a column of type object. - *BREAKING CHANGE* If you define a schema, all columns must be in the schema.
2024-09-15Make IR the default evaluator (#13718)Devyn Cairns
# Description Makes IR the default evaluator, in preparation to remove the non-IR evaluator in a future release. # User-Facing Changes * Remove `NU_USE_IR` option * Add `NU_DISABLE_IR` option * IR is enabled unless `NU_DISABLE_IR` is set # After Submitting - [ ] release notes
2024-09-15catch unwrap on panics with `polars collect` (#13850)Jack Wright
# Description This resurrects the work from #12866 and fixes #12732. Polars panics for a plethora or reasons. While handling panics is generally frowned upon, in cases like with `polars collect` a panic cause a lot of work to be lost. Often you might have multiple dataframes in memory and you are trying one operation and lose all state. While it possible the panic can leave things a strange state, it is pretty unlikely as part of a polars pipeline. Most of the time polars objects are not manipulating dataframes in memory mutability, but rather creating a new dataframe the operations being applied. This is always the case with a lazy pipeline. After the collect call, the original dataframes are intact still and I haven't observed any side effects.
2024-09-15Fix dockerfile and reset Nu config to default (#13851)Justin Ma
<!-- 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 Fix dockerfile and reset Nu config to default, fetching config file from the remote may cause compatible issues
2024-09-14allow tab to be retained with `find` (#13848)Darren Schroeder
# Description This PR allows the tab character to be retained when using `find`. ### Before ![image](https://github.com/user-attachments/assets/92d78f55-58fb-42f4-be8f-82992292c900) ### After ![image](https://github.com/user-attachments/assets/fbd8e47f-9806-4e30-89a1-6c88b12a612c) closes #13846 # 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 toolkit.nu; toolkit test stdlib"` 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. -->