4 releases
new 0.2.0 | Jan 5, 2025 |
---|---|
0.1.2 | Jan 5, 2025 |
0.1.1 | Jan 4, 2025 |
0.1.0 | Jan 4, 2025 |
#100 in Games
301 downloads per month
42KB
1K
SLoC
Sabita (錆びた)
Sabita is a Sudoku solver / generator made with Rust
'Sabita' (錆びた) means 'rusty' in japanese
CLI
Install
You will need to install Rust
cargo install sabita
Use
# Generator
sabita g file/to/create # Generate a sudoku with no missing value
sabita g file/to/create 50 # Generate a sudoku with 50 missing values
# Solver
sabita s file/to/solve # Solve the sudoku (check out file sudoku.example) to see format
# Benchmark
sabita --benchmark # Launch the benchmarking script, see section below
Performances
Performances are benchmarked through the src/core/benchmark.rs
and the results are written in the benchmark.log
file
Dev
Commands
Many aliases and sequences are handled through cargo-make you will need to install it
cargo run # Builds and run the project
cargo fmt # Format code
cargo fmt -- --check # Throw error if unformated code
cargo clippy # Advanced linter
cargo clippy --fix # Fix auto fixable
cargo build # Only build it
cargo test # Run all unit tests
cargo test <file without extension> # Run specific test file inside the 'tests' folder (don't write it in path)
cargo test <specific function name> # Run specific test function
cargo add <package> [--dev] # Install a project dependency (or a dev dependency)
cargo install <package> # Install a system wide dependency
cargo doc # Generates HTML documentation
cargo clean # Remove 'targer' directory (build artifacts, doc ...)
cargo publish # Publish project to crates.io registry
Git hooks
Git hooks are handled with rusty-hook, to enable them after a fresh install, run cargo build
Tasks
Using CLI-Manager for task handling.
Dependencies
~1MB
~19K SLoC