Skip to content

CARAPACE_MATCH doesn't ignore case on completion #1061

@houqp

Description

@houqp

Current Behavior

when CARAPACE_MATCH is set to 1, trying to complete with pkill --signal a yields no result

Expected Behavior

when CARAPACE_MATCH is set to 1, trying to complete with pkill --signal a yields:

ABRT  -- Abnormal termination
ALRM  -- Virtual alarm clock

Steps To Reproduce

  1. set CARAPACE_MATCH to 1
  2. type pkill --signal a
  3. press tab to trigger completion

Version

1.0.7

OS

  • Darwin
  • Linux
  • Termux
  • Windows

Shell

  • Bash
  • Elvish
  • Fish
  • Nushell
  • Oil
  • Powershell
  • Xonsh
  • Zsh

Anything else?

Not the root cause of this since the example uses prefix for completion, but there seems be to another bug in the relevant code file:

strings.EqualFold(s, t)
. We are not returning the result from strings.EqualFold when CASE_INSENSITIVE is enabled.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions