Skip to content

Fix pre-commit rustfmt skip paths for core crate#5533

Open
Shiven0504 wants to merge 4 commits into
clockworklabs:masterfrom
Shiven0504:fix/pre-commit-rustfmt-skip
Open

Fix pre-commit rustfmt skip paths for core crate#5533
Shiven0504 wants to merge 4 commits into
clockworklabs:masterfrom
Shiven0504:fix/pre-commit-rustfmt-skip

Conversation

@Shiven0504

@Shiven0504 Shiven0504 commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR updates the pre-commit hook to reflect the repository's current crate layout for rustfmt skip checks.

Previously, the hook excluded messages.rs and crates/spacetimedb-core/src/protobuf/*.rs. Since the repository no longer contains the protobuf directory under spacetimedb-core, the skip pattern had become outdated, causing messages.rs to be formatted instead of being excluded.

This change updates the skip paths so the hook correctly matches the current repository structure. Fixes #5532

API and ABI Breaking Changes

  • None.

Risk / Complexity

  • Complexity: 1 (Trivial)
  • Risk: Low. This is a maintenance-only change affecting git hook path matching and has no impact on runtime behavior.

Testing

  • Verified the updated hook diff.

  • Confirmed the skip paths match the current repository layout.

  • Validated the hook syntax using:

    bash -n git-hooks/hooks/pre-commit

Update git-hooks/hooks/pre-commit to match the current crate layout. The old exclusions used the removed path crates/spacetimedb-core/..., so messages.rs and protobuf output were being formatted instead of skipped.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

git-hooks/pre-commit: stale exclusion paths no longer match after crate reorganization

1 participant