|
7zip有没有类似如下的关联方式,非常简洁:- EXEC !%ProgramFiles%\Imagine\Imagine.EXE /assocext /regcontextmenu
- EXEC !%ProgramFiles%\WimTool\WimTool.EXE /REG /M
复制代码
很多PE都是以CMD导入注册表,内容如下(来自如水7PE),但为什么导入我的64位的8PE竟然无效,是不是在哪里还要再设置一下。
- rem 关联7z右键
- reg add "HKCU\Software\7-ZIP\Compression" /f /v "Level" /t REG_DWORD /d 5
- reg add "HKCU\Software\7-ZIP\Compression" /f /v "Archiver" /t REG_SZ /d "7z"
- reg add "HKCU\Software\7-ZIP\Compression" /f /v "ShowPassword" /t REG_DWORD /d 0
- reg add "HKCU\Software\7-ZIP\Compression" /f /v "EncryptHeaders" /t REG_DWORD /d 0
- reg add "HKCU\Software\7-ZIP\Compression\Options\7z" /f /v "Method" /t REG_SZ /d "LZMA"
- reg add "HKCU\Software\7-ZIP\Compression\Options\7z" /f /v "Level" /t REG_DWORD /d 9
- reg add "HKCU\Software\7-ZIP\Compression\Options\7z" /f /v "Dictionary" /t REG_DWORD /d 16777216
- reg add "HKCU\Software\7-ZIP\Compression\Options\7z" /f /v "Order" /t REG_DWORD /d 64
- reg add "HKCU\Software\7-ZIP\Compression\Options\7z" /f /v "BlockSize" /t REG_DWORD /d 32
- reg add "HKCU\Software\7-ZIP\Compression\Options\7z" /f /v "NumThreads" /t REG_DWORD /d 1
- reg add "HKCU\Software\7-ZIP\Options" /f /v "CascadedMenu" /t REG_DWORD /d 1
- reg add "HKCU\Software\7-ZIP\Options" /f /v "ContextMenu" /t REG_DWORD /d 16151
- reg add "HKCU\Software\7-ZIP\Options" /f /v "WorkDirType" /t REG_DWORD /d 1
- reg add "HKCU\Software\7-ZIP\Options" /f /v "WorkDirPath" /t REG_SZ /d ""
- reg add "HKCU\Software\7-ZIP\Options" /f /v "TempRemovableOnly" /t REG_DWORD /d 0
- reg add "HKU\.DEFAULT\SessionInformation" /f /v "ProgramCount" /t REG_DWORD /d 4
- reg add "HKLM\SOFTWARE\Classes\*\shellex\ContextMenuHandlers\7-ZIP" /f /ve /t REG_SZ /d "{23170F69-40C1-278A-1000-000100020000}"
- reg add "HKLM\SOFTWARE\Classes\CLSID\{23170F69-40C1-278A-1000-000100020000}" /f /ve /t REG_SZ /d "7-Zip Shell Extension"
- reg add "HKLM\SOFTWARE\Classes\CLSID\{23170F69-40C1-278A-1000-000100020000}\InprocServer32" /f /ve /t REG_SZ /d "%TP%\7-zip\7-zip.dll"
- reg add "HKLM\SOFTWARE\Classes\CLSID\{23170F69-40C1-278A-1000-000100020000}\InprocServer32" /f /v "ThreadingModel" /t REG_SZ /d "Apartment"
- reg add "HKLM\SOFTWARE\Classes\Directory\shellex\DragDropHandlers\7-ZIP" /f /ve /t REG_SZ /d "{23170F69-40C1-278A-1000-000100020000}"
- reg add "HKLM\SOFTWARE\Classes\Directory\shellex\ContextMenuHandlers\7-ZIP" /f /ve /t REG_SZ /d "{23170F69-40C1-278A-1000-000100020000}"
- reg add "HKLM\SOFTWARE\Classes\Drive\shellex\DragDropHandlers\7-ZIP" /f /ve /t REG_SZ /d "{23170F69-40C1-278A-1000-000100020000}"
- reg add "HKLM\SOFTWARE\Microsoft\Cryptography\RNG" /f /v "Seed" /t REG_BINARY /d ae980bee38a3f51bba1e2a2620869cd4140359f701aff4cc6d90c3dacb7a58e26176a8a8d517c1ca0a19aff67e65b7ea2580d530b236cc02f57234b8acc6629bfef9fece90743d5d47134f8a5e15d12b
- reg add "HKLM\SOFTWARE\Classes\.7z" /f /ve /t REG_SZ /d "7-Zip.7z"
- reg add "HKLM\SOFTWARE\Classes\.arj" /f /ve /t REG_SZ /d "7-Zip.arj"
- reg add "HKLM\SOFTWARE\Classes\.bz2" /f /ve /t REG_SZ /d "7-Zip.bz2"
- reg add "HKLM\SOFTWARE\Classes\.bzip2" /f /ve /t REG_SZ /d "7-Zip.bzip2"
- reg add "HKLM\SOFTWARE\Classes\.cab" /f /ve /t REG_SZ /d "7-Zip.cab"
- reg add "HKLM\SOFTWARE\Classes\.cpio" /f /ve /t REG_SZ /d "7-Zip.cpio"
- reg add "HKLM\SOFTWARE\Classes\.gz" /f /ve /t REG_SZ /d "7-Zip.gz"
- reg add "HKLM\SOFTWARE\Classes\.gzip" /f /ve /t REG_SZ /d "7-Zip.gzip"
- reg add "HKLM\SOFTWARE\Classes\.lzh" /f /ve /t REG_SZ /d "7-Zip.lzh"
- reg add "HKLM\SOFTWARE\Classes\.lzma" /f /ve /t REG_SZ /d "7-Zip.lzma"
- reg add "HKLM\SOFTWARE\Classes\.rar" /f /ve /t REG_SZ /d "7-Zip.rar"
- reg add "HKLM\SOFTWARE\Classes\.rpm" /f /ve /t REG_SZ /d "7-Zip.rpm"
- reg add "HKLM\SOFTWARE\Classes\.tar" /f /ve /t REG_SZ /d "7-Zip.tar"
- reg add "HKLM\SOFTWARE\Classes\.taz" /f /ve /t REG_SZ /d "7-Zip.taz"
- reg add "HKLM\SOFTWARE\Classes\.tbz" /f /ve /t REG_SZ /d "7-Zip.tbz"
- reg add "HKLM\SOFTWARE\Classes\.tbz2" /f /ve /t REG_SZ /d "7-Zip.tbz2"
- reg add "HKLM\SOFTWARE\Classes\.vhd" /f /ve /t REG_SZ /d "7-Zip.vhd"
- reg add "HKLM\SOFTWARE\Classes\.zip" /f /ve /t REG_SZ /d "7-Zip.zip"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.7z" /f /ve /t REG_SZ /d ".7z 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.7z\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,0"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.7z\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.7z\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.7z\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.arj" /f /ve /t REG_SZ /d ".arj 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.arj\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,4"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.arj\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.arj\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.arj\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bz2" /f /ve /t REG_SZ /d ".bz2 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bz2\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,2"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bz2\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bz2\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bz2\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bzip2" /f /ve /t REG_SZ /d ".bzip2 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bzip2\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,2"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bzip2\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bzip2\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.bzip2\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cab" /f /ve /t REG_SZ /d ".cab 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cab\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,7"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cab\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cab\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cab\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cpio" /f /ve /t REG_SZ /d ".cpio 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cpio\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,12"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cpio\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cpio\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.cpio\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gz" /f /ve /t REG_SZ /d ".gz 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gz\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,14"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gz\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gz\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gz\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gzip" /f /ve /t REG_SZ /d ".gzip 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gzip\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,14"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gzip\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gzip\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.gzip\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzh" /f /ve /t REG_SZ /d ".lzh 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzh\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,6"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzh\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzh\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzh\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzma" /f /ve /t REG_SZ /d ".lzma 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzma\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,16"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzma\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzma\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.lzma\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rar" /f /ve /t REG_SZ /d ".rar 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rar\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,3"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rar\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rar\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rar\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rpm" /f /ve /t REG_SZ /d ".rpm 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rpm\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,10"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rpm\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rpm\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.rpm\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tar" /f /ve /t REG_SZ /d ".tar 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tar\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,13"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tar\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tar\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tar\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.taz" /f /ve /t REG_SZ /d ".taz 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.taz\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,5"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.taz\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.taz\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.taz\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz" /f /ve /t REG_SZ /d ".tbz 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,2"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz2" /f /ve /t REG_SZ /d ".tbz2 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz2\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,2"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz2\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz2\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.tbz2\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.vhd" /f /ve /t REG_SZ /d ".vhd 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.vhd\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,20"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.vhd\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.vhd\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.vhd\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.zip" /f /ve /t REG_SZ /d ".zip 压缩文件"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.zip\DefaultIcon" /f /ve /t REG_SZ /d "%TP%\7-Zip\7z.dll,1"
- reg add "HKLM\SOFTWARE\Classes\7-Zip.zip\shell" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.zip\shell\open" /f /ve /t REG_SZ /d ""
- reg add "HKLM\SOFTWARE\Classes\7-Zip.zip\shell\open\command" /f /ve /t REG_SZ /d ""%TP%\7-Zip\7zFM.exe" "%%1""
- reg add "HKU\.DEFAULT\Software\7-Zip\Options" /f /v "CascadedMenu" /t REG_DWORD /d 1
- reg add "HKU\.DEFAULT\Software\7-Zip\Options" /f /v "ContextMenu" /t REG_DWORD /d 4919
复制代码 |
|