diff --git a/README.md b/README.md index bc0aa07cc..b2e40e9e0 100644 --- a/README.md +++ b/README.md @@ -32,12 +32,12 @@ Scarb is under active development! Expect a lot of new features to appear soon! - [x] Nightlies - [x] `Scarb.lock` - [x] `scarb update` +- [x] `scarb check` - [ ] Standardized `test` target 🏗️ - [ ] Package registry 🏗️ - [ ] PubGrub implementation for version resolution - [ ] Dynamic loading of custom Cairo compiler plugins as Scarb packages 🏗️ - [ ] Dynamic loading of custom targets aka code generators -- [ ] `scarb check` 🏗️ - [ ] Dependency overrides - [ ] Signing & notarization of Windows & macOS binaries - [ ] `scarb doc` diff --git a/website/docs/cheatsheet.md b/website/docs/cheatsheet.md index 0b94c0ffb..d6bfba2b6 100644 --- a/website/docs/cheatsheet.md +++ b/website/docs/cheatsheet.md @@ -27,6 +27,10 @@ Built Sierra code of this package will be written to `target/dev` directory. > [!TIP] > `scarb clean` cleans `target` directory. + +> [!TIP] +> `scarb check` checks for errors without compiling the packages. + ### Building CASM Add following to `Scarb.toml`: diff --git a/website/docs/guides/working-on-an-existing-package.md b/website/docs/guides/working-on-an-existing-package.md index e5b6a2cbc..b0c179b1b 100644 --- a/website/docs/guides/working-on-an-existing-package.md +++ b/website/docs/guides/working-on-an-existing-package.md @@ -31,3 +31,20 @@ $ scarb build ``` This will fetch all the dependencies and then build them, along with the package. + +You might want to simply check the package and all of its dependencies for errors without performing the final step of output files generation. +Instead of `scarb build`, you can use a bit faster command - `scarb check`: + +```shell +$ scarb check + Checking alexandria_ascii v0.1.0 (/path/to/package/alexandria/src/ascii/Scarb.toml) + Checking alexandria_data_structures v0.1.0 (/path/to/package/alexandria/src/data_structures/Scarb.toml) + Checking alexandria_encoding v0.1.0 (/path/to/package/alexandria/src/encoding/Scarb.toml) + Checking alexandria_linalg v0.1.0 (/path/to/package/alexandria/src/linalg/Scarb.toml) + Checking alexandria_math v0.2.0 (/path/to/package/alexandria/src/math/Scarb.toml) + Checking alexandria_numeric v0.1.0 (/path/to/package/alexandria/src/numeric/Scarb.toml) + Checking alexandria_searching v0.1.0 (/path/to/package/alexandria/src/searching/Scarb.toml) + Checking alexandria_sorting v0.1.0 (/path/to/package/alexandria/src/sorting/Scarb.toml) + Checking alexandria_storage v0.2.0 (/path/to/package/alexandria/src/storage/Scarb.toml) + Finished checking release target(s) in 4 seconds +```