From 846f5d9e578d596070d2085321cf6b77d34f627a Mon Sep 17 00:00:00 2001 From: Ajeet D'Souza <98ajeet@gmail.com> Date: Sun, 22 Aug 2021 23:36:50 +0530 Subject: [PATCH] Changes for elvish 0.16.0 --- CHANGELOG.md | 6 ++++++ README.md | 7 +++++-- shell.nix | 2 +- templates/elvish.txt | 6 ++++-- templates/nushell.txt | 3 ++- 5 files changed, 18 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e8006fe..4a48f05 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 + +### Fixed + +- Elvish: errors on 0.16.0. + ## [0.7.4] - 2020-08-15 ### Fixed diff --git a/README.md b/README.md index c6787bc..44c8323 100644 --- a/README.md +++ b/README.md @@ -149,6 +149,8 @@ Add this to your configuration (usually `~/.elvish/rc.elv`): eval (zoxide init elvish | slurp) ``` +Note that zoxide only supports elvish v0.16.0+. +
@@ -163,7 +165,7 @@ zoxide init fish | source
-nushell v0.33+ +nushell Add this to your configuration (find it by running `config path` in Nushell): @@ -172,7 +174,8 @@ prompt = "__zoxide_hook;__zoxide_prompt" startup = ["zoxide init nushell --hook prompt | save ~/.zoxide.nu", "source ~/.zoxide.nu"] ``` -You can replace `__zoxide_prompt` with a custom prompt. +You can replace `__zoxide_prompt` with a custom prompt. Note that zoxide only +supports Nushell v0.33.0+.
diff --git a/shell.nix b/shell.nix index 69d93bf..25820ec 100644 --- a/shell.nix +++ b/shell.nix @@ -1,7 +1,7 @@ let rust = import (builtins.fetchTarball "https://github.com/oxalica/rust-overlay/archive/ad311f5bb5c5ef475985f1e0f264e831470a8510.tar.gz"); pkgs = import { overlays = [ rust ]; }; - pkgs-latest = import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/1359293549af4f8ca536716d0432f3cdd0afe0c6.tar.gz") {}; + pkgs-latest = import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/b4692e4197869c42c46d77e31af7e687e1892f55.tar.gz") {}; pkgs-python = pkgs-latest.python3.withPackages (pkgs: [ pkgs.black pkgs.mypy pkgs.pylint ]); in pkgs.mkShell { diff --git a/templates/elvish.txt b/templates/elvish.txt index 875f16c..996a689 100644 --- a/templates/elvish.txt +++ b/templates/elvish.txt @@ -49,7 +49,7 @@ fn __zoxide_z [@rest]{ __zoxide_cd ~ } elif (builtin:eq [-] $rest) { __zoxide_cd (builtin:get-env __zoxide_oldpwd) - } elif (and (builtin:eq (builtin:count $rest) 1) (path:is-dir $rest[0])) { + } elif (and (builtin:eq (builtin:count $rest) 1) (path:is-dir &follow-symlink=$true $rest[0])) { __zoxide_cd $rest[0] } else { __zoxide_cd (zoxide query --exclude $pwd -- $@rest) @@ -83,4 +83,6 @@ edit:add-var zi~ $__zoxide_zi~ # To initialize zoxide, add this to your configuration (usually # ~/.elvish/rc.elv): # -# eval (zoxide init elvish | slurp) +# eval (zoxide init elvish | slurp) +# +# Note that zoxide only supports elvish v0.16.0+. diff --git a/templates/nushell.txt b/templates/nushell.txt index 4f222a5..7929bfa 100644 --- a/templates/nushell.txt +++ b/templates/nushell.txt @@ -101,4 +101,5 @@ alias {{cmd}}i = __zoxide_zi # prompt = '__zoxide_hook;__zoxide_prompt' # startup = ['zoxide init nushell --hook prompt | save ~/.zoxide.nu', 'source ~/.zoxide.nu'] # -# You can replace __zoxide_prompt with a custom prompt. +# You can replace __zoxide_prompt with a custom prompt. Note that zoxide only +# supports Nushell v0.33.0+.