mirror of
https://github.com/nushell/nushell.git
synced 2024-12-24 16:09:11 +01:00
74dcac3b0d
1071 Commits
Author | SHA1 | Message | Date | |
---|---|---|---|---|
Stefan Holderbach
|
57510f2fd2
|
Move CLI related commands to nu-cli (#8832)
# Description Part of the larger cratification effort. Moves all `reedline` or shell line editor specific commands to `nu-cli`. ## From `nu-cmd-lang`: - `commandline` - This shouldn't have moved there. Doesn't directly depend on reedline but assumes parts in the engine state that are specific to the use of reedline or a REPL ## From `nu-command`: - `keybindings` and subcommands - `keybindings default` - `keybindings list` - `keybindings listen` - very `reedline` specific - `history` - needs `reedline` - `history session` ## internal use Instead of having a separate `create_default_context()` that calls `nu-command`'s `create_default_context()`, I added a `add_cli_context()` that updates an `EngineState` # User-Facing Changes None ## Build time comparison `cargo build --timings` from a `cargo clean --profile dev` ### total main: 64 secs this: 59 secs ### `nu-command` build time branch | total| codegen | fraction ---|---|---|--- main | 14.0s | 6.2s | (44%) this | 12.5s | 5.5s | (44%) `nu-cli` depends on `nu-command` at the moment. Thus it is built during the code-gen phase of `nu-command` (on 16 virtual cores) # Tests + Formatting I removed the `test_example()` facilities for now as we had not run any of the commands in an `Example` test and importing the right context for those tests seemed more of a hassle than the duplicated `test_examples()` implementations in `nu-cmd-lang` and `nu-command` |
||
Michael Angerman
|
60e6ea5abd
|
remove nu_cli crate dependency from nu_std (#8807)
now nu_std only depends on nu_parser, nu_protocol and miette and removes the nu_cli dependency this enables developers moving forward to come along and implement their own CLI's without having to pull in a redundant nu-cli which will not be needed for them. I did this by moving report_error into nu_protocol which nu_std already has a dependency on anyway.... - `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` 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.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 > ``` |
||
Antoine Stevan
|
5d8bedfbe4
|
stdlib: make the library a standalone crate (#8770)
# Description as we now have a prelude thanks to #8627, i'd like to work on the structure of the library 😋 and i think the first step is to make it a true standalone crate 😏 this PR - moves all the library from `crates/nu-utils/standard_library/` to `crates/nu-std/` - moves the `rust` loading code from `src/run.rs` to `crates/nu-std/src/lib.rs` |
||
Bob Hyman
|
771e24913d
|
range operator accepts bot..=top as well as bot..top (#8382)
# Description A compromise fix for #8162. Nushell range operator now accepts `..=` to mean the range includes the top value, so you can use your Rust habits. But the unadorned `..` range operator also includes the value, so you can also use your Nushell habits. _(Description of your pull request goes here. **Provide examples and/or screenshots** if your changes affect the user experience.)_ ```nushell 〉1..5 ╭───┬───╮ │ 0 │ 1 │ │ 1 │ 2 │ │ 2 │ 3 │ │ 3 │ 4 │ │ 4 │ 5 │ ╰───┴───╯ -------------------------------------------- /home/bobhy/src/rust/nushell -------------------------------------------- 〉1..=5 ╭───┬───╮ │ 0 │ 1 │ │ 1 │ 2 │ │ 2 │ 3 │ │ 3 │ 4 │ │ 4 │ 5 │ ╰───┴───╯ -------------------------------------------- /home/bobhy/src/rust/nushell -------------------------------------------- 〉1..<5 ╭───┬───╮ │ 0 │ 1 │ │ 1 │ 2 │ │ 2 │ 3 │ │ 3 │ 4 │ ╰───┴───╯ ``` # User-Facing Changes Existing scripts with range operator will continue to operate as heretofore. _(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: - [x] `cargo fmt --all -- --check` to check standard code formatting (`cargo fmt --all` applies these changes) - [x] `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A clippy::needless_collect` to check that you're using the standard code style - [x] `cargo test --workspace` to check that all tests pass # After Submitting Will update the book to include new syntax. |
||
dependabot[bot]
|
a29b61bd4f
|
Bump miette from 5.6.0 to 5.7.0 (#8720) | ||
dependabot[bot]
|
7c6ea81dd4
|
Bump tempfile from 3.4.0 to 3.5.0 (#8719)
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.4.0 to 3.5.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/Stebalien/tempfile/blob/master/NEWS">tempfile's changelog</a>.</em></p> <blockquote> <h1>3.5.0</h1> <ul> <li>Update rustix from 0.36 to 0.37.1. This makes wasi work on rust stable</li> <li>Update <code>windows-sys</code>, <code>redox_syscall</code></li> <li>BREAKING: Remove the implementation of <code>Write for &NamedTempFile<F> where &F: Write</code>. Unfortunately, this can cause compile issues in unrelated code (<a href="https://redirect.github.com/Stebalien/tempfile/issues/224">Stebalien/tempfile#224</a>).</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/Stebalien/tempfile/commits">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tempfile&package-manager=cargo&previous-version=3.4.0&new-version=3.5.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 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> |
||
dependabot[bot]
|
3509bde1a9
|
Bump windows from 0.46.0 to 0.48.0 (#8721)
Bumps [windows](https://github.com/microsoft/windows-rs) from 0.46.0 to 0.48.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/microsoft/windows-rs/releases">windows's releases</a>.</em></p> <blockquote> <h2>0.48.0</h2> <p>This release includes an update to all crates to address a target version reliability issue. This issue is detailed here: <a href="https://redirect.github.com/microsoft/windows-rs/issues/2410#issuecomment-1490802715">microsoft/windows-rs#2410</a></p> <h2>What's Changed</h2> <ul> <li>Improve target version reliability by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2412">microsoft/windows-rs#2412</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/microsoft/windows-rs/compare/0.47.0...0.48.0">https://github.com/microsoft/windows-rs/compare/0.47.0...0.48.0</a></p> <h2>0.47.0</h2> <p>As a reminder, updates are only published by request (<a href="https://redirect.github.com/microsoft/windows-rs/issues/2397">#2397</a>; <a href="https://redirect.github.com/microsoft/win32metadata/issues/1507">microsoft/win32metadata#1507</a>). This release provides an update to the <code>windows</code> crate. It does not include an update to the <code>windows-sys</code> crate.</p> <p>This update adds support for standalone code generation (<a href="https://redirect.github.com/microsoft/windows-rs/issues/2396">#2396</a>) as well as requested fixes to the Win32 metadata that prevented some APIs from being used.</p> <h2>What's Changed</h2> <ul> <li>Workaround for <code>rustdoc</code> regression by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2381">microsoft/windows-rs#2381</a></li> <li>Token privilege samples by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2382">microsoft/windows-rs#2382</a></li> <li>Apply <code>const</code> parameter metadata by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2384">microsoft/windows-rs#2384</a></li> <li>Advanced metadata filtering by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2385">microsoft/windows-rs#2385</a></li> <li>Update Win32 metadata v46 by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2387">microsoft/windows-rs#2387</a></li> <li>Support standalone code generation by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2396">microsoft/windows-rs#2396</a></li> <li>Update readme to include <code>windows-targets</code> and <code>windows-bindgen</code> by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2399">microsoft/windows-rs#2399</a></li> <li>Update Win32 metadata v47 by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2400">microsoft/windows-rs#2400</a></li> <li>Version 0.47.0 by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2401">microsoft/windows-rs#2401</a></li> <li>Add CLR test for lib validation by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2403">microsoft/windows-rs#2403</a></li> <li>Restore reproducible libs by <a href="https://github.com/riverar"><code>@riverar</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2402">microsoft/windows-rs#2402</a></li> <li>Check diff for all targets by <a href="https://github.com/kennykerr"><code>@kennykerr</code></a> in <a href="https://redirect.github.com/microsoft/windows-rs/pull/2404">microsoft/windows-rs#2404</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/microsoft/windows-rs/compare/0.46.0...0.47.0">https://github.com/microsoft/windows-rs/compare/0.46.0...0.47.0</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
JT
|
56efbd7de9
|
Add IDE support (#8745)
# Description This adds a set of new flags on the `nu` binary intended for use in IDEs. Here is the set of supported functionality so far: * goto-def - go to the definition of a variable or custom command * type hints - see the inferred type of variables * check - see the errors in the document (currently only one error is supported) * hover - get information about the variable or custom command * complete - get a completion list at the current position # User-Facing Changes No changes to the REPL experience. This only impacts the IDE scenario. # 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass - `cargo run -- crates/nu-utils/standard_library/tests.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. --------- Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com> |
||
dependabot[bot]
|
91282d4404
|
Bump git2 from 0.16.1 to 0.17.0 (#8722) | ||
dependabot[bot]
|
398976e43e
|
Bump spin from 0.9.5 to 0.9.8 (#8730)
Bumps [spin](https://github.com/mvdnes/spin-rs) from 0.9.5 to 0.9.8. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/mvdnes/spin-rs/blob/master/CHANGELOG.md">spin's changelog</a>.</em></p> <blockquote> <h1>[0.9.8] - 2023-04-03</h1> <h3>Fixed</h3> <ul> <li>Unsoundness in <code>Once::try_call_once</code> caused by an <code>Err(_)</code> result</li> </ul> <h1>[0.9.7] - 2023-03-27</h1> <h3>Fixed</h3> <ul> <li>Relaxed accidentally restricted <code>Send</code>/<code>Sync</code> bounds for <code>Mutex</code> guards</li> </ul> <h1>[0.9.6] - 2023-03-13</h1> <h3>Fixed</h3> <ul> <li>Relaxed accidentally restricted <code>Send</code>/<code>Sync</code> bounds for <code>RwLock</code> guards</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/mvdnes/spin-rs/commits">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=spin&package-manager=cargo&previous-version=0.9.5&new-version=0.9.8)](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 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) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/nushell/nushell/network/alerts). </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
Stefan Holderbach
|
d18cf19a3f
|
Bump to 0.78.1 development version (#8741)
# Description either just development or hotfix |
||
Stefan Holderbach
|
2ec2028637
|
Bump version to 0.78.0 (#8715)
# Description Version bump for the `0.78.0` Start to include the version with our `default_config.nu` and `default_env.nu` # Checklist - [x] reedline - [ ] release notes |
||
Stefan Holderbach
|
b84a01cb1d
|
Pin reedline to 0.18.0 release (#8728)
# Description see release notes: https://github.com/nushell/reedline/releases/tag/v0.18.0 |
||
Stefan Holderbach
|
68d98fcf24
|
Remove unused atty dep in nu-table (#8716)
# Description nfm |
||
Stefan Holderbach
|
3bf5999ef4
|
Remove proptest s for nuon writing/parsing (#8688)
# Description The two tests `to_nuon_from_nuon` and `to_nuon_from_nuon_string` were taking multiple seconds and have since been superseded by more explicit unit tests. Compared to the time cost for devs and CI they seldomly returned explicit problems. One failure only popped up after months, as a sampled failure (https://github.com/nushell/nushell/pull/7564). # User-Facing Changes none # Tests + Formatting Fuzzing should move to a separate worker and be removed from the main test suite. See #8575 for experimentation around the impact on our test coverage. |
||
dependabot[bot]
|
ad4450f9e8
|
Bump openssl from 0.10.45 to 0.10.48 (#8606) | ||
dependabot[bot]
|
4a1d12462f
|
Bump miette from 5.5.0 to 5.6.0 (#8531)
Bumps [miette](https://github.com/zkat/miette) from 5.5.0 to 5.6.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/zkat/miette/blob/main/CHANGELOG.md">miette's changelog</a>.</em></p> <blockquote> <h2>5.6.0 (2023-03-14)</h2> <h3>Bug Fixes</h3> <ul> <li><strong>ci:</strong> configure clippy-specific MSRV (<a href=" |
||
Darren Schroeder
|
47d6a66fbf
|
use reedline main branch (#8580)
# Description This PR forces nushell to use the reedline main branch instead of the published crate so that we can test the changes in the latest reedline main branch. # 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass > **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. |
||
Jérémy Audiger
|
0f4a073eaf
|
Remove once_cell dependency from nu-test-support create. (#8568)
I was looking where we could remove the usage of once-cell dependency. As for now, I only found one place. Not a terrible improvement, but at least, it removes a dependency nu-test-support crate. Relies on `Mutex::new` constified in Rust 1.63.0 |
||
dependabot[bot]
|
a193b85123
|
Bump alphanumeric-sort from 1.4.4 to 1.5.0 (#8532) | ||
dependabot[bot]
|
0f40c44ed2
|
Bump windows from 0.44.0 to 0.46.0 (#8535) | ||
dependabot[bot]
|
b0be6c3013
|
Bump quick-xml from 0.27.1 to 0.28.1 (#8533) | ||
dependabot[bot]
|
9c6bfc0be9
|
Bump rstest from 0.16.0 to 0.17.0 (#8534) | ||
Steven Xu
|
1d3f6105f5
|
feat: add a command_not_found hook (#8314)
# Description Add a `command_not_found` function to `$env.config.hooks`. If this function outputs a string, then it's included in the `help`. An example hook on *Arch Linux*, to find packages that contain the binary, looks like: ```nushell let-env config = { # ... hooks: { command_not_found: { |cmd_name| ( try { let pkgs = (pkgfile --binaries --verbose $cmd_name) ( $"(ansi $env.config.color_config.shape_external)($cmd_name)(ansi reset) " + $"may be found in the following packages:\n($pkgs)" ) } catch { null } ) } # ... ``` # User-Facing Changes - Add a `command_not_found` function to `$env.config.hooks`. # 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass # 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. |
||
JT
|
2d41613039
|
bump to 0.77.2 (#8496)
# 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 -A clippy::needless_collect` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass > **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. |
||
Steven Xu
|
b2a557d4ed
|
fix: fix commandline when called with no arguments (#8207)
# Description This fixes the `commandline` command when it's run with no arguments, so it outputs the command being run. New line characters are included. This allows for: - [A way to get current command inside pre_execution hook · Issue #6264 · nushell/nushell](https://github.com/nushell/nushell/issues/6264) - The possibility of *Atuin* to work work *Nushell*. *Atuin* hooks need to know the current repl input before it is run. # User-Facing 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass # 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. |
||
dependabot[bot]
|
2579a827fc
|
Bump mockito from 0.32.5 to 1.0.0 (#8426)
Bumps [mockito](https://github.com/lipanski/mockito) from 0.32.5 to 1.0.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/lipanski/mockito/releases">mockito's releases</a>.</em></p> <blockquote> <h2>1.0.0</h2> <p>🎈 7 years and 63 releases later, it's finally time for the 1.0 🎈</p> <h2>Changes</h2> <ul> <li><strong>[Breaking]</strong> The legacy interface was removed in this version</li> <li><strong>[Breaking]</strong> <code>Mock::with_body_from_fn</code> was renamed to <code>Mock::with_chunked_body</code> - the former is still supported with a deprecation warning</li> <li>Mocks are only cleared when the server is dropped, not when the mock is dropped - this means you <strong>don't have to assign mocks to variables any more</strong> (unless you want to call other methods on them)</li> <li>Introduced the <code>Mock::remove</code> and <code>Mock::remove_async</code> methods to remove mocks on demand</li> </ul> <h2>Major changes since 0.31</h2> <ul> <li>Tests can now run in parallel</li> <li>Support for HTTP2</li> <li>An async interface for all actions (though the sync interface is also available)</li> <li>Mock multiple server/hosts at the same time</li> </ul> <p>For a list of all the changes please check the <a href="https://github.com/lipanski/mockito/releases">release log</a>.</p> <h2>Migrating to the new API</h2> <p>Legacy API:</p> <pre lang="rust"><code>let m1 = mockito::mock("GET", "/hello").with_body("hello").create(); let m2 = mockito::mock("GET", "/bye").with_body("bye").create(); <p>// Use one of these to configure your client let host = mockito:server_address(); let url = mockito::server_url(); </code></pre></p> <p>New API:</p> <pre lang="rust"><code>let mut server = mockito::Server::new(); server.mock("GET", "/hello").with_body("hello").create(); server.mock("GET", "/bye").with_body("bye").create(); <p>// Use one of these to configure your client let host = server.host_with_port(); let url = server.url(); </code></pre></p> <blockquote> <p>If you can't migrate to the new API in one go, consider using version 0.32.5, which supports both the legacy API as well as the new API.</p> </blockquote> <h2>Migrating to the async API</h2> <p>In order to write async tests, you'll need to use the <code>_async</code> methods:</p> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
dependabot[bot]
|
aa876ce24f
|
Bump lru from 0.9.0 to 0.10.0 (#8425) | ||
dependabot[bot]
|
71fdf717a8
|
Bump open from 3.4.0 to 4.0.0 (#8427) | ||
dependabot[bot]
|
f34ac9be62
|
Bump sqlparser from 0.30.0 to 0.32.0 (#8428)
Bumps [sqlparser](https://github.com/sqlparser-rs/sqlparser-rs) from 0.30.0 to 0.32.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/sqlparser-rs/sqlparser-rs/blob/main/CHANGELOG.md">sqlparser's changelog</a>.</em></p> <blockquote> <h2>[0.32.0] 2023-03-6</h2> <h3>Added</h3> <ul> <li>Support ClickHouse <code>CREATE TABLE</code> with <code>ORDER BY</code> (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/824">#824</a>) - Thanks <a href="https://github.com/ankrgyl"><code>@ankrgyl</code></a></li> <li>Support PostgreSQL exponentiation <code>^</code> operator (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/813">#813</a>) - Thanks <a href="https://github.com/michael-2956"><code>@michael-2956</code></a></li> <li>Support <code>BIGNUMERIC</code> type in BigQuery (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/811">#811</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> <li>Support for optional trailing commas (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/810">#810</a>) - Thanks <a href="https://github.com/ankrgyl"><code>@ankrgyl</code></a></li> </ul> <h3>Fixed</h3> <ul> <li>Fix table alias parsing regression by backing out redshift column definition list (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/827">#827</a>) - Thanks <a href="https://github.com/alamb"><code>@alamb</code></a></li> <li>Fix typo in <code>ReplaceSelectElement</code> <code>colum_name</code> --> <code>column_name</code> (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/822">#822</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> </ul> <h2>[0.31.0] 2023-03-1</h2> <h3>Added</h3> <ul> <li>Support raw string literals for BigQuery dialect (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/812">#812</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> <li>Support <code>SELECT * REPLACE <Expr> AS <Identifier></code> in BigQuery dialect (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/798">#798</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> <li>Support byte string literals for BigQuery dialect (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/802">#802</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> <li>Support columns definition list for system information functions in RedShift dialect (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/769">#769</a>) - Thanks <a href="https://github.com/mskrzypkows"><code>@mskrzypkows</code></a></li> <li>Support <code>TRANSIENT</code> keyword in Snowflake dialect (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/807">#807</a>) - Thanks <a href="https://github.com/mobuchowski"><code>@mobuchowski</code></a></li> <li>Support <code>JSON</code> keyword (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/799">#799</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> <li>Support MySQL Character Set Introducers (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/788">#788</a>) - Thanks <a href="https://github.com/mskrzypkows"><code>@mskrzypkows</code></a></li> </ul> <h3>Fixed</h3> <ul> <li>Fix clippy error in ci (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/803">#803</a>) - Thanks <a href="https://github.com/togami2864"><code>@togami2864</code></a></li> <li>Handle offset in map key in BigQuery dialect (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/797">#797</a>) - Thanks <a href="https://github.com/Ziinc"><code>@Ziinc</code></a></li> <li>Fix a typo (precendence -> precedence) (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/794">#794</a>) - Thanks <a href="https://github.com/SARDONYX-sard"><code>@SARDONYX-sard</code></a></li> <li>use post_* visitors for mutable visits (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/789">#789</a>) - Thanks <a href="https://github.com/lovasoa"><code>@lovasoa</code></a></li> </ul> <h3>Changed</h3> <ul> <li>Add another known user (<a href="https://redirect.github.com/sqlparser-rs/sqlparser-rs/issues/787">#787</a>) - Thanks <a href="https://github.com/joocer"><code>@joocer</code></a></li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
Stefan Holderbach
|
1701303279
|
Bump to 0.77.1 development version (#8453)
# Description Either to be used in an emergency point release or to indicate development builds in the `version` command |
||
Stefan Holderbach
|
fd09609b44
|
Bump version to 0.77.0 (#8410)
|
||
Stefan Holderbach
|
c7583ecdb7
|
Pin to reedline 0.17 (#8441)
# Description See release notes: https://github.com/nushell/reedline/releases/tag/v0.17.0 |
||
Stefan Holderbach
|
4eec4a27c7
|
Pin to nu-ansi-term 0.47 (#8440)
# Description Update reedline to a commit that uses the same version as we share types # User-Facing Changes (-) # Tests + Formatting Build check |
||
Stefan Holderbach
|
79d0735864
|
Remove unused nu-json from nu-protocol (#8417)
This dependency apears unnecessary and should remove a link in the crate graph that could favor parallel compilation |
||
dependabot[bot]
|
c26d91fb61
|
Bump nix from 0.25.0 to 0.26.2 (#8129)
Bumps [nix](https://github.com/nix-rust/nix) from 0.25.0 to 0.26.2. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/nix-rust/nix/blob/v0.26.2/CHANGELOG.md">nix's changelog</a>.</em></p> <blockquote> <h2>[0.26.2] - 2023-01-18</h2> <h3>Fixed</h3> <ul> <li>Fix <code>SockaddrIn6</code> bug that was swapping flowinfo and scope_id byte ordering. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1964">#1964</a>)</li> </ul> <h2>[0.26.1] - 2022-11-29</h2> <h3>Fixed</h3> <ul> <li>Fix UB with <code>sys::socket::sockopt::SockType</code> using <code>SOCK_PACKET</code>. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1821">#1821</a>)</li> </ul> <h2>[0.26.0] - 2022-11-29</h2> <h3>Added</h3> <ul> <li>Added <code>SockaddrStorage::{as_unix_addr, as_unix_addr_mut}</code> (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1871">#1871</a>)</li> <li>Added <code>MntFlags</code> and <code>unmount</code> on all of the BSDs.</li> <li>Added <code>any()</code> and <code>all()</code> to <code>poll::PollFd</code>. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1877">#1877</a>)</li> <li>Add <code>MntFlags</code> and <code>unmount</code> on all of the BSDs. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1849">#1849</a>)</li> <li>Added a <code>Statfs::flags</code> method. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1849">#1849</a>)</li> <li>Added <code>NSFS_MAGIC</code> FsType on Linux and Android. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1829">#1829</a>)</li> <li>Added <code>sched_getcpu</code> on platforms that support it. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1825">#1825</a>)</li> <li>Added <code>sched_getaffinity</code> and <code>sched_setaffinity</code> on FreeBSD. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1804">#1804</a>)</li> <li>Added <code>line_discipline</code> field to <code>Termios</code> on Linux, Android and Haiku (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1805">#1805</a>)</li> <li>Expose the memfd module on FreeBSD (memfd was added in FreeBSD 13) (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1808">#1808</a>)</li> <li>Added <code>domainname</code> field of <code>UtsName</code> on Android and Linux (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1817">#1817</a>)</li> <li>Re-export <code>RLIM_INFINITY</code> from <code>libc</code> (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1831">#1831</a>)</li> <li>Added <code>syncfs(2)</code> on Linux (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1833">#1833</a>)</li> <li>Added <code>faccessat(2)</code> on illumos (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1841">#1841</a>)</li> <li>Added <code>eaccess()</code> on FreeBSD, DragonFly and Linux (glibc and musl). (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1842">#1842</a>)</li> <li>Added <code>IP_TOS</code> <code>SO_PRIORITY</code> and <code>IPV6_TCLASS</code> sockopts for Linux (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1853">#1853</a>)</li> <li>Added <code>new_unnamed</code> and <code>is_unnamed</code> for <code>UnixAddr</code> on Linux and Android. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1857">#1857</a>)</li> <li>Added <code>SockProtocol::Raw</code> for raw sockets (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1848">#1848</a>)</li> <li>added <code>IP_MTU</code> (<code>IpMtu</code>) <code>IPPROTO_IP</code> sockopt on Linux and Android. (<a href="https://github-redirect.dependabot.com/nix-rust/nix/pull/1865">#1865</a>)</li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
Stefan Holderbach
|
0a5f8f05da
|
Update all dependencies in Cargo.lock (#8408)
# Description This includes the development versions of `reedline` and `nu-ansi-term` (Interesting to see if there is potential breakage due to a change to the `Color::default()`) All other crates are updated to the latest available version. This change reduces the number of dependencies to compile slightly and for me on Linux reduced the compile time a few seconds. # Output from `cargo build --timings` ## `main` <html><body> <!--StartFragment--> Targets: | nu 0.76.1 (bin "nu") -- | -- Profile: | dev Fresh units: | 0 Dirty units: | 398 Total units: | 398 Max concurrency: | 16 (jobs=16 ncpu=16) Build start: | 2023-03-11T18:19:14Z Total time: | 75.1s (1m 15.1s) rustc: | rustc 1.66.1 (90743e729 2023-01-10)Host: x86_64-unknown-linux-gnuTarget: x86_64-unknown-linux-gnu <!--EndFragment--> </body> </html> ## this PR <html><body> <!--StartFragment--> Targets: | nu 0.76.1 (bin "nu") -- | -- Profile: | dev Fresh units: | 0 Dirty units: | 392 Total units: | 392 Max concurrency: | 16 (jobs=16 ncpu=16) Build start: | 2023-03-11T18:21:20Z Total time: | 69.6s (1m 9.6s) rustc: | rustc 1.66.1 (90743e729 2023-01-10)Host: x86_64-unknown-linux-gnuTarget: x86_64-unknown-linux-gnu <!--EndFragment--> </body> </html> # User-Facing Changes None intended, none visually detected upon a cursory look around. # Tests + Formatting - |
||
Reilly Wood
|
03e688ea7b
|
Revert to notify v4 (#8367)
This reverts https://github.com/nushell/nushell/pull/8114 which upgraded to `notify` (a file watching crate used by the `watch` command) v5. `notify` v5 has several breaking changes and it's much harder to use. It no longer includes debouncing of file system events, which I think is essential functionality for `watch`. @WindSoilder was going to try writing our own debouncing functionality but I don't think he had time to finish it. @WindSoilder Is it OK if we revert this for the 0.77 release (March 14)? We can try again for 0.78 |
||
Darren Schroeder
|
454d1a995c
|
point nushell at latest reedline and nu-ansi-term main (#8342) | ||
dependabot[bot]
|
4ae1b1cc26
|
Bump scraper from 0.14.0 to 0.15.0 (#8331)
Bumps [scraper](https://github.com/causal-agent/scraper) from 0.14.0 to 0.15.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/causal-agent/scraper/releases">scraper's releases</a>.</em></p> <blockquote> <h2>0.15.0</h2> <h2>What's Changed</h2> <ul> <li>Bump cssparser to 0.28 and selectors to 0.23. by <a href="https://github.com/adamreichold"><code>@adamreichold</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/99">causal-agent/scraper#99</a></li> <li>Create dependabot.yml by <a href="https://github.com/mohe2015"><code>@mohe2015</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/97">causal-agent/scraper#97</a></li> <li>Re-export Element trait from selectors crate by <a href="https://github.com/adamreichold"><code>@adamreichold</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/98">causal-agent/scraper#98</a></li> <li>build(deps): fix unchecked lock and update deps by <a href="https://github.com/j-mendez"><code>@j-mendez</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/107">causal-agent/scraper#107</a></li> <li>Re-export selectors' CaseSensitivity enum as it is part of our public API. by <a href="https://github.com/adamreichold"><code>@adamreichold</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/108">causal-agent/scraper#108</a></li> <li>perf(element): add one sweep element creation by <a href="https://github.com/j-mendez"><code>@j-mendez</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/109">causal-agent/scraper#109</a></li> <li>Added feature flag <code>atomic</code> to make use of atomic <code>StrTendril</code> type. by <a href="https://github.com/jaboatman"><code>@jaboatman</code></a> in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/102">causal-agent/scraper#102</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/adamreichold"><code>@adamreichold</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/99">causal-agent/scraper#99</a></li> <li><a href="https://github.com/mohe2015"><code>@mohe2015</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/97">causal-agent/scraper#97</a></li> <li><a href="https://github.com/j-mendez"><code>@j-mendez</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/107">causal-agent/scraper#107</a></li> <li><a href="https://github.com/jaboatman"><code>@jaboatman</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/causal-agent/scraper/pull/102">causal-agent/scraper#102</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/causal-agent/scraper/compare/v0.14.0...v0.15.0">https://github.com/causal-agent/scraper/compare/v0.14.0...v0.15.0</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
dependabot[bot]
|
b7a34498e3
|
Bump rust-embed from 6.4.1 to 6.6.0 (#8330)
Bumps [rust-embed](https://github.com/pyros2097/rust-embed) from 6.4.1 to 6.6.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/pyrossh/rust-embed/blob/master/changelog.md">rust-embed's changelog</a>.</em></p> <blockquote> <h2>[6.6.0] - 2023-03-05</h2> <ul> <li>sort_by_file_name() requires walkdir v2.3.2 <a href="https://github-redirect.dependabot.com/pyrossh/rust-embed/issues/206">#206</a></li> <li>Add <code>mime-guess</code> feature to statically store mimetype <a href="https://github-redirect.dependabot.com/pyrossh/rust-embed/issues/192">#192</a></li> </ul> <h2>[6.4.2] - 2022-10-20</h2> <ul> <li>Fail the proc macro if include/exclude are used without the feature <a href="https://github-redirect.dependabot.com/pyrossh/rust-embed/issues/187">#187</a></li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/pyros2097/rust-embed/commits">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rust-embed&package-manager=cargo&previous-version=6.4.1&new-version=6.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 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> |
||
dependabot[bot]
|
10fd3115c2
|
Bump rayon from 1.6.1 to 1.7.0 (#8328)
Bumps [rayon](https://github.com/rayon-rs/rayon) from 1.6.1 to 1.7.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/rayon-rs/rayon/blob/master/RELEASES.md">rayon's changelog</a>.</em></p> <blockquote> <h1>Release rayon 1.7.0 / rayon-core 1.11.0 (2023-03-03)</h1> <ul> <li>The minimum supported <code>rustc</code> is now 1.59.</li> <li>Added a fallback when threading is unsupported.</li> <li>The new <code>ParallelIterator::take_any</code> and <code>skip_any</code> methods work like unordered <code>IndexedParallelIterator::take</code> and <code>skip</code>, counting items in whatever order they are visited in parallel.</li> <li>The new <code>ParallelIterator::take_any_while</code> and <code>skip_any_while</code> methods work like unordered <code>Iterator::take_while</code> and <code>skip_while</code>, which previously had no parallel equivalent. The "while" condition may be satisfied from anywhere in the parallel iterator, affecting all future items regardless of position.</li> <li>The new <code>yield_now</code> and <code>yield_local</code> functions will cooperatively yield execution to Rayon, either trying to execute pending work from the entire pool or from just the local deques of the current thread, respectively.</li> </ul> <h1>Release rayon-core 1.10.2 (2023-01-22)</h1> <ul> <li>Fixed miri-reported UB for SharedReadOnly tags protected by a call.</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
dependabot[bot]
|
df60793e3b
|
Bump tempfile from 3.3.0 to 3.4.0 (#8329)
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.3.0 to 3.4.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/Stebalien/tempfile/blob/master/NEWS">tempfile's changelog</a>.</em></p> <blockquote> <h1>3.4.0</h1> <p>SECURITY: Prior <code>tempfile</code> releases depended on <code>remove_dir_all</code> version 0.5.0 which was vulnerable to a <a href="https://github.com/XAMPPRocky/remove_dir_all/security/advisories/GHSA-mc8h-8q98-g5hr">TOCTOU race</a>. This same race is present in rust versions prior to 1.58.1.</p> <p>Features:</p> <ul> <li>Generalized temporary files: <code>NamedTempFile</code> can now abstract over different kinds of files (e.g., unix domain sockets, pipes, etc.): <ul> <li>Add <code>Builder::make</code> and <code>Builder::make_in</code> for generalized temp file creation.</li> <li>Add <code>NamedTempFile::from_parts</code> to complement <code>NamedTempFile::into_parts</code>.</li> <li>Add generic parameter to <code>NamedTempFile</code> to support wrapping non-File types.</li> </ul> </li> </ul> <p>Bug Fixes/Improvements:</p> <ul> <li>Don't try to create a temporary file multiple times if the file path has been fully specified by the user (no random characters).</li> <li><code>NamedTempFile::persist_noclobber</code> is now always atomic on linux when <code>renameat_with</code> is supported. Previously, it would first link the new path, then unlink the previous path.</li> <li>Fix compiler warnings on windows.</li> </ul> <p>Trivia:</p> <ul> <li>Switch from <code>libc</code> to <code>rustix</code> on wasi/unix. This now makes direct syscalls instead of calling through libc.</li> <li>Remove <code>remove_dir_all</code> dependency. The rust standard library has optimized their internal version significantly.</li> <li>Switch to official windows-sys windows bindings.</li> </ul> <p>Breaking:</p> <ul> <li>The minimum rust version is now <code>1.48.0</code>.</li> <li>Mark most functions as <code>must_use</code>.</li> <li>Uses direct syscalls on linux by default, instead of libc.</li> <li>The new type parameter in <code>NamedTempFile</code> may lead to type inference issues in some cases.</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/Stebalien/tempfile/commits">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tempfile&package-manager=cargo&previous-version=3.3.0&new-version=3.4.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 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> |
||
Filip Andersson
|
f6ca62384e
|
changes Reqwest to Ureq. (#8320)
# Description _(Thank you for improving Nushell. Please, check our [contributing guide](../CONTRIBUTING.md) and talk to the core team before making major changes.)_ This pull request removes `Reqwest` and replaces it with `Ureq` to remove some of our dependencies, giving us faster compile times as well as smaller binaries. `Ureq` does not have an async runtime included so we do not need build heavy dependencies such as `Tokio`. From older tests I had the number of build units be reduced from `430 -> 392`. The default of `Ureq` uses `Rustls` but it has been configured to instead use `native_tls` which should work exactly the same as the `tls` works now. I removed `content-length` from the http commands as after refactoring i did not see a reason to have it available, correct me if this is something we should preserve. In the medium, to long term, we should maybe consider changing to `rustls` to have the same `tls` on all platforms. # 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass # 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. |
||
Reilly Wood
|
f93033c20b
|
Fix CPU usage info in sys (#8321)
Closes #8264. This PR does a few things to fix the `usage` column in `sys.cpu`: 1. Sleep a while (~400ms) between calls to `sys.refresh_cpu()`, [as required by `sysinfo`](https://docs.rs/sysinfo/latest/sysinfo/trait.SystemExt.html#method.refresh_cpu) 2. Change `sys` to return a `LazyRecord` (so you can do things like `sys | get host` instantly without waiting for CPU info) 3. Update our `sysinfo` dependency to [fix CPU usage calculations on Linux](https://github.com/GuillaumeGomez/sysinfo/pull/946) CPU usage is no longer always reported as zero: ![image](https://user-images.githubusercontent.com/26268125/222929775-5e9cbe18-95d9-4ecb-baf8-1e843f5c7086.png) |
||
Jérémy Audiger
|
a7b5bd18ba
|
Shadow rs dep (#8298)
# Description While looking at the recent MR merged, I noticed that a dependency was no more used with https://github.com/nushell/nushell/pull/8280. # User-Facing Changes None. # 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass # 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. |
||
Jérémy Audiger
|
c1d76bfac7
|
Add unit tests for HTTP commands. (#8267)
# Description Following the comment from @fdncred: https://github.com/nushell/nushell/pull/8144#issuecomment-1442514338. I added some unit tests for HTTP commands. The tests are not exhaustive, but at least, this is a first good step IMO. # User-Facing Changes None. # 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` to check that you're using the standard code style - `cargo test --workspace` to check that all tests pass # 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. |
||
Michael Angerman
|
b093d5d10d
|
clean up nu-cmd-lang Cargo.toml (#8252)
Remove all un-used dependencies in nu-cmd-lang's Cargo.toml |
||
dependabot[bot]
|
c358400351
|
Bump procfs from 0.14.1 to 0.15.1 (#8233)
Bumps [procfs](https://github.com/eminence/procfs) from 0.14.1 to 0.15.1. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/eminence/procfs/releases">procfs's releases</a>.</em></p> <blockquote> <h2>v0.15.1</h2> <h2>New features</h2> <ul> <li>Change Stat::comm documentation by <a href="https://github.com/rust1248"><code>@rust1248</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/251">eminence/procfs#251</a></li> <li>Add docs and a as_str method to MMPermission by <a href="https://github.com/eminence"><code>@eminence</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/252">eminence/procfs#252</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/rust1248"><code>@rust1248</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/251">eminence/procfs#251</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/eminence/procfs/compare/v0.15.0...v0.15.1">https://github.com/eminence/procfs/compare/v0.15.0...v0.15.1</a></p> <h2>v0.15.0</h2> <h2>New Features</h2> <ul> <li>Add /proc/iomem by <a href="https://github.com/tatref"><code>@tatref</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/216">eminence/procfs#216</a></li> <li>Add new functions to read various net files for a specific process by <a href="https://github.com/eminence"><code>@eminence</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/226">eminence/procfs#226</a></li> <li>add /proc/kpageflags by <a href="https://github.com/tatref"><code>@tatref</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/233">eminence/procfs#233</a></li> <li>Enable oppportunistic fd counting fast path by <a href="https://github.com/bobrik"><code>@bobrik</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/234">eminence/procfs#234</a></li> <li>add /proc/kpagecount by <a href="https://github.com/tatref"><code>@tatref</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/232">eminence/procfs#232</a></li> <li>Add new <code>/proc/meminfo</code> fields. by <a href="https://github.com/afranchuk"><code>@afranchuk</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/238">eminence/procfs#238</a></li> <li>impl Hash for kernel version by <a href="https://github.com/tatref"><code>@tatref</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/240">eminence/procfs#240</a></li> </ul> <h2>Bug fixes</h2> <ul> <li>fix chrono::Local::timestamp deprecated in chrono 0.4.23 by <a href="https://github.com/tatref"><code>@tatref</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/220">eminence/procfs#220</a></li> <li>Fix some minor documentation issues by <a href="https://github.com/eminence"><code>@eminence</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/225">eminence/procfs#225</a></li> <li>Fixes the reported path when a task's function returns an error by <a href="https://github.com/eminence"><code>@eminence</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/230">eminence/procfs#230</a></li> <li>fix shm size type by <a href="https://github.com/tatref"><code>@tatref</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/243">eminence/procfs#243</a></li> </ul> <h2>Breaking changes</h2> <ul> <li>ticks_per_second and page_size are infallible by <a href="https://github.com/eminence"><code>@eminence</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/235">eminence/procfs#235</a></li> <li>parse uid for /proc/net/{tcp,udp} by <a href="https://github.com/trinity-1686a"><code>@trinity-1686a</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/231">eminence/procfs#231</a></li> <li>Refactor and expose memory map processing. by <a href="https://github.com/afranchuk"><code>@afranchuk</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/237">eminence/procfs#237</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/trinity-1686a"><code>@trinity-1686a</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/231">eminence/procfs#231</a></li> <li><a href="https://github.com/afranchuk"><code>@afranchuk</code></a> made their first contribution in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/238">eminence/procfs#238</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/eminence/procfs/compare/v0.14.2...v0.15.0">https://github.com/eminence/procfs/compare/v0.14.2...v0.15.0</a></p> <h2>MSRV Note</h2> <p>This <code>v0.15</code> release is only tested against the latest stable rust compiler, but is known to work with older versions (down to rust 1.48). Support for these older compilers may break in <code>procfs</code> patch releases. See also <a href="https://github-redirect.dependabot.com/eminence/procfs/issues/223">#223</a></p> <h2>v0.14.2</h2> <h2>New Features</h2> <ul> <li>Process: Namespace: Use openat instead of building a path by <a href="https://github.com/arilou"><code>@arilou</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/192">eminence/procfs#192</a></li> <li>add serde serialize/deserialize derives for public types by <a href="https://github.com/eliad-wiz"><code>@eliad-wiz</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/193">eminence/procfs#193</a></li> <li>Disabling default features on the <code>chrono</code> crate by <a href="https://github.com/Will-Low"><code>@Will-Low</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/210">eminence/procfs#210</a></li> <li>Implement smaps_rollup by <a href="https://github.com/TaborKelly"><code>@TaborKelly</code></a> in <a href="https://github-redirect.dependabot.com/eminence/procfs/pull/214">eminence/procfs#214</a></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
||
dependabot[bot]
|
a09aaf3495
|
Bump csv from 1.1.6 to 1.2.0 (#8235)
Bumps [csv](https://github.com/BurntSushi/rust-csv) from 1.1.6 to 1.2.0. <details> <summary>Commits</summary> <ul> <li><a href=" |