From 41b8f08c46a8bffaaa93c67a34bd38dfc05eab9d Mon Sep 17 00:00:00 2001 From: Ajeet D'Souza <98ajeet@gmail.com> Date: Sat, 18 Sep 2021 01:43:59 +0530 Subject: [PATCH] Upgrade Nushell to v0.37.0 (#266) --- .github/workflows/ci.yml | 2 +- CHANGELOG.md | 6 ++++++ README.md | 2 +- man/zoxide-init.1 | 2 +- templates/nushell.txt | 8 ++++---- 5 files changed, 13 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 284fe2f6..aed25a25 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,4 +21,4 @@ jobs: if: ${{ matrix.os != 'windows-latest' }} with: nix_path: nixpkgs=https://github.com/NixOS/nixpkgs/archive/20.09.tar.gz - - run: cargo xtask ci --nix ${{ matrix.os != 'windows-latest' }} + - run: cargo xtask --nix=${{ matrix.os != 'windows-latest' }} ci diff --git a/CHANGELOG.md b/CHANGELOG.md index 9fdb9607..7afd6e59 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## Unreleased + +### Changed + +- Nushell: upgrade minimum supported version to v0.37.0. + ## [0.7.5] - 2020-09-09 ### Added diff --git a/README.md b/README.md index 32c42ba4..28dddb3b 100644 --- a/README.md +++ b/README.md @@ -182,7 +182,7 @@ Add this to your configuration (find it by running `config path` in Nushell): startup = ["zoxide init nushell --hook prompt | save ~/.zoxide.nu", "source ~/.zoxide.nu"] ``` -Note: zoxide only supports Nushell v0.36.0 and above. +Note: zoxide only supports Nushell v0.37.0 and above. diff --git a/man/zoxide-init.1 b/man/zoxide-init.1 index be6b1a01..3b61c402 100644 --- a/man/zoxide-init.1 +++ b/man/zoxide-init.1 @@ -36,7 +36,7 @@ Nushell): \fBstartup = ["zoxide init nushell --hook prompt | save ~/.zoxide.nu", "source ~/.zoxide.nu"]\fR .fi .sp -Note: zoxide only supports Nushell v0.36.0 and above. +Note: zoxide only supports Nushell v0.37.0 and above. .TP .B powershell Add this to your configuration (find it by running \fBecho $profile\fR in diff --git a/templates/nushell.txt b/templates/nushell.txt index 2f65d890..9874a31b 100644 --- a/templates/nushell.txt +++ b/templates/nushell.txt @@ -33,10 +33,10 @@ def __zoxide_hook [] { } # Initialize hook. -let-env PROMPT_STRING = ( - let prompt = (if ($nu.env | select PROMPT_STRING | empty?) { +let-env PROMPT_COMMAND = ( + let prompt = (if ($nu.env | select PROMPT_COMMAND | empty?) { if ($nu.config | select prompt | empty?) { '__zoxide_prompt' } { $nu.config.prompt } - } { $nu.env.PROMPT_STRING }); + } { $nu.env.PROMPT_COMMAND }); if ($prompt | str contains '__zoxide_hook') { $prompt } { $'__zoxide_hook;($prompt)' } ) @@ -107,4 +107,4 @@ alias {{cmd}}i = __zoxide_zi # # startup = ['zoxide init nushell --hook prompt | save ~/.zoxide.nu', 'source ~/.zoxide.nu'] # -# Note: zoxide only supports Nushell v0.36.0 and above. +# Note: zoxide only supports Nushell v0.37.0 and above.