Todo list cli app build with Rust
- Make sure you have Postgres running.
- Make sure you have installed
diesel-cli. This project is using posgresql as the main DBcargo install diesel_cli --no-default-features --features postgresNotes:
Sometimes you need to installlibpqfor supporting postgres backend - Creating
.envfile. reference:.env.example - Set
DATABASE_URLin the.envfile. - Initialize diesel using:
diesel setup. - Run the migration using:
diesel migration run.
- Install dependency and build app using cargo
cargo build --release
- Create a copy or link to
target/release/rustodo. I prefer using symlink.ln -s target/release/rustodo rustodo - Run the app
# Run interactively using: ./rustodo # Or ./rustodo add "Create new todo list api" "Testing todo list app" ./rustodo list