如何将导出的reg键附加到file.reg

问题描述 投票:0回答:1

找不到将Reg导出输出附加到现有文件的方法,所以我正在运行此命令

REG EXPORT HKEY_CLASSES_ROOT\Directory\Background\shellex\ContextMenuHandlers\NvCplDesktopContext\ backup.reg

要将某些设置导出到backup.reg文件,当它尝试导出其他内容时,我会收到消息,这将覆盖该文件。无论如何,我可以将其附加到文件而不是重写reg文件?

windows regedit
1个回答
2
投票

怎么样 ...

@echo off 

REG EXPORT HKEY_CLASSES_ROOT\Directory\Background\shellex\ContextMenuHandlers\First\ current.tmp /y
more current.tmp >> merged.reg

REG EXPORT HKEY_CLASSES_ROOT\Directory\Background\shellex\ContextMenuHandlers\Second\ current.tmp /y
more +1 current.tmp >> merged.reg

REG EXPORT HKEY_CLASSES_ROOT\Directory\Background\shellex\ContextMenuHandlers\Third\ current.tmp /y
more +1 current.tmp >> merged.reg

rm current.tmp
© www.soinside.com 2019 - 2024. All rights reserved.