Skip to content
This repository was archived by the owner on Sep 9, 2026. It is now read-only.

Latest commit

 

History

History
56 lines (38 loc) · 1.54 KB

File metadata and controls

56 lines (38 loc) · 1.54 KB

Contributor's guide

Commit signing

Enable commit signing

git config commit.gpgsign true

Prerequisites

Code quality assurance

Install a pre-push git hook:

git config core.hooksPath .githooks

Running the Rust Documentation Locally

After cloning the repository, follow the instructions below to run the documentation locally:

cargo doc

Docs for TODO(template) template_crate:

RUSTDOCFLAGS="--html-in-header katex-header.html" cargo doc --no-deps -p template_crate --open

pre-commit Framework (Alternative)

As an alternative to the pre-push git hook, you can use the pre-commit framework to manage and run hooks. pre-commit is Python-based and allows you to define a set of hooks that will run automatically on certain git events, such as pre-commit or pre-push.

In addition to the hooks defined in .githooks, pre-commit configuration also cleansup the code by removing trailing whitespace and ensuring that all files end with a newline.

To set up pre-commit, follow these steps:

  1. Install pre-commit:

    pip install pre-commit
  2. Install the pre-commit hooks:

     pre-commit install --hook-type pre-push