diff --git a/install.ps1 b/install.ps1 index 343b8be..c1fc29f 100644 --- a/install.ps1 +++ b/install.ps1 @@ -7,6 +7,25 @@ # } # } +# Disable UAC +Try { + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System" /t REG_DWORD /f /v "EnableLUA" /d "0" + Write-Host "UAC is now disabled." +} +Catch { + Write-Host "Error - Exception caught in disabling UAC : $error[0]" +} + +# Enable Developer Mode +reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock" /t REG_DWORD /f /v "AllowDevelopmentWithoutDevLicense" /d "1" /t REG_DWORD /f /v "AllowAllTrustedApps" /d "1" + +# Set environmenmt variables +## CMDER_ROOT +[System.Environment]::SetEnvironmentVariable('CMDER_ROOT',"$($env:USERPROFILE)\Cmder", [System.EnvironmentVariableTarget]::Machine) + +# DEV_ROOT --Use this per-machine, i.e. laptops sometimes only have a single disk and desktops have multiple disks +$dev_path = Read-Host -Prompt 'Input the Repos Path:' +[System.Environment]::SetEnvironmentVariable('DEV_PATH', $dev_path, [System.EnvironmentVariableTarget]::Machine) # User Profile Write-Host "User Profile Directory: $($env:USERPROFILE)" @@ -103,5 +122,5 @@ if (-not (Test-Path -Path $neovim_init_path)) { Write-Host "Neovim Init Path Exists" } -Write-Host -NoNewline "Press any key to continue.." +Write-Host -NoNewline "Be sure to Reboot the Machine. Press any key to continue.." $null = $Host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown") \ No newline at end of file