monoco-toolkit 0.3.1__py3-none-any.whl → 0.3.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- monoco/core/resources/en/AGENTS.md +25 -0
- monoco/core/resources/en/SKILL.md +32 -1
- monoco/core/resources/zh/AGENTS.md +25 -0
- monoco/core/resources/zh/SKILL.md +32 -0
- monoco/features/i18n/core.py +31 -11
- {monoco_toolkit-0.3.1.dist-info → monoco_toolkit-0.3.2.dist-info}/METADATA +1 -1
- {monoco_toolkit-0.3.1.dist-info → monoco_toolkit-0.3.2.dist-info}/RECORD +10 -10
- {monoco_toolkit-0.3.1.dist-info → monoco_toolkit-0.3.2.dist-info}/WHEEL +0 -0
- {monoco_toolkit-0.3.1.dist-info → monoco_toolkit-0.3.2.dist-info}/entry_points.txt +0 -0
- {monoco_toolkit-0.3.1.dist-info → monoco_toolkit-0.3.2.dist-info}/licenses/LICENSE +0 -0
|
@@ -6,3 +6,28 @@ Core toolkit commands for project management.
|
|
|
6
6
|
- **Config**: `monoco config get|set <key> [value]` (Manage configuration)
|
|
7
7
|
- **Sync**: `monoco sync` (Synchronize with agent environments)
|
|
8
8
|
- **Uninstall**: `monoco uninstall` (Clean up agent integrations)
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## ⚠️ Agent Must-Read: Git Workflow
|
|
13
|
+
|
|
14
|
+
Before modifying any code, **MUST** follow these steps:
|
|
15
|
+
|
|
16
|
+
### Standard Process
|
|
17
|
+
|
|
18
|
+
1. **Create Issue**: `monoco issue create feature -t "Feature Title"`
|
|
19
|
+
2. **🔒 Start Isolation**: `monoco issue start FEAT-XXX --branch`
|
|
20
|
+
- ⚠️ **Required** `--branch` flag
|
|
21
|
+
- ❌ Never modify code directly on `main`/`master` branches
|
|
22
|
+
3. **Implement**: Code and test normally
|
|
23
|
+
4. **Sync Files**: `monoco issue sync-files` (must run before commit)
|
|
24
|
+
5. **Submit Review**: `monoco issue submit FEAT-XXX`
|
|
25
|
+
6. **Close Issue**: `monoco issue close FEAT-XXX --solution implemented`
|
|
26
|
+
|
|
27
|
+
### Quality Gates
|
|
28
|
+
|
|
29
|
+
- Git Hooks auto-run `monoco issue lint` and tests
|
|
30
|
+
- Don't bypass with `git commit --no-verify`
|
|
31
|
+
- Linter blocks direct modifications on protected branches
|
|
32
|
+
|
|
33
|
+
> 📖 See `monoco-issue` skill for complete workflow documentation.
|
|
@@ -34,7 +34,6 @@ Monoco is a developer productivity toolkit that provides:
|
|
|
34
34
|
### Agent Integration
|
|
35
35
|
|
|
36
36
|
- **`monoco sync`**: Synchronize with agent environments
|
|
37
|
-
|
|
38
37
|
- Injects system prompts into agent configuration files (GEMINI.md, CLAUDE.md, etc.)
|
|
39
38
|
- Distributes skills to agent framework directories
|
|
40
39
|
- Respects language configuration from `i18n.source_lang`
|
|
@@ -43,6 +42,24 @@ Monoco is a developer productivity toolkit that provides:
|
|
|
43
42
|
- Removes managed blocks from agent configuration files
|
|
44
43
|
- Cleans up distributed skills
|
|
45
44
|
|
|
45
|
+
### Git Workflow Integration
|
|
46
|
+
|
|
47
|
+
Monoco enforces a **Feature Branch Workflow** to ensure code isolation and quality:
|
|
48
|
+
|
|
49
|
+
- **`monoco init`**: Automatically installs Git Hooks
|
|
50
|
+
- **pre-commit**: Runs Issue Linter and code formatting checks
|
|
51
|
+
- **pre-push**: Executes test suite and integrity validation
|
|
52
|
+
- All hooks configurable via `.monoco/config.yaml`
|
|
53
|
+
|
|
54
|
+
- **Branch Isolation Strategy**:
|
|
55
|
+
- ⚠️ **Required**: Use `monoco issue start <ID> --branch` to create isolated environment
|
|
56
|
+
- Auto-generates normalized branch names: `feat/<id>-<slug>`
|
|
57
|
+
- **Main Protection**: Linter blocks direct code modifications on `main`/`master` branches
|
|
58
|
+
|
|
59
|
+
- **File Tracking**: `monoco issue sync-files` auto-syncs Git changes to Issue metadata
|
|
60
|
+
|
|
61
|
+
> 📖 **Detailed Workflow**: See `monoco-issue` skill for complete Issue lifecycle management guide.
|
|
62
|
+
|
|
46
63
|
## Configuration Structure
|
|
47
64
|
|
|
48
65
|
Configuration is stored in YAML format at:
|
|
@@ -60,7 +77,21 @@ Key configuration sections:
|
|
|
60
77
|
|
|
61
78
|
## Best Practices
|
|
62
79
|
|
|
80
|
+
### Basic Operations
|
|
81
|
+
|
|
63
82
|
1. **Use CLI commands** instead of manual file editing when possible
|
|
64
83
|
2. **Run `monoco sync`** after configuration changes to update agent environments
|
|
65
84
|
3. **Commit `.monoco/config.yaml`** to version control for team consistency
|
|
66
85
|
4. **Keep global config minimal** - most settings should be project-specific
|
|
86
|
+
|
|
87
|
+
### Git Workflow (⚠️ CRITICAL for Agents)
|
|
88
|
+
|
|
89
|
+
5. **Strictly follow branch isolation**:
|
|
90
|
+
- ✅ Always use: `monoco issue start <ID> --branch`
|
|
91
|
+
- ❌ Never modify code directly on `main`/`master` branches
|
|
92
|
+
- 📝 Before commit: Run `monoco issue sync-files` to update file tracking
|
|
93
|
+
|
|
94
|
+
6. **Quality Gates**:
|
|
95
|
+
- Git Hooks will auto-run checks, don't bypass (`--no-verify`)
|
|
96
|
+
- Ensure `monoco issue lint` passes before committing
|
|
97
|
+
- Use `monoco issue submit` to generate delivery reports
|
|
@@ -6,3 +6,28 @@
|
|
|
6
6
|
- **配置**: `monoco config get|set <key> [value]` (管理配置)
|
|
7
7
|
- **同步**: `monoco sync` (与 agent 环境同步)
|
|
8
8
|
- **卸载**: `monoco uninstall` (清理 agent 集成)
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## ⚠️ Agent 必读: Git 工作流
|
|
13
|
+
|
|
14
|
+
在修改任何代码前,**必须**遵循以下步骤:
|
|
15
|
+
|
|
16
|
+
### 标准流程
|
|
17
|
+
|
|
18
|
+
1. **创建 Issue**: `monoco issue create feature -t "功能标题"`
|
|
19
|
+
2. **🔒 启动隔离环境**: `monoco issue start FEAT-XXX --branch`
|
|
20
|
+
- ⚠️ **强制要求** `--branch` 参数
|
|
21
|
+
- ❌ 禁止在 `main`/`master` 分支直接修改代码
|
|
22
|
+
3. **实现功能**: 正常编码和测试
|
|
23
|
+
4. **同步文件**: `monoco issue sync-files` (提交前必须运行)
|
|
24
|
+
5. **提交审查**: `monoco issue submit FEAT-XXX`
|
|
25
|
+
6. **关闭 Issue**: `monoco issue close FEAT-XXX --solution implemented`
|
|
26
|
+
|
|
27
|
+
### 质量门禁
|
|
28
|
+
|
|
29
|
+
- Git Hooks 会自动运行 `monoco issue lint` 和测试
|
|
30
|
+
- 不要使用 `git commit --no-verify` 绕过检查
|
|
31
|
+
- Linter 会阻止在受保护分支上的直接修改
|
|
32
|
+
|
|
33
|
+
> 📖 详见 `monoco-issue` skill 获取完整工作流文档。
|
|
@@ -42,6 +42,24 @@ Monoco 是一个开发者生产力工具包,提供:
|
|
|
42
42
|
- 从 agent 配置文件中移除托管块
|
|
43
43
|
- 清理已分发的 skills
|
|
44
44
|
|
|
45
|
+
### Git 工作流集成
|
|
46
|
+
|
|
47
|
+
Monoco 强制执行 **Feature Branch 工作流**以确保代码隔离和质量:
|
|
48
|
+
|
|
49
|
+
- **`monoco init`**: 自动安装 Git Hooks
|
|
50
|
+
- **pre-commit**: 运行 Issue Linter 和代码格式检查
|
|
51
|
+
- **pre-push**: 执行测试套件和完整性验证
|
|
52
|
+
- 所有 Hooks 可通过 `.monoco/config.yaml` 配置
|
|
53
|
+
|
|
54
|
+
- **分支隔离策略**:
|
|
55
|
+
- ⚠️ **强制要求**: 使用 `monoco issue start <ID> --branch` 创建隔离环境
|
|
56
|
+
- 自动创建规范化分支名: `feat/<id>-<slug>`
|
|
57
|
+
- **主干保护**: Linter 会阻止在 `main`/`master` 分支上的直接代码修改
|
|
58
|
+
|
|
59
|
+
- **文件追踪**: `monoco issue sync-files` 自动同步 Git 变更到 Issue 元数据
|
|
60
|
+
|
|
61
|
+
> 📖 **详细工作流**: 参见 `monoco-issue` skill 获取完整的 Issue 生命周期管理指南。
|
|
62
|
+
|
|
45
63
|
## 配置结构
|
|
46
64
|
|
|
47
65
|
配置以 YAML 格式存储在:
|
|
@@ -59,7 +77,21 @@ Monoco 是一个开发者生产力工具包,提供:
|
|
|
59
77
|
|
|
60
78
|
## 最佳实践
|
|
61
79
|
|
|
80
|
+
### 基础操作
|
|
81
|
+
|
|
62
82
|
1. **优先使用 CLI 命令**,而不是手动编辑文件
|
|
63
83
|
2. **配置更改后运行 `monoco sync`** 以更新 agent 环境
|
|
64
84
|
3. **将 `.monoco/config.yaml` 提交到版本控制**,保持团队一致性
|
|
65
85
|
4. **保持全局配置最小化** - 大多数设置应该是项目特定的
|
|
86
|
+
|
|
87
|
+
### Git 工作流 (⚠️ CRITICAL for Agents)
|
|
88
|
+
|
|
89
|
+
5. **严格遵循分支隔离**:
|
|
90
|
+
- ✅ 始终使用: `monoco issue start <ID> --branch`
|
|
91
|
+
- ❌ 禁止在 `main`/`master` 分支直接修改代码
|
|
92
|
+
- 📝 提交前运行: `monoco issue sync-files` 更新文件追踪
|
|
93
|
+
|
|
94
|
+
6. **质量门禁**:
|
|
95
|
+
- Git Hooks 会自动运行检查,不要尝试绕过 (`--no-verify`)
|
|
96
|
+
- 提交前确保 `monoco issue lint` 通过
|
|
97
|
+
- 使用 `monoco issue submit` 生成交付报告
|
monoco/features/i18n/core.py
CHANGED
|
@@ -24,6 +24,13 @@ DEFAULT_EXCLUDES = [
|
|
|
24
24
|
".vscode",
|
|
25
25
|
".idea",
|
|
26
26
|
".fleet",
|
|
27
|
+
".vscode-test",
|
|
28
|
+
".cache",
|
|
29
|
+
".mypy_cache",
|
|
30
|
+
".pytest_cache",
|
|
31
|
+
".ruff_cache",
|
|
32
|
+
".tox",
|
|
33
|
+
".nox",
|
|
27
34
|
# System Prompts & Agent Configs
|
|
28
35
|
"AGENTS.md",
|
|
29
36
|
"CLAUDE.md",
|
|
@@ -55,17 +62,16 @@ def load_gitignore_patterns(root: Path) -> List[str]:
|
|
|
55
62
|
|
|
56
63
|
|
|
57
64
|
def is_excluded(
|
|
58
|
-
path: Path, root: Path, patterns: List[str],
|
|
65
|
+
path: Path, root: Path, patterns: List[str], excludes_set: Optional[set] = None
|
|
59
66
|
) -> bool:
|
|
60
67
|
"""Check if a path should be excluded based on patterns and defaults."""
|
|
61
68
|
rel_path = str(path.relative_to(root))
|
|
62
69
|
|
|
63
|
-
final_excludes = excludes if excludes is not None else DEFAULT_EXCLUDES
|
|
64
|
-
|
|
65
70
|
# 1. Check default excludes (exact match for any path component, case-insensitive)
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
71
|
+
if excludes_set:
|
|
72
|
+
for part in path.parts:
|
|
73
|
+
if part.lower() in excludes_set:
|
|
74
|
+
return True
|
|
69
75
|
|
|
70
76
|
# 2. Check gitignore patterns
|
|
71
77
|
for pattern in patterns:
|
|
@@ -98,11 +104,25 @@ def discover_markdown_files(root: Path, include_issues: bool = False) -> List[Pa
|
|
|
98
104
|
if not include_issues:
|
|
99
105
|
excludes.append("Issues")
|
|
100
106
|
|
|
101
|
-
#
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
107
|
+
# Pre-calculate lowercase set for performance
|
|
108
|
+
excludes_set = {e.lower() for e in excludes}
|
|
109
|
+
|
|
110
|
+
# Use walk to skip excluded directories early
|
|
111
|
+
for current_root, dirs, files in root.walk():
|
|
112
|
+
# Filter directories in-place to skip excluded ones
|
|
113
|
+
dirs[:] = [
|
|
114
|
+
d
|
|
115
|
+
for d in dirs
|
|
116
|
+
if not is_excluded(
|
|
117
|
+
current_root / d, root, patterns, excludes_set=excludes_set
|
|
118
|
+
)
|
|
119
|
+
]
|
|
120
|
+
|
|
121
|
+
for file in files:
|
|
122
|
+
if file.endswith(".md"):
|
|
123
|
+
p = current_root / file
|
|
124
|
+
if not is_excluded(p, root, patterns, excludes_set=excludes_set):
|
|
125
|
+
all_md_files.append(p)
|
|
106
126
|
|
|
107
127
|
return sorted(all_md_files)
|
|
108
128
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: monoco-toolkit
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.2
|
|
4
4
|
Summary: Agent Native Toolkit for Monoco - Task Management & Kanban for AI Agents
|
|
5
5
|
Project-URL: Homepage, https://monoco.io
|
|
6
6
|
Project-URL: Repository, https://github.com/IndenScale/Monoco
|
|
@@ -24,10 +24,10 @@ monoco/core/agent/action.py,sha256=qkQGJERhL4N5MSuwDivn8NAw4sMhEa346huGtqNyFTM,5
|
|
|
24
24
|
monoco/core/agent/adapters.py,sha256=q6obVcXve46mVNBaSCBRFRYs8gImv6Y2gAJVv173Z6w,4376
|
|
25
25
|
monoco/core/agent/protocol.py,sha256=eB0OiMjDQu1DOoeVqb_PpHsMyPy2LdNenNyt4vJ9qbQ,798
|
|
26
26
|
monoco/core/agent/state.py,sha256=Z8qqY7loms5nt3524_TrEMmlpnurxf0aHfiCT1FgvDI,3385
|
|
27
|
-
monoco/core/resources/en/AGENTS.md,sha256=
|
|
28
|
-
monoco/core/resources/en/SKILL.md,sha256=
|
|
29
|
-
monoco/core/resources/zh/AGENTS.md,sha256=
|
|
30
|
-
monoco/core/resources/zh/SKILL.md,sha256=
|
|
27
|
+
monoco/core/resources/en/AGENTS.md,sha256=vf9z43UU-LPwYKPWCrtw8TpWrmkeZ6zfMyHP4Q9JqdQ,1178
|
|
28
|
+
monoco/core/resources/en/SKILL.md,sha256=wBXNpPqATOxO8TGiOM8S091gMNZ8du_WhQubO6TfNyg,3504
|
|
29
|
+
monoco/core/resources/zh/AGENTS.md,sha256=KBNZSCPBIals6jDdvG5wJgjZuswi_1nKljggJSMtfy8,1156
|
|
30
|
+
monoco/core/resources/zh/SKILL.md,sha256=1D8_FqzDVqowZWk4Qkyx4me53NTd8qihP20gaCH6gJY,3153
|
|
31
31
|
monoco/daemon/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
32
32
|
monoco/daemon/app.py,sha256=tAtLxzw_aRzU0r6Bk9lhshaCyqZRkQKUJmg5FDi7-1c,15431
|
|
33
33
|
monoco/daemon/commands.py,sha256=2AGsqDZ0edg34KuAGZrTvKlJZ1fhxNXgus7vGn2km4c,1115
|
|
@@ -40,7 +40,7 @@ monoco/features/config/commands.py,sha256=i6_fKhSGLeO8RCbWrYKxelFgaHWcPiQERS2uxU
|
|
|
40
40
|
monoco/features/i18n/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
41
41
|
monoco/features/i18n/adapter.py,sha256=-ifDKQ7UH8tDoOdB_fSKoIrNRJROIPNuzZor2FPJVfo,932
|
|
42
42
|
monoco/features/i18n/commands.py,sha256=NJ2lZRRjiTW-3UbqxhEKURdWSDxQPkfnBAUgnwoVCL8,8416
|
|
43
|
-
monoco/features/i18n/core.py,sha256=
|
|
43
|
+
monoco/features/i18n/core.py,sha256=bnEV9D7KgxbC5I3l-1RN1-H8hek1loDL6KFXzmdq0pQ,9658
|
|
44
44
|
monoco/features/i18n/resources/en/AGENTS.md,sha256=zzuF7BW6x8Mj6LZZmeM6wTbG5CSCDMShf4rwtN7XITg,197
|
|
45
45
|
monoco/features/i18n/resources/en/SKILL.md,sha256=Z8fAAqeMvpLDw1D_9AzZIykS5-HLVM9nnlRZLWBTPqM,2203
|
|
46
46
|
monoco/features/i18n/resources/zh/AGENTS.md,sha256=lKkwLLCADRH7UDq9no4eQY2sRfJrb64JoZ_HNved8vA,175
|
|
@@ -77,8 +77,8 @@ monoco/features/spike/resources/en/AGENTS.md,sha256=NG3CMnlDk_0J8hnRUcueAM9lgIQr
|
|
|
77
77
|
monoco/features/spike/resources/en/SKILL.md,sha256=qKDcVh0D3pDRvfNLh1Bzo4oQU3obpl4tqdlzxeiWYMk,1911
|
|
78
78
|
monoco/features/spike/resources/zh/AGENTS.md,sha256=5RHNl7fc3RdYYTFH483ojJl_arGPKkyYziOuGgFbqqg,290
|
|
79
79
|
monoco/features/spike/resources/zh/SKILL.md,sha256=Q82e9lCQOAYIwBs5rGnvlVUDq7bp0pz8yvO10KTWFYQ,1710
|
|
80
|
-
monoco_toolkit-0.3.
|
|
81
|
-
monoco_toolkit-0.3.
|
|
82
|
-
monoco_toolkit-0.3.
|
|
83
|
-
monoco_toolkit-0.3.
|
|
84
|
-
monoco_toolkit-0.3.
|
|
80
|
+
monoco_toolkit-0.3.2.dist-info/METADATA,sha256=9Xyk-ImLkR4WvBAz6eQb8_N-QZiJ7TPu27P3u48Y35c,4866
|
|
81
|
+
monoco_toolkit-0.3.2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
82
|
+
monoco_toolkit-0.3.2.dist-info/entry_points.txt,sha256=iYj7FWYBdtClU15-Du1skqD0s6SFSIhJvxJ29VWp8ng,43
|
|
83
|
+
monoco_toolkit-0.3.2.dist-info/licenses/LICENSE,sha256=ACAGGjV6aod4eIlVUTx1q9PZbnZGN5bBwkSs9RHj83s,1071
|
|
84
|
+
monoco_toolkit-0.3.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|