序
安装好的windows一般都在C盘
安装软件时, 一般都不希望安装到默认位置, 安装的软件越多, C盘空间就越小.
即使安装时,将安装路径指向了其他分区, 还是有公用文件装到C盘.
这时, 可以将注册表中的关于安装的路径选项都改成其他盘. 重启计算机生效.
对于1块SSD(WindowsOS) + 2块机械硬盘(soft install disk + data disk)的组合, 改了默认安装路径,挺有用的. 不会造成大容量机械硬盘还有空间,但是SSD中没空间了.
改好之后, 少数软件还是用C:\Program Files, 这时要手工改.
还有些小作坊的软件, 直接不让选路径,直接装在C:\Program Files, 这没招.
对于MS出的vs系列和大部分软件, 都按照注册表中的值走.
实验
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion]
"SM_GamesName"="Games"
"SM_ConfigureProgramsName"="Set Program Access and Defaults"
"CommonFilesDir"="D:\\Program Files\\Common Files"
"CommonFilesDir (x86)"="D:\\Program Files (x86)\\Common Files"
"CommonW6432Dir"="D:\\Program Files\\Common Files"
"DevicePath"=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,\
00,74,00,25,00,5c,00,69,00,6e,00,66,00,00,00
"MediaPathUnexpanded"=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,\
6f,00,6f,00,74,00,25,00,5c,00,4d,00,65,00,64,00,69,00,61,00,00,00
"ProgramFilesDir"="D:\\Program Files"
"ProgramFilesDir (x86)"="D:\\Program Files (x86)"
"ProgramFilesPath"=hex(2):25,00,50,00,72,00,6f,00,67,00,72,00,61,00,6d,00,46,\
00,69,00,6c,00,65,00,73,00,25,00,00,00
"ProgramW6432Dir"="D:\\Program Files"