nushell / nushell/nushell

Completion menu shows history instead of command completions when using list layout.

Open
#16,971 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A:completions A:configuration A:line-editor status:needs-triage
Dominant language
Rust
Stars
40.5k
Forks
2.3k
Avg merge
1d 14h
Merged PRs (30d)
79

Description

Bug report form
  • I have done a basic search of the issue tracker to find any existing issues that are similar.
  • I have checked that my version is at least the latest stable release available via my installation method.
Describe the bug

If I set the completion_menu layout to list, pressing TAB displays my command history rather than command completion suggestions.

This is what I get when I enter cd and press TAB in my home directory, using layout: list:

✔ > cd
0: cd ~
1: cd /usr/bin
2: cd /usr
3: cd /tmp
4: cd /
5: cd ..
...

When I change layout: columnar I get directory suggestions (as expected):

✔ > cd
Desktop/
backup/
bin/
books/
build/
...
How to reproduce
  • Add this config to config.nu:
$env.config.completions.sort = "smart"
$env.config.completions.algorithm = "fuzzy"

$env.config.menus ++= [{
    name: completion_menu
    only_buffer_difference: false
    type: {
        layout: list
    }
    marker: ""
    style: {
        text: white
        selected_text: red
        description_text: yellow
    }
}]

  • Navigate to a directory that contains many subdirectories, for example: cd ~.

  • Type cd (with a space) and press TAB.

    Instead of showing directory name completions, this displays the command history for cd.

  • If you change the setting to layout: columnar and open a new terminal, completions are shown correctly.

Expected behavior

I expected to see directory name completions when pressing TAB after typing cd using layout: list.

Configuration
key value
version 0.108.0
major 0
minor 108
patch 0
branch makepkg
commit_hash da141be11b3acaa55b39321e5f9651d02aa2ed6f
build_os linux-x86_64
build_target x86_64-unknown-linux-gnu
rust_version rustc 1.90.0 (1159e78c4 2025-09-14) (Arch Linux rust 1:1.90.0-3)
cargo_version cargo 1.90.0 (840b83a10 2025-07-30) (Arch Linux rust 1:1.90.0-3)
build_time 2025-10-15 21:17:42 +00:00
build_rust_channel release
allocator standard
features default, network, plugin, rustls-tls, sqlite, trash-support
installed_plugins
experimental_options example=false, reorder-cell-paths=true, pipefail=false, enforce-runtime-annotations=false

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no files or tests. First reproduce the problem with the supplied config, then trace the completion-menu handling for list and columnar layouts; done means pressing TAB after cd with layout: list shows directory completions rather than command history.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.