Skip to content

Regression in Fish 4: the test command doesn't work with parenthesis anymore #11387

Description

@bugnano

I'm using Fish 4.0.1 on Fedora 42.

Before upgrading to Fedora 42 I was using Fedora 40, with the old C++-based fish shell.

In the old shell I used the command

if test \( -f /usr/bin/fdfind \) -a \( ! -f /usr/bin/fd \)

in my config file and everything worked fine.

Also, note that this syntax is still documented in Fish 4.0.1

However, after upgrading to Fedora 42, Fish 4.0.1 complains with:

test: Expected a combining operator like '-a' at index 4
( -f /usr/bin/fdfind ) -a ( ! -f /usr/bin/fd )
                     ^
~/.config/fish/config.fish (line 211): 
if test \( -f /usr/bin/fdfind \) -a \( ! -f /usr/bin/fd \)
   ^
from sourcing file ~/.config/fish/config.fish
	called during startup

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

regressionSomething that used to work, but was broken, especially between releases

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions