Skip to content

Instantly share code, notes, and snippets.

@keithga
keithga / ZTISurface1TBBootDisk.wsf
Created November 21, 2017 05:08
Suface 1TB fix
<job id="ZTISurface1TBBootDisk">
<script language="VBScript" src="ZTIUtility.vbs"/>
<script language="VBScript" src="ZTIDiskUtility.vbs"/>
<script language="VBScript">
' // ***************************************************************************
' //
' // Copyright (c) Microsoft Corporation. All rights reserved.
' //
' // Microsoft Deployment Toolkit Solution Accelerator
@keithga
keithga / Export-GroovePlaylist.ps1
Last active August 18, 2018 00:14
Export Microsoft Groove Playlists
<#
.SYNOPSIS
Export Groove Playlist
.DESCRIPTION
Export Groove Music playlist (tested on Groove Music version 9/25/2017)
Steps:
@keithga
keithga / Update-INIFiles.ps1
Created September 16, 2017 03:34
Update CustomSettings.ini file.
<#
.SYNOPSIS
Update CustomSettings.ini file.
.DESCRIPTION
Updates one or more CUstomSettings.ini files with a common value.
Calling powershell.exe instance must have read/write privelages to the share.
@keithga
keithga / Trace-NetworkwithNetSh.ps1
Created February 23, 2019 02:16
network trace program
#Requires -RunAsAdministrator
<#
.Synopsis
Launch network trace
.DESCRIPTION
Launches network trace and displays a
.EXAMPLE
Example of how to use this cmdlet
.NOTES
@keithga
keithga / find-DiskHog.ps1
Last active July 10, 2022 03:46
Disk Hog Script
<#
.SYNOPSIS
Report on Disk Hogs
.DESCRIPTION
Returns a list of the largest directories in use on the local machine
.NOTES
Copyright Keith Garner, All rights reserved.
Really Updated for Windows 7 and Optimized for !!!SPEED!!!
.PARAMETER Path
Start of the search, usually c:\
@keithga
keithga / MYIT_OEMBypass.ps1
Last active September 22, 2022 17:09
IT OEM Bypass script
<#
Bypass file for OEM OOBE Setup.
Called from within Audit Mode.
#>
param(
[int] $TargetDisk = 0,
[string] $NewBootWim = "$PSScriptRoot\Generic_x64.wim",
[string] $UserName = 'MDTServer\MDTNonInteractive',
[string] $Password = 'UnSecurePassword1234',
@keithga
keithga / DeviceCollPerformance2
Created January 26, 2018 05:59
Replacement script for Add-CMDeviceCollectionDirectMembership
<#
Example of how to create a Device Collection and populate it with computer objects
The Faster way. <Yea!>
#>
[cmdletbinding()]
param(
$CollBaseName = 'MyTestCol_0C_{0:D4}',
@keithga
keithga / Win10.1709.Eval.Links.json
Last active July 25, 2023 06:15
List of Windows 10 1709 Enterprise Eval download links
@keithga
keithga / RDGGen.ps1
Created November 4, 2017 22:26
Remote Desktop Generator for Azure
<#
 .SYNOPSIS
Auto Generate a RDG file for Azure.
.DESCRIPTION
Will create a Microsoft Remote Desktop Connection Manager *.RDG file
from the Virtual Machines within your Azure Tenant.
.PARAMETER Path
Location of the target *.RDG file.
# This script will remove the VM *AND* Vhd
$VMs = get-vm | Out-GridView -OutputMode Multiple
$Disks = $VMs | Get-VMHardDiskDrive | % path
$VMs | stop-vm -Force -TurnOff -Confirm:$False -ErrorAction SilentlyContinue -WarningAction SilentlyContinue
$VMs | Remove-VM -Force -Confirm:$False