feat: support double-clicking .db/.sqlite/.duckdb files to open in IDE

Add OS file association for database files (.db, .sqlite, .sqlite3, .duckdb)
so double-clicking them in Finder/Explorer automatically creates a connection.
If the same file path is already connected, prompts the user to switch instead.

Also fix 42 pre-existing clippy warnings in dbx-core (needless_borrow,
too_many_arguments, derivable_impls, manual_div_ceil, type_complexity, etc.).

Closes #527
This commit is contained in:
t8y2 committed 2026-05-29 17:25:52 +08:00
1 parent bbdb21c1e6
commit ef4baba57a
29 files changed
+344 -105

No files matched your search

+1 -3
View File
@@ -650,9 +650,7 @@ fn is_transaction_control(sql: &str) -> bool {
return true;
}
if first.eq_ignore_ascii_case("BEGIN") {
return tokens
.get(1)
.map_or(false, |t| t.eq_ignore_ascii_case("TRANSACTION") || t.eq_ignore_ascii_case("TRAN"));
return tokens.get(1).is_some_and(|t| t.eq_ignore_ascii_case("TRANSACTION") || t.eq_ignore_ascii_case("TRAN"));
}
false
}