diff --git a/src/main.rs b/src/main.rs index c1e8c22..dfa0db3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -13,11 +13,9 @@ Usage: dbdash --sqlite PATH dbdash --help -Run without a connection argument and without DATABASE_URL to connect in-app. -Otherwise DATABASE_URL supplies the PostgreSQL connection when no argument is given. -Prefer the environment variable to keep passwords out of process arguments: - export DATABASE_URL='postgresql://user@localhost:5432/database' +Run without a connection argument to open the in-app connection screen: cargo run +Use the in-app password field to keep credentials out of process arguments. Open an existing SQLite database file (read-only; missing files are not created): cargo run -- --sqlite ./database.sqlite @@ -78,7 +76,7 @@ fn run() -> Result<()> { .ok_or("--sqlite requires a database file path; see dbdash --help")?, ) } else { - argument.or_else(|| std::env::var_os("DATABASE_URL")) + argument }; if args.next().is_some() { return Err("unexpected extra arguments; see dbdash --help".into());