Skip to content

Instantly share code, notes, and snippets.

View jgregmac's full-sized avatar

J. Greg Mackinnon jgregmac

View GitHub Profile
# Provision-MSOLUsers.ps1 script, by J. Greg Mackinnon, 2014-07-30
# Updated 2014-11-20, new license SKU, corrections to error capture commands, and stronger typing of variables.
# Updated 2014-11-21, added "license options" package to the add license command, for granular service provisioning.
# Updated 2014-12-22, Now provisions student, faculty, and staff Office 365 Pro Plus with different SKUs.
#
# Provisions all active student accounts in Active Directory with an Office 365 ProPlus license.
#
# Requires:
# - PowerShell Module "MSOnline"
# - PowerShell Module "ActiveDirectory"
'addDefaultPrinter script - J. Greg Mackinnon, 2014-06-11
' Adds the network printer specified in the script argument "/share".
' Sets this printer as the default printer for the current user.
option explicit
'Declare Variables
Dim bBadArg,bNoArgs
Dim cScrArgs
Dim iReturn
'exchangePrepForThunderbird.vbs script, J. Greg Mackinnon, 2015-10-22
' Kills any running Thunderbird processes, removes the legacy mailbox path prefix,
' sets the imap new mail check interval to 10 minutes, and restarts Thunderbird if
' it was running.
' A backup copy of the userpref.js file is created when the script is run.
' If run silently, Thunderbird will be closed automatically and no message boxes will be displayed.
'
' Usage:
' cscript.exe exchangePrepForThunderbird.vbs [/silent:(True|False)]
'
<#
.SYNOPSIS
Migrate-SPUsers Script, by J. Greg Mackinnon (derrived from unattributed script found on the Internet)
Used to document and convert user and group entries in SharePoint from Windows or Claims provider format to a new Claims provider format.
.DESCRIPTION
This script can be executed in two modes:
In "Document" mode (the default), a CSV file will be generated that enumerates all SharePoint users and groups recorded in all SharePoint "webs", and shows the new account details that will be applied.
In "Convert" mode, the changes generated in the CSV files from "Document" mode will be applied.
This two-step process makes it possible to review the planned migration before committing.
.PARAMETER oldProvider
<# Set-CMDeploymentDeadlines script
J. Greg Mackinnon, 2014-02-07
Updates all existing software update deployments with a new enforcement deadline.
Requires specification of:
-SiteServer (an SCCM Site Server name)
-SiteCode (an SCCM Site Code)
-DeadlineDate
-DeadlineTime
#>
################################################################################
#
# Create-MDTDriverStructure.ps1
# J. Greg Mackinnon, University of Vermont, 2013-11-11
# Creates a folder structure in the "Out of Box Drivers" branch of a MDT 2013
# deployment share. The structure matches the first two subdirectories of
# the source filesystem defined in $srcRoot. All drivers contained within
# $srcRoot are imported into the deployment share.
#
# Requires:
<job id="ZUVMCheckModel">
<script language="VBScript" src="ZTIUtility.vbs"/>
<script language="VBScript">
Option Explicit
RunNewInstance
'//--------------------------------------------------------
'// Main Class
'//--------------------------------------------------------
#=====================================================================================================
# AUTHOR: J. Greg Mackinnon, Adapted from 1.1 release by Tao Yang
# DATE: 2013-05-21
# Name: SCOMEnhancedEmailNotification.PS1
# Version: 3.0
# COMMENT: SCOM Enhanced Email notification which includes detailed alert information
# Update: 2.0 - 2012-06-30 - Major revision for compatibility with SCOM 2012
# - Cmdlets updated to use 2012 names
# - "Notified" Resolution Status logic removed
# - Snapin Loading and PSDrive Mappings removed (replaced with Module load)