Repository: atuinsh/atuin (language: rust)

Issue:
[nushell] breaking change coming
Heads-up friendly folks at atuin! At nushell, we're working on a PR that will probably be a breaking change for people who use atuin with nushell integration.

We're breaking up the commandline built-in command into several subcommands. Please see the PR for more details. It will be deprecated for a while. You'll get a warning message, but it should still work in version 0.91.0 but after that we'll probably remove the deprecation.
https://github.com/nushell/nushell/pull/11877




Discussion / hints:

Fix patch:
diff --git a/atuin/src/shell/atuin.nu b/atuin/src/shell/atuin.nu
index 75e4b8a4ecc..17591b41b16 100644
--- a/atuin/src/shell/atuin.nu
+++ b/atuin/src/shell/atuin.nu
@@ -28,10 +28,12 @@ let _atuin_pre_prompt = {||
 }
 
 def _atuin_search_cmd [...flags: string] {
+    let nu_version = ($env.NU_VERSION | split row '.' | each { || into int })
     [
         $ATUIN_KEYBINDING_TOKEN,
         ([
-            `commandline (ATUIN_LOG=error run-external --redirect-stderr atuin search`,
+            (if $nu_version.0 <= 0 and $nu_version.1 <= 90 { 'commandline' } else { 'commandline edit' }),
+            `(ATUIN_LOG=error run-external --redirect-stderr atuin search`,
             ($flags | append [--interactive, --] | each {|e| $'"($e)"'}),
             `(commandline) | complete | $in.stderr | str substring ..-1)`,
         ] | flatten | str join ' '),


Test patch: