@comate/zulu 1.5.0 → 1.5.2
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.
- package/README.md +2 -0
- package/comate-engine/assets/skills/{automation-browser → browser-use}/SKILL.md +1 -1
- package/comate-engine/assets/skills/code-security/SKILL.md +1 -1
- package/comate-engine/assets/skills/code-security/references/vul_repair_sensitive.md +103 -16
- package/comate-engine/assets/skills/create-automation/SKILL.md +185 -222
- package/comate-engine/assets/skills/create-image/SKILL.md +7 -2
- package/comate-engine/assets/skills/figma2code/SKILL.md +8 -4
- package/comate-engine/assets/skills/icode/references/feature/submit-cr.md +1 -1
- package/comate-engine/assets/skills/icode/scripts/build_git_commit_payload.py +19 -1
- package/comate-engine/node_modules/@comate/plugin-shared-internals/dist/index.js +1 -1
- package/comate-engine/node_modules/sqlite-vec/index.cjs +0 -0
- package/comate-engine/node_modules/sqlite-vec/index.mjs +0 -0
- package/comate-engine/node_modules/sqlite-vec/package.json +0 -0
- package/comate-engine/node_modules/sqlite-vec-darwin-arm64/package.json +0 -0
- package/comate-engine/node_modules/sqlite-vec-darwin-x64/package.json +0 -0
- package/comate-engine/node_modules/sqlite-vec-linux-arm64/package.json +0 -0
- package/comate-engine/node_modules/sqlite-vec-linux-x64/package.json +0 -0
- package/comate-engine/node_modules/sqlite-vec-windows-x64/package.json +0 -0
- package/comate-engine/package.json +1 -1
- package/comate-engine/server.js +18 -18
- package/dist/bundle/index.js +4 -4
- package/package.json +1 -1
|
@@ -43,6 +43,22 @@ def _get_current_branch(workspace):
|
|
|
43
43
|
return ""
|
|
44
44
|
|
|
45
45
|
|
|
46
|
+
def _get_upstream_branch(workspace):
|
|
47
|
+
"""获取当前分支的上游远端分支名(strip remote 前缀)"""
|
|
48
|
+
try:
|
|
49
|
+
result = subprocess.run(
|
|
50
|
+
["git", "rev-parse", "--abbrev-ref", "--symbolic-full-name", "@{upstream}"],
|
|
51
|
+
capture_output=True, text=True, encoding="utf-8", errors="replace",
|
|
52
|
+
timeout=10, cwd=workspace
|
|
53
|
+
)
|
|
54
|
+
if result.returncode == 0 and result.stdout.strip():
|
|
55
|
+
upstream = result.stdout.strip()
|
|
56
|
+
return upstream.split("/", 1)[-1] if "/" in upstream else upstream
|
|
57
|
+
except (subprocess.TimeoutExpired, FileNotFoundError, OSError):
|
|
58
|
+
pass
|
|
59
|
+
return ""
|
|
60
|
+
|
|
61
|
+
|
|
46
62
|
def _get_remote_branches(workspace, current_branch):
|
|
47
63
|
try:
|
|
48
64
|
result = subprocess.run(
|
|
@@ -74,7 +90,9 @@ def _build_workspace_entry(workspace_path, diff_info):
|
|
|
74
90
|
repo_name = os.path.basename(workspace_path)
|
|
75
91
|
|
|
76
92
|
if has_changes:
|
|
77
|
-
|
|
93
|
+
local_branch = _get_current_branch(workspace_path)
|
|
94
|
+
upstream_branch = _get_upstream_branch(workspace_path)
|
|
95
|
+
current_branch = upstream_branch or local_branch
|
|
78
96
|
remote_branches = _get_remote_branches(workspace_path, current_branch)
|
|
79
97
|
diff_summary = {
|
|
80
98
|
"changed_files": diff_info.get("changed_files", []),
|