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 Add-GeneratedUsers { | |
<# | |
.SYNOPSIS | |
Creates Generated Users | |
.DESCRIPTION | |
This function creates users automatically. Just provide some information if customization is needed | |
.PARAMETER Count | |
How many users will be created. |
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
#Requires -Module Spotishell | |
# Install and setup Spotishell | |
# https://github.com/wardbox/spotishell | |
$InformationPreference = "Continue" | |
# Set your spotify username here | |
$username = "myspotifyusername" | |
$public_playlists = Get-UserPlaylists -Id $username | Where-Object { $_.owner.uri -eq "spotify:user:$username" -and $_.public} |
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-SaveFilePath { | |
[CmdletBinding()] | |
param ( | |
[string] | |
$InitialDirectory = $PWD, | |
[string] | |
$Filter | |
) | |
begin { |
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
$CustomHistoryHandler = { | |
param([string]$line) | |
$AllowListRegex = @( # Add keywords to match that you want to allow in your history file. | |
"Get-TokenFromOutlook" | |
) -join '|' | |
$DenyListRegex = @( # Add keywords to match that you don't want in your history file | |
"correcthorsebatterystaple" | |
) -join '|' |
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
[CmdletBinding()] | |
param ( | |
[Parameter(ParameterSetName = "SSHURI")] | |
[System.Uri] | |
$SSHURI, | |
# | |
[Parameter(ParameterSetName = "ComputerName", Mandatory)] | |
[string] | |
$ComputerName, | |
# Parameter help description |
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
<# | |
.SYNOPSIS | |
This will type the clipboard | |
.DESCRIPTION | |
This command will type the clipboard after a configurable delay, set at 2 seconds by default | |
.PARAMETER SecondsToSleep | |
Seconds to sleep before sending the clipboard |
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
<# | |
.SYNOPSIS | |
This script can disable and enable Windows Explorer Hotkeys using the Windows Key | |
.DESCRIPTION | |
This script can disable and enable Windows Explorer Hotkeys using the Windows Key. | |
You cannot disable and enable with a single command. You will need to run this script | |
twice (once disabling, again enabling). |
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 Convert-FileSize { | |
[CmdletBinding()] | |
[OutputType([string])] | |
param ( | |
[Parameter(Mandatory = $true)] | |
[int64] $FileSize | |
) | |
switch ($FileSize) { |