@hupan56/wlkj 2.4.3 → 2.4.4
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/package.json
CHANGED
|
@@ -193,6 +193,12 @@ def do_pull(quiet=False):
|
|
|
193
193
|
print('Already up to date.')
|
|
194
194
|
else:
|
|
195
195
|
print('Pulled latest from team.')
|
|
196
|
+
# 拉到队友的新 PRD → 自动 collect 到 data/docs/prd/ (历史归档)
|
|
197
|
+
try:
|
|
198
|
+
from git_sync import collect_prds
|
|
199
|
+
collect_prds()
|
|
200
|
+
except Exception:
|
|
201
|
+
pass # collect 失败不阻塞 pull
|
|
196
202
|
return 0
|
|
197
203
|
|
|
198
204
|
|
|
@@ -382,6 +388,13 @@ def _do_push_locked(message, dev, skip_eval, skip_secret):
|
|
|
382
388
|
if r.returncode == 0:
|
|
383
389
|
touch_pull_marker()
|
|
384
390
|
print('Synced to team. (attempt {})'.format(attempt))
|
|
391
|
+
# push 成功后, 自动 collect PRD 到 data/docs/prd/ (历史归档)
|
|
392
|
+
# 这样 search_index --prd 能立刻搜到新 PRD, 不用等周五 cron
|
|
393
|
+
try:
|
|
394
|
+
from git_sync import collect_prds
|
|
395
|
+
collect_prds()
|
|
396
|
+
except Exception as e:
|
|
397
|
+
print('[sync] PRD 归档跳过 (不阻塞): ' + str(e)[:80])
|
|
385
398
|
# D2: 检测 PRD 发布并推飞书通知
|
|
386
399
|
_notify_prd_publications(staged_files)
|
|
387
400
|
return 0
|