fix: 修复新版安装器卸载卡住问题#646
Conversation
|
ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📜 Recent review details⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
Summary by CodeRabbit发布说明
Hidden review stack artifactWalkthrough一组变更:打包脚本改为无条件包含若干安装脚本;多个 Windows 批处理脚本将服务控制从 net 转为 sc/taskkill、为设备清理引入迭代上限,并增强下载超时与 PATH 更新实现。 变更Windows 服务和设备管理的稳健性改进
序列图不生成序列图:变更为多个独立脚本的局部改进,未形成单一跨 3 个以上组件的明确顺序交互流。 估计代码审查工作量🎯 3 (中等复杂度) | ⏱️ ~25 分钟 可能相关的 PR
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src_assets/windows/misc/path/update-path.bat (1)
16-17: ⚡ Quick win建议将
setlocal提前到临时 PATH 赋值之前。Line 16 先改
PATH、Line 17 才setlocal。在当前仓库中未发现通过call复用此脚本的地方,不过遵循最佳实践,应在赋值之前先局部化环境。这样即使将来有其他脚本通过call调用或在不同部署环境下使用,也不会继承被裁剪过的 PATH,是一个低成本、高收益的改进。建议修改
-set "PATH=%SystemRoot%\System32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SystemRoot%\System32\WindowsPowerShell\v1.0" -setlocal +setlocal +set "PATH=%SystemRoot%\System32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SystemRoot%\System32\WindowsPowerShell\v1.0"🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src_assets/windows/misc/path/update-path.bat` around lines 16 - 17, Move the setlocal call to before the temporary PATH assignment so the environment changes are localized; specifically, ensure setlocal is executed prior to the statement that modifies PATH (the line that uses set "PATH=%SystemRoot%\System32;..."), i.e., swap the order so setlocal runs first to avoid permanently altering the caller's PATH when this script is called.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@src_assets/windows/misc/path/update-path.bat`:
- Around line 16-17: Move the setlocal call to before the temporary PATH
assignment so the environment changes are localized; specifically, ensure
setlocal is executed prior to the statement that modifies PATH (the line that
uses set "PATH=%SystemRoot%\System32;..."), i.e., swap the order so setlocal
runs first to avoid permanently altering the caller's PATH when this script is
called.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 314aa02a-4c81-4998-8cb1-ff610a5308c2
📒 Files selected for processing (7)
cmake/packaging/sunshine.iss.insrc_assets/windows/misc/gamepad/install-gamepad.batsrc_assets/windows/misc/path/update-path.batsrc_assets/windows/misc/service/uninstall-service.batsrc_assets/windows/misc/vdd/uninstall-vdd.batsrc_assets/windows/misc/vmouse/install-vmouse.batsrc_assets/windows/misc/vmouse/uninstall-vmouse.bat
Summary by CodeRabbit
发布说明
Bug 修复
Chores