REG常用命令表

1、添加环境变量

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Environment]
"CDSROOT"="C:\\Cadence\\SPB_15.2"
"CHDL_LIB_INST_DIR"="%CDSROOT%"
"CONCEPT_INST_DIR"="%CDSROOT%"
"CDS_LIC_FILE"="%CDSROOT%\\SPB152.dat"
"PATH"="%CDSROOT%\\tools\\bin;%CDSROOT%\\tools\\pcb\\bin;%CDSROOT%\\tools\\specctra\\bin;%CDSROOT%\\tools\\Capture;%CDSROOT%\\tools\\fet\\bin;%CDSROOT%\\tools\\libutil\\bin"

example2:

Windows Registry Editor Version 5.00
 
[HKEY_CURRENT_USER\Environment]
"TAIPHome"="D:\\S2C\\P6.6.2.6\\PlayerPro"
"TAIPodHome"="D:\\S2C\\P6.6.2.6\\PlayerPro\\firmware"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment]
"TAIPHome"="D:\\S2C\\P6.6.2.6\\PlayerPro"
"TAIPodHome"="D:\\S2C\\P6.6.2.6\\PlayerPro\\firmware"

 

2、获取权限

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\runas]
@="获取TrustedInstaller权限"
[HKEY_CLASSES_ROOT\*\shell\runas\command]
@="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"
"IsolatedCommand"="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"
[HKEY_CLASSES_ROOT\Directory\shell\runas]
@="获取TrustedInstaller权限"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT\Directory\shell\runas\command]
@="cmd.exe /c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant administrators:F /t"
"IsolatedCommand"="cmd.exe /c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant administrators:F /t"

 

你可能感兴趣的:(Windows使用)