Skip to content

Commit db7ef7f

Browse files
author
codeErrorSleep
committed
feat: Integrate automatic update function and add Chinese documentation
- Add tauri-plugin-updater and tauri-plugin-process dependencies to support automatic application updates - Add update check function in the settings dialog box, including automatic update switch and manual check button - Create UpdaterChecker component to automatically check for updates when the application starts and prompt users to install them - Configure update server endpoint (GitHub Releases) and signing public key - Add Chinese version README_CN.md document - Updated permission configuration and dependency lock files to support new plugins
1 parent 84d9d68 commit db7ef7f

12 files changed

Lines changed: 711 additions & 93 deletions

File tree

README.md

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
![DbPaw Logo](public/product-icon.png)
44

5+
English | [简体中文](README_CN.md)
6+
57
> **A modern, AI-powered database client for the new era.**
68
79
[![Release](https://img.shields.io/github/v/release/username/DbPaw?style=flat-square)](https://github.com/username/DbPaw/releases)
@@ -15,14 +17,14 @@
1517
- **🔌 Multi-Database Support**: Connect to **PostgreSQL** and **MySQL** databases with ease.
1618
- **🤖 AI-Powered Assistance**: Integrated AI sidebar to help you write complex SQL queries, explain execution plans, and optimize performance.
1719
- **🔒 Secure Connectivity**: Support for **SSH Tunneling** to securely access remote databases.
18-
- **📝 Advanced SQL Editor**:
20+
- **📝 Advanced SQL Editor**:
1921
- Syntax highlighting and auto-completion.
2022
- **Saved Queries** library to organize your frequently used scripts.
2123
- Format SQL with a single click.
22-
- **📊 Interactive Data Grid**:
24+
- **📊 Interactive Data Grid**:
2325
- View, filter, and sort table data efficiently.
2426
- Visualize data relationships.
25-
- **🎨 Modern UI**:
27+
- **🎨 Modern UI**:
2628
- Beautifully designed with **TailwindCSS** and **Shadcn/UI**.
2729
- Built-in **Dark Mode** support for comfortable coding at night.
2830
- **🚀 High Performance**: Built on Rust, ensuring low memory usage and blazing fast startup times.
@@ -32,6 +34,7 @@
3234
Go to the [Releases](https://github.com/username/DbPaw/releases) page to download the latest version for your operating system.
3335

3436
### macOS Users
37+
3538
If you encounter a "DbPaw is damaged" or "Unidentified Developer" warning upon opening the app:
3639

3740
1. Move `DbPaw.app` to your `/Applications` folder.
@@ -41,37 +44,42 @@ If you encounter a "DbPaw is damaged" or "Unidentified Developer" warning upon o
4144
```
4245
3. You can now open the app normally.
4346

44-
*Note: This is required because the app is not yet notarized by Apple.*
47+
_Note: This is required because the app is not yet notarized by Apple._
4548

4649
## 🛠️ Development
4750

4851
If you want to contribute or build from source, follow these steps:
4952

5053
### Prerequisites
54+
5155
- [Rust](https://www.rust-lang.org/tools/install) (latest stable)
5256
- [Bun](https://bun.sh/) or Node.js (v18+)
5357

5458
### Setup
5559

5660
1. **Clone the repository**
61+
5762
```bash
5863
git clone https://github.com/username/DbPaw.git
5964
cd DbPaw
6065
```
6166

6267
2. **Install frontend dependencies**
68+
6369
```bash
6470
bun install
6571
```
6672

6773
3. **Run in Development Mode**
68-
74+
6975
**Frontend-only (Mock Mode)** - Recommended for UI work:
76+
7077
```bash
7178
bun dev:mock
7279
```
73-
80+
7481
**Full App (Tauri + Rust)** - For full functionality testing:
82+
7583
```bash
7684
bun tauri dev
7785
```

README_CN.md

Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
# DbPaw
2+
3+
![DbPaw Logo](public/product-icon.png)
4+
5+
[English](README.md) | 简体中文
6+
7+
> **一个现代化的 AI 驱动数据库客户端,适用于新时代。**
8+
9+
[![Release](https://img.shields.io/github/v/release/username/DbPaw?style=flat-square)](https://github.com/username/DbPaw/releases)
10+
[![License](https://img.shields.io/badge/license-MIT-blue.svg?style=flat-square)](LICENSE)
11+
[![Platform](https://img.shields.io/badge/platform-macOS%20%7C%20Windows%20%7C%20Linux-lightgrey.svg?style=flat-square)](https://tauri.app)
12+
13+
**DbPaw** 是一个轻量级、跨平台的数据库管理工具,基于 [Tauri](https://tauri.app)[React](https://react.dev) 构建。它结合了原生 Rust 后端的高性能和现代化 Web UI,为您提供无缝的 SQL 编辑和数据探索体验。
14+
15+
## ✨ 特性
16+
17+
- **🔌 多数据库支持**:轻松连接 **PostgreSQL****MySQL** 数据库。
18+
- **🤖 AI 智能辅助**:集成 AI 侧边栏,帮助您编写复杂的 SQL 查询、解释执行计划并优化性能。
19+
- **🔒 安全连接**:支持 **SSH 隧道**,安全访问远程数据库。
20+
- **📝 高级 SQL 编辑器**
21+
- 语法高亮和自动补全。
22+
- **已保存查询**库,用于组织您常用的脚本。
23+
- 一键格式化 SQL。
24+
- **📊 交互式数据网格**
25+
- 高效查看、过滤和排序表数据。
26+
- 可视化数据关系。
27+
- **🎨 现代化 UI**
28+
- 使用 **TailwindCSS****Shadcn/UI** 精心设计。
29+
- 内置**深色模式**支持,夜间编码更舒适。
30+
- **🚀 高性能**:基于 Rust 构建,确保低内存占用和极速启动。
31+
32+
## 📥 安装
33+
34+
前往 [Releases](https://github.com/username/DbPaw/releases) 页面下载适合您操作系统的最新版本。
35+
36+
### macOS 用户
37+
38+
如果在打开应用时遇到"DbPaw 已损坏"或"无法识别的开发者"警告:
39+
40+
1.`DbPaw.app` 移动到 `/Applications` 文件夹。
41+
2. 打开**终端**并运行以下命令:
42+
```bash
43+
sudo xattr -d com.apple.quarantine /Applications/DbPaw.app
44+
```
45+
3. 现在可以正常打开应用。
46+
47+
_注意:这是因为应用尚未经过 Apple 公证。_
48+
49+
## 🛠️ 开发
50+
51+
如果您想贡献代码或从源码构建,请按照以下步骤操作:
52+
53+
### 前提条件
54+
55+
- [Rust](https://www.rust-lang.org/tools/install) (最新稳定版)
56+
- [Bun](https://bun.sh/) 或 Node.js (v18+)
57+
58+
### 设置
59+
60+
1. **克隆仓库**
61+
62+
```bash
63+
git clone https://github.com/username/DbPaw.git
64+
cd DbPaw
65+
```
66+
67+
2. **安装前端依赖**
68+
69+
```bash
70+
bun install
71+
```
72+
73+
3. **运行开发模式**
74+
75+
**仅前端(模拟模式)** - 推荐用于 UI 开发:
76+
77+
```bash
78+
bun dev:mock
79+
```
80+
81+
**完整应用(Tauri + Rust)** - 用于完整功能测试:
82+
83+
```bash
84+
bun tauri dev
85+
```
86+
87+
4. **构建生产版本**
88+
```bash
89+
bun tauri build
90+
```
91+
92+
## 🏗️ 技术栈
93+
94+
- **核心**: [Tauri v2](https://v2.tauri.app/) (Rust)
95+
- **前端**: [React 19](https://react.dev/), [TypeScript](https://www.typescriptlang.org/)
96+
- **样式**: [TailwindCSS v4](https://tailwindcss.com/), [Shadcn/UI](https://ui.shadcn.com/)
97+
- **状态管理**: React Hooks & Context
98+
- **编辑器**: [Monaco Editor](https://microsoft.github.io/monaco-editor/) / CodeMirror
99+
100+
## 📄 许可证
101+
102+
本项目采用 MIT 许可证 - 详情请参阅 [LICENSE](LICENSE) 文件。

bun.lock

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "dbpaw",
33
"private": true,
4-
"version": "0.1.1",
4+
"version": "0.1.2",
55
"type": "module",
66
"scripts": {
77
"dev": "vite",
@@ -48,7 +48,9 @@
4848
"@radix-ui/react-tooltip": "1.1.8",
4949
"@tauri-apps/api": "^2",
5050
"@tauri-apps/plugin-opener": "^2",
51+
"@tauri-apps/plugin-process": "^2.3.1",
5152
"@tauri-apps/plugin-store": "^2.4.2",
53+
"@tauri-apps/plugin-updater": "^2.10.0",
5254
"@uiw/react-codemirror": "^4.25.4",
5355
"class-variance-authority": "0.7.1",
5456
"clsx": "2.1.1",

0 commit comments

Comments
 (0)