Back to skills
extension
Category: Development & EngineeringNo API key required

software-move

Moving installed software between disks, supporting scanning, directory migration, link creation, and history restoration. It is triggered when the user needs to: (1) scan for installed software on the disk, (2) check if the software supports relocation, (3) migrate the software installation directory to another disk, (4) create an NTFS junction/symbolic link after migration, (5) restore migrated software from history, (6) manage the history of migration/undo/redo. Trigger words: "搬移软件", "移动软件", "software move", "move installed software to another disk".

personAuthor: systemdhubgithub

software-move

用于在磁盘间搬移已安装软件并支持历史还原的技能。

安装

cd scripts && pip install -e .

工作流程

  1. 扫描softwaremove scan disk <盘符>
  2. 检测softwaremove move check --source <路径> --name <名称>
  3. 迁移softwaremove move start --source <源路径> --target <目标路径>
  4. 还原softwaremove history restore --id <编号>

常用命令

# 扫描磁盘
softwaremove scan disk D

# 检测软件是否可搬移
softwaremove move check --source "C:\Users\1\AppData\Local\Figma" --name "Figma"

# 搬移软件(Program Files 目录需加 --admin)
softwaremove move start --source "C:\Program Files\Docker\Docker" --target "D:\SoftwareMoved\Docker" --admin

# 查看历史记录
softwaremove history list

# 撤销上一次迁移
softwaremove history undo

管理员权限

C:\Program FilesC:\Program Files (x86)C:\Windows 下的软件需要管理员权限才能创建 junction 链接。迁移时添加 --admin 参数自动请求 UAC 提权。

执行前提醒(Agent 必读)

在执行任何需要 --admin 的操作(包括 move starthistory restorehistory undohistory redo)之前,Agent 必须先向用户发送以下提醒:

即将执行软件搬家/还原操作。过程中可能会弹出一个新的终端窗口(UAC 提权),请不要关闭该窗口,等操作执行完成后它会自动关闭。

待用户确认收到提醒后,再执行实际命令。

参考文档