Skip to content

Instantly share code, notes, and snippets.

@stephanbuys
Created August 1, 2017 09:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save stephanbuys/0f9c3c824574cdd402f29ed34d7c388c to your computer and use it in GitHub Desktop.
Save stephanbuys/0f9c3c824574cdd402f29ed34d7c388c to your computer and use it in GitHub Desktop.
# Check out a copy of Diesel git clone https://github.com/diesel-rs/diesel.git
cd diesel/examples/postgres/getting_started_step_3/
# Build the example (assuming your postgres instance is ready
# and running; see the docker hint above)
echo DATABASE_URL=postgres://username:password@localhost/diesel_demo > .env
diesel setup
cargo build
# Expand the code (assuming cargo-expand is installed)
cargo expand --lib > expanded.rs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment