Skip to content

Adding rustfmt to pre-commit-hooks #109

@szg251

Description

@szg251

By default, rustfmt looks for a Cargo.toml file in the root directory to determines which files should be formatted. However, as we're using a monorepo structure there's no such file, so the pre-commit-hook fails. We must find a way to tell rustfmt where the package roots are.
Previously I configured cargo workspaces, which solved the problem, but it is not in alignment with the rules of our monorepo (the repo should be language agnostic), so this is a no-go.

Metadata

Metadata

Assignees

Labels

devopsAll things devops (Nix, language servers, editors, code quality etc)

Type

No type

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions