This Bash script automatically creates a project structure using Tauri and Leptos.
Before using the script, make sure you have the following dependencies installed:
- Rust & Cargo → Install Rust
- Trunk → Install via
cargo install trunk
- Tauri CLI → Install via
cargo install tauri-cli
- Save the script to a file, e.g.,
setup_project.sh
. - Grant execution permissions:
chmod +x setup_project.sh
- Run the script:
./setup_project.sh
- Enter the project name and path.
After executing the script, the following structure will be created:
project_name/
│── backend/
│ ├── src/
│ ├── Cargo.toml
│ ├── src-tauri/
│── frontend/
│ ├── src/
│ ├── Cargo.toml
│ ├── index.html
│── Cargo.toml (workspace)
│── libs/
Once the project is created, use the following commands:
- Start the frontend (Leptos):
cd project_name/frontend && trunk serve
- Start the backend (Tauri):
cd project_name/backend/src-tauri && cargo tauri dev
✅ Your project is now ready for development! 🚀