Move main.rs to examples/postgres

This commit is contained in:
Ryan Leckey 2019-07-26 09:20:09 -07:00
parent de52268668
commit 7c70445e3d
2 changed files with 5 additions and 0 deletions

View File

@ -16,4 +16,7 @@ log = "0.4.7"
md-5 = "0.8.0"
memchr = "2.2.1"
runtime = { version = "=0.3.0-alpha.6", default-features = false }
[dev-dependencies]
runtime-tokio = { version = "=0.3.0-alpha.5" }
env_logger = "0.6.2"

View File

@ -9,6 +9,8 @@ use std::io;
#[runtime::main(runtime_tokio::Tokio)]
async fn main() -> io::Result<()> {
env_logger::init();
// Connect as postgres / postgres and DROP the sqlx__dev database
// if exists and then re-create it
let mut conn = Connection::establish(