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
function Update-CSOMFolderMetadata { | |
param ( | |
[Parameter(Mandatory=$True)] | |
$SiteURL, | |
[Parameter(Mandatory=$True)] | |
$FileServerRelativeUrl, | |
$CreatedBy, | |
$ModifiedBy, | |
$CreatedOn, | |
$ModifiedOn, |
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
function Update-CSOMFileMetadata { | |
param ( | |
[Parameter(Mandatory=$True)] | |
$SiteURL, | |
[Parameter(Mandatory=$True)] | |
$FileServerRelativeUrl, | |
$CreatedBy, | |
$ModifiedBy, | |
$CreatedOn, | |
$ModifiedOn, |
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
function Get-CSOMDocumentLibraryInventory { | |
param ( | |
[Parameter(Mandatory=$True)] | |
[string]$SiteURL, | |
[Parameter(Mandatory=$True)] | |
[string]$LibraryName, | |
[int]$BatchSize, | |
[Parameter(Mandatory=$True)] | |
[System.Management.Automation.PSCredential] | |
$Credential |
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
@font-face { | |
font-family: KaTeX_AMS; | |
src: url(/static/fonts/KaTeX_AMS-Regular.38a68f7.woff2) format("woff2"), url(/static/fonts/KaTeX_AMS-Regular.7d307e8.woff) format("woff"), url(/static/fonts/KaTeX_AMS-Regular.2dbe16b.ttf) format("truetype"); | |
font-weight: 400; | |
font-style: normal | |
} | |
@font-face { | |
font-family: KaTeX_Caligraphic; | |
src: url(/static/fonts/KaTeX_Caligraphic-Bold.342b296.woff2) format("woff2"), url(/static/fonts/KaTeX_Caligraphic-Bold.9634168.woff) format("woff"), url(/static/fonts/KaTeX_Caligraphic-Bold.33d2688.ttf) format("truetype"); |
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
# set strong cryptography on 64 bit .Net Framework (version 4 and above) | |
Set-ItemProperty -Path 'HKLM:\SOFTWARE\Wow6432Node\Microsoft\.NetFramework\v4.0.30319' -Name 'SchUseStrongCrypto' -Value '1' -Type DWord | |
# set strong cryptography on 32 bit .Net Framework (version 4 and above) | |
Set-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\.NetFramework\v4.0.30319' -Name 'SchUseStrongCrypto' -Value '1' -Type DWord |
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
Function Get-FolderSize { | |
[cmdletbinding()] | |
param | |
( | |
[Parameter(Mandatory = $false)] | |
[Alias('Path')] | |
[String[]] | |
$BasePath = 'C:\', | |
[Parameter(Mandatory = $false)] | |
[Alias('User')] |
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
Function Set-SQLMSXEncryptionChannelOff | |
{ | |
$Path = "HKLM:\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL13.SE\SQLServerAgent" | |
$Name = "MsxEncryptChannelOptions" | |
$DefaultValue = "2" | |
$NewValue = "0" | |
$ComputerName = $Env:COMPUTERNAME | |
$Item = (Get-ItemProperty $Path -Name $Name).$Name | |
if($Item -eq $DefaultValue) | |
{ |
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
Add-WUServiceManager -ServiceID 7971f918-a847-4430-9279-4a52d1efe18d | |
Get-WUInstall –MicrosoftUpdate –AcceptAll –AutoReboot |
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
function Install-dbatools { | |
Import-Module dbatools -ErrorAction SilentlyContinue | |
if((Get-Module | Where-Object {$_.Name -eq "dbatools"}) -eq $null) { | |
Write-Output "dbatools module installing" | |
Install-Module dbatools -force | |
} | |
else { | |
Write-Output "dbatools module already installed" | |
} | |
} |
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
USE [DatabaseLogins] | |
CREATE TABLE [dbo].[DbaTools-WatchDbLogins]( | |
[ComputerName] [nvarchar](max) NULL, | |
[InstanceName] [nvarchar](max) NULL, | |
[SqlInstance] [nvarchar](max) NULL, | |
[LoginTime] [datetime2](7) NULL, | |
[Login] [nvarchar](max) NULL, | |
[Host] [nvarchar](max) NULL, | |
[Program] [nvarchar](max) NULL, |
NewerOlder