This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-ChildItem Cert:\CurrentUser\My | |
| Where-Object {$_.Issuer -eq 'CN=DO_NOT_TRUST_FiddlerRoot, O=DO_NOT_TRUST, OU=Created by http://www.fiddler2.com'} | |
| Remove-Item; | |
# Requires user interaction | |
#Get-ChildItem Cert:\CurrentUser\Root | |
#| Where-Object {$_.Issuer -eq 'CN=DO_NOT_TRUST_FiddlerRoot, O=DO_NOT_TRUST, OU=Created by http://www.fiddler2.com'} | |
#| Remove-Item; | |
# Requires user interaction |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-16"?> | |
<Task version="1.4" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task"> | |
<RegistrationInfo> | |
<Date>2018-02-17T10:29:54.0880708</Date> | |
<Author>.\Administrator</Author> | |
<URI>\CleanUp\Remove Fiddler Certificates on StartUp</URI> | |
</RegistrationInfo> | |
<Triggers> | |
<LogonTrigger> | |
<Enabled>true</Enabled> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Write-Host "Disable Telemetry" -ForegroundColor Cyan; | |
New-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection" -Name AllowTelemetry -PropertyType DWord -Value 0 -force | Out-Null; | |
Stop-Service DiagTrack | Out-Null; | |
Set-Service DiagTrack -startupType Disabled | Out-Null; | |
Stop-Service dmwappushservice | Out-Null; | |
Set-Service dmwappushservice -startupType Disabled | Out-Null; | |
Write-Host "Add Developer Exclusions For Windows Defender" -ForegroundColor Cyan; | |
Add-MpPreference -ExclusionProcess "light.exe" | Out-Null; | |
Add-MpPreference -ExclusionProcess "candel.exe" | Out-Null; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$EventLogSourceName = "Visual Studio Updater" | |
if([System.Diagnostics.EventLog]::SourceExists($EventLogSourceName) -eq $false){ | |
New-EventLog –LogName Application –Source $EventLogSourceName | |
} | |
$cacheDirs = @( | |
"C:\Program Files (x86)\Microsoft Visual Studio\Installer" | |
#"C:\ProgramData\Microsoft\VisualStudio\Packages", | |
#"C:\ProgramData\Microsoft\VisualStudio\Setup" | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$registryKey = [Microsoft.Win32.Registry]::LocalMachine.OpenSubKey("SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired"); | |
if ($null -ne $registryKey){ | |
if ($registryKey.GetValueNames().Length -ne 0) { | |
Write-Host "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired indicates a pending reboot."; | |
Write-EventLog –LogName Application –Source $EventLogSourceName –EntryType Information –EventID 99 –Message "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired indicates a pending reboot."; | |
Restart-Computer -Force | |
} | |
} | |
$registryKey = [Microsoft.Win32.Registry]::LocalMachine.OpenSubKey("SOFTWARE\Microsoft\Updates"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$setupPath = ".\Setup.exe"; | |
$productKey = "XXX"; | |
$instanceName = "MSSQLSERVER"; | |
$version = "2019"; | |
$collation = "Latin1_General_CI_AS"; | |
$serviceAccount = ""; | |
$serviceAccountPassword = ""; | |
$currentUser = [System.Environment]::UserDomainName + "\" + [System.Environment]::UserName; | |
$sqlAdminAccount = ""; | |
$sqlAdminGroup = ""; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$extensionDisplayName = "Wix Toolset Visual Studio 2017 Extension"; | |
$extensionApiVersion = "api-version=3.2-preview.1" | |
$marketplaceQueryUrl = "https://marketplace.visualstudio.com/_apis/public/gallery/extensionquery"; | |
$extensionQuery = "{`"flags`":`"262`"," + | |
"`"filters`":[" + | |
"{" + | |
"`"criteria`":" + | |
"[" + | |
"{`"filterType`":`"14`",`"value`":`"1033`"}," + |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$linkFilePath = "C:\Users\$([Environment]::UserName)\Desktop\WindowsTerminal.lnk" | |
$bytes = [System.IO.File]::ReadAllBytes($linkFilePath) | |
$bytes[0x15] = $bytes[0x15] -bor 0x20 #set byte 21 (0x15) bit 6 (0x20) ON | |
[System.IO.File]::WriteAllBytes($linkFilePath, $bytes) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<UsingTask | |
TaskName="GenerateMachineKey" | |
TaskFactory="CodeTaskFactory" | |
AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll" > | |
<ParameterGroup /> | |
<Task> | |
<Reference Include="System.Xml"/> | |
<Using Namespace="System"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# .NET | |
Add-MpPreference -ExclusionPath "%WINDIR%\Microsoft.NET\" | |
Add-MpPreference -ExclusionPath "%WINDIR%\assembly" | |
# Visual Studio | |
Add-MpPreference -ExclusionProcess "devenv.exe" | |
Add-MpPreference -ExclusionProcess "msbuild.exe" | |
Add-MpPreference -ExclusionProcess "VBCSCompiler.exe" | |
Add-MpPreference -ExclusionPath "%ProgramFiles(x86)%\Microsoft SDKs\" | |
Add-MpPreference -ExclusionPath "%ProgramFiles(x86)%\Microsoft Visual Studio\" |