Skip to content

[Bug]: Format scripts hiding errors when using grep from busybox #860

Description

@psalaberria002

What happened?

format.sh uses grep -vFxf <(git ls-files --deleted) to exclude deleted files from the formatter input. When git ls-files --deleted returns nothing (normal for a clean checkout), the pattern file is empty. BusyBox grep -vFxf with an empty pattern file exits 1 and produces no output, where GNU grep passes all lines through. The || true swallows the exit code but not the lost output, leaving files="" for every language — so no formatter ever runs.

Version

Development (host) and target OS/architectures:

Output of bazel --version:

Version of the Aspect rules, or other relevant rules from your
WORKSPACE or MODULE.bazel file:

Language(s) and/or frameworks involved:

How to reproduce

Any other information?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions