Basic Development Precautions#
Scripts#
We provide a series of scripts to help you handle simple daily tasks. Please refer to Script Instructions.
Run Integration Tests#
First, you need to set environment variables. For convenience, we support .env and provide a simple template for setting environment variables, or you can set the OURCHAT_CONFIG_FILE variable to point to the directory containing test configuration files. Then you can run cargo test to run the tests.
Documentation#
Please make good use of cargo doc, we have provided you with detailed documentation! Call cargo doc --document-private-items to generate private documentation.
Pre-requisites#
buf (for formatting and checking .proto files, optional)
Optimize Development Experience#
Since analyzing and indexing all crates in the workspace is a heavy burden on your computer, especially when you are likely to work on only a few crates, we strongly recommend using the following configuration in VSCode:
{
"rust-analyzer.files.exclude": [
"server/migration", // example
],
}