@hupan56/wlkj 3.3.1 → 3.3.3

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.
@@ -242,9 +242,11 @@ def detect_name(explicit=None):
242
242
  # Step 2: 调 init_doctor --fix (主体)
243
243
  # ============================================================
244
244
 
245
- def run_doctor(name, role):
245
+ def run_doctor(name, role, skip_code=False):
246
246
  print('\n--- 初始化 (init_doctor) ---')
247
247
  cmd = [sys.executable, str(THIS_DIR / 'init_doctor.py'), '--fix', name, role]
248
+ if skip_code:
249
+ cmd.append('--skip-code')
248
250
  # 透传 stdio (用户能看到实时输出) + 强制 UTF-8 环境 (解决 cmd GBK 乱码)
249
251
  env = dict(os.environ)
250
252
  env['PYTHONIOENCODING'] = 'utf-8'
@@ -911,6 +913,7 @@ def main():
911
913
  parser.add_argument('--skip-cron', action='store_true', help='跳过 cron 注册')
912
914
  parser.add_argument('--skip-qoderwork', action='store_true', help='跳过 QoderWork 安装')
913
915
  parser.add_argument('--skip-lanhu', action='store_true', help='跳过蓝湖 MCP 引导')
916
+ parser.add_argument('--skip-code', '--cloud', action='store_true', help='云模式:跳过本地源码 clone/索引(KG 在云平台)')
914
917
  args = parser.parse_args()
915
918
 
916
919
  print('=' * 56)
@@ -931,7 +934,7 @@ def main():
931
934
  configure_git_identity(name)
932
935
 
933
936
  # Step 2
934
- if not run_doctor(name, args.role):
937
+ if not run_doctor(name, args.role, args.skip_code):
935
938
  warn('init_doctor 未完全成功, 继续 setup 后续步骤...')
936
939
 
937
940
  # Step 3