From 806a8c9a5a144a754d545f49c8070b5556940837 Mon Sep 17 00:00:00 2001 From: Robin Steuteville Date: Tue, 30 Jan 2024 11:06:14 -0700 Subject: [PATCH 1/2] creating developers chapter in md book --- docs/src/SUMMARY.md | 1 + docs/src/developers.md | 11 +++++++++++ docs/src/fastsim-doc.md | 4 +++- docs/src/how-to-update.md | 4 ++-- 4 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 docs/src/developers.md diff --git a/docs/src/SUMMARY.md b/docs/src/SUMMARY.md index 90bb88e0..f4961345 100644 --- a/docs/src/SUMMARY.md +++ b/docs/src/SUMMARY.md @@ -4,4 +4,5 @@ - [Documentation](./fastsim-doc.md) - [Python](./python-doc.md) - [Rust](./rust-doc.md) + - [Developers](./developers.md) - [How to Update This Book](./how-to-update.md) diff --git a/docs/src/developers.md b/docs/src/developers.md new file mode 100644 index 00000000..8bacb111 --- /dev/null +++ b/docs/src/developers.md @@ -0,0 +1,11 @@ +# How to compile/test Rust code + +## cargo build +`cargo build` will not compile when run in `/rust` due to problems compiling `/rust/fastsim-py`. +`cargo build` should compile when run in the `/rust/fastsim-core`. + +## cargo test +`cargo test` should compile when run in /rust because there are no tests in `/rust/fastsim-py`. + +## build_and_test.sh +Running `sh build_and_test.sh` from the root fastsim directory compile/tests the Rust code, and tests the Python code. It should compile without errors. \ No newline at end of file diff --git a/docs/src/fastsim-doc.md b/docs/src/fastsim-doc.md index 565f42dc..dfa9a59e 100644 --- a/docs/src/fastsim-doc.md +++ b/docs/src/fastsim-doc.md @@ -2,4 +2,6 @@ ## [Python](./python-doc.md) -## [Rust](./rust-doc.md) \ No newline at end of file +## [Rust](./rust-doc.md) + +## [Developers](./developers.md) \ No newline at end of file diff --git a/docs/src/how-to-update.md b/docs/src/how-to-update.md index 7f9f81ee..1462d723 100644 --- a/docs/src/how-to-update.md +++ b/docs/src/how-to-update.md @@ -16,7 +16,7 @@ Run the following in the repository root directory: ## Publishing 1. Update `book.toml` or files in `docs/src/` -1. Make sure the docs look good locally by running the -1. Commit files and push to `main` branch +1. Make sure the docs look good locally: `mdbook build docs/ --open` +1. Commit files and push to `fastsim-2` branch After that, a GitHub action will build the book and publish it [here](https://pages.github.nrel.gov/MBAP/mbap-computing/) \ No newline at end of file From d78781ee700b6bf082f5212c90285aeac63f0231 Mon Sep 17 00:00:00 2001 From: Chad Baker Date: Tue, 30 Jan 2024 11:15:42 -0700 Subject: [PATCH 2/2] linked to appropriate section --- docs/src/how-to-update.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/how-to-update.md b/docs/src/how-to-update.md index 1462d723..57ae3e47 100644 --- a/docs/src/how-to-update.md +++ b/docs/src/how-to-update.md @@ -16,7 +16,7 @@ Run the following in the repository root directory: ## Publishing 1. Update `book.toml` or files in `docs/src/` -1. Make sure the docs look good locally: `mdbook build docs/ --open` +1. Make sure the docs look good locally by running the steps in [Serving Locally](#serving-locally). 1. Commit files and push to `fastsim-2` branch After that, a GitHub action will build the book and publish it [here](https://pages.github.nrel.gov/MBAP/mbap-computing/) \ No newline at end of file