mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-04-02 20:09:00 +08:00
- 引入基于YAML和JSON Schema的静态内容配置系统 - 实现运行时只读查询和Source Generator支持 - 提供VS Code扩展用于配置浏览、验证和轻量编辑 - 支持开发期热重载和跨表引用校验功能 - 包含完整的文档说明和工具链集成
42 lines
1.2 KiB
Markdown
42 lines
1.2 KiB
Markdown
# GFramework Config Tools
|
|
|
|
Minimal VS Code extension scaffold for the GFramework AI-First config workflow.
|
|
|
|
## Current MVP
|
|
|
|
- Browse config files from the workspace `config/` directory
|
|
- Open raw YAML files
|
|
- Open matching schema files from `schemas/`
|
|
- Run lightweight schema validation for required fields, unknown top-level fields, scalar types, and scalar array items
|
|
- Open a lightweight form preview for top-level scalar fields
|
|
|
|
## Validation Coverage
|
|
|
|
The extension currently validates the repository's minimal config-schema subset:
|
|
|
|
- required top-level properties
|
|
- unknown top-level properties
|
|
- scalar compatibility for `integer`, `number`, `boolean`, and `string`
|
|
- top-level scalar arrays with scalar item type checks
|
|
|
|
Nested objects and complex arrays should still be reviewed in raw YAML.
|
|
|
|
## Local Testing
|
|
|
|
```bash
|
|
cd tools/vscode-config-extension
|
|
node --test ./test/*.test.js
|
|
```
|
|
|
|
## Current Constraints
|
|
|
|
- Multi-root workspaces use the first workspace folder
|
|
- Validation only covers a minimal subset of JSON Schema
|
|
- Form editing currently supports top-level scalar fields only
|
|
- Arrays and nested objects should still be edited in raw YAML
|
|
|
|
## Workspace Settings
|
|
|
|
- `gframeworkConfig.configPath`
|
|
- `gframeworkConfig.schemasPath`
|