Skip to content

cargo new generates gitignore file that ignores non-root Cargo.locks, causing errors with cargo vendor #10370

@ashpil

Description

@ashpil

The default gigignore template generates a line with Cargo.lock rather than /Cargo.lock, causing necessary Cargo.locks in non-root directories to be ignored.

This becomes an issue if one uses cargo vendor to vendor deps - as the gitignore file ignores the dependencies' Cargo.locks, which one is required to have to build without error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions