Skip to content

ci: git Unknown option: -C #142534

@matthiaskrgr

Description

@matthiaskrgr

saw this in the try log jobs of #142531 (comment)

https://github.com/rust-lang/rust/actions/runs/15661849630/job/44120746559#step:28:2059

Sun, 15 Jun 2025 09:49:11 GMT Unknown option: -C
Sun, 15 Jun 2025 09:49:11 GMT usage: git [--version] [--help] [-c name=value]
Sun, 15 Jun 2025 09:49:11 GMT            [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
Sun, 15 Jun 2025 09:49:11 GMT            [-p|--paginate|--no-pager] [--no-replace-objects] [--bare]
Sun, 15 Jun 2025 09:49:11 GMT            [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]
Sun, 15 Jun 2025 09:49:11 GMT            <command> [<args>]

apparently we run git -C sometimes

       -C <path>
           Run as if git was started in <path> instead of the current working directory. When multiple -C options are given, each subsequent non-absolute -C <path> is interpreted relative to the preceding -C <path>. If <path> is present but empty, e.g.  -C "", then the current working directory is left unchanged.

maybe the git version on ci is not new enough?

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-CIArea: Our Github Actions CIC-bugCategory: This is a bug.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions