Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ A extreme lightweight SQLite Web administration tool based on Rust (Axum) and So
- ⚡ **High Performance**: Runtime memory usage is only **~1MB**.
- 🤖 **AI Assistant**: Intelligently corrects wrong SQL, supports natural language to SQL conversion.

![instruction](instruction.jpg)

![screenshot](screenshot.png)

## Tech Stack
Expand Down
2 changes: 2 additions & 0 deletions README_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
- ⚡ **高性能**: 运行时内存占用仅 **~1MB**。
- 🤖 **AI 辅助**: 智能纠正错误 SQL,支持自然语言转 SQL。

![介绍](instruction.jpg)

![截图](screenshot.png)

## 技术栈
Expand Down
34 changes: 17 additions & 17 deletions backend/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions backend/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "rust-sqlite-webui"
version = "0.2.1"
version = "0.2.2"
edition = "2024"

[dependencies]
Expand All @@ -14,7 +14,7 @@ tower = "0.5"
tower-http = { version = "0.6", features = ["cors", "fs", "trace"] }
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
clap = { version = "4.5", features = ["derive"] }
clap = { version = "4.6", features = ["derive"] }
reqwest = { version = "0.13.2", features = ["json"] }

[profile.release]
Expand Down
10 changes: 7 additions & 3 deletions backend/src/handlers/connection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use axum::{
};
use serde::Deserialize;
use sqlx::SqlitePool;
use sqlx::sqlite::SqliteConnectOptions;
use sqlx::sqlite::{SqliteConnectOptions, SqliteJournalMode};
use crate::state::AppState;
use std::path::Path;

Expand Down Expand Up @@ -34,7 +34,10 @@ pub async fn list_dbs() -> impl IntoResponse {
if let Ok(file_type) = entry.file_type() {
if file_type.is_file() {
if let Some(name) = entry.file_name().to_str() {
files.push(name.to_string());
// Filter out -wal and -shm files
if !name.ends_with("-wal") && !name.ends_with("-shm") {
files.push(name.to_string());
}
}
}
}
Expand Down Expand Up @@ -73,7 +76,8 @@ pub async fn connect_db(

let options = SqliteConnectOptions::new()
.filename(&full_path)
.create_if_missing(payload.create);
.create_if_missing(payload.create)
.journal_mode(SqliteJournalMode::Wal);

match SqlitePool::connect_with(options).await {
Ok(pool) => {
Expand Down
8 changes: 4 additions & 4 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
"build": "vite build"
},
"devDependencies": {
"@tailwindcss/vite": "^4.1.18",
"@tailwindcss/vite": "^4.2.2",
"@types/node": "^25",
"daisyui": "^5.5.19",
"solid-devtools": "^0.34.5",
"solid-js": "^1.9.11",
"solid-js": "^1.9.12",
"tailwindcss": "^4.2.2",
"typescript": "^5.9.3",
"typescript": "^6.0.2",
"vite": "^7.3.0",
"vite-plugin-solid": "^2.11.8"
"vite-plugin-solid": "^2.11.12"
},
"packageManager": "pnpm@10.32.1+sha512.a706938f0e89ac1456b6563eab4edf1d1faf3368d1191fc5c59790e96dc918e4456ab2e67d613de1043d2e8c81f87303e6b40d4ffeca9df15ef1ad567348f2be"
}
Loading
Loading