-
PR Title 1
- Repository: repo-name
- Date: YYYY-MM-DD
- Link: PR Link
-
PR Title 2
This file contains hidden or 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
# Simple PowerShell Test Script | |
Write-Host "Hello from my test gist!" -ForegroundColor Green | |
Get-Date | |
Write-Host "This is a test gist created to verify GistPad functionality." -ForegroundColor Yellow |
This file contains hidden or 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 Test-Assessment-21830 { | |
[CmdletBinding()] | |
param() | |
Write-PSFMessage '🟦 Start' -Tag Test -Level VeryVerbose | |
$activity = "Checking Highly privileged roles are only activated in a PAW/SAW device" | |
Write-ZtProgress -Activity $activity -Status "Getting policy" | |
# Get all Conditional Access policies |
This file contains hidden or 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
# Simple PowerShell Test Script | |
Write-Host "Hello from my test gist!" -ForegroundColor Green | |
Get-Date | |
Write-Host "This is a test gist created to verify GistPad functionality." -ForegroundColor Yellow |
This file contains hidden or 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
$options = @{ | |
AddToHistoryHandler = { | |
param( [string]$line) | |
return $line.Length -gt 3 -and $line[0] -ne ' ' -and $line[0] -ne ';' | |
} | |
} | |
Set-PSReadLineOption @options |
This file contains hidden or 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
{ | |
"title": "Test tour", | |
"steps": [ | |
{ | |
"file": "Test-CodeTour.ps1", | |
"line": 4, | |
"description": "### Step 1\r\n\r\nThis is the first command in the script.\r\nIt will show you today's date. Simple as that.", | |
"contents": "\r\n# a script to test the CodeTour extension\r\n\r\nGet-Date\r\n\r\nfunction foo {\r\n Write-Output \"foo\"\r\n}\r\n\r\n# Call a function\r\nfoo\r\n\r\n" | |
}, | |
{ |
This file contains hidden or 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
$sourceuri = "ftp://ftp.example.com/myfolder/myfile.xml" | |
$filePath = "C:\temp\myfile.xml" | |
$username = "user" | |
$password = "password" | |
# Create a FTPWebRequest object to handle the connection to the ftp server | |
$ftprequest = [System.Net.FtpWebRequest]::create($sourceuri) | |
$credentials = New-Object System.Net.NetworkCredential($username,$password) | |
# set the request's network credentials for an authenticated connection |
This file contains hidden or 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
$sourceuri = "ftp://speedtest.tele2.net/1MB.zip" | |
$targetpath = "C:\temp\1mb.zip" | |
$username = "anonymous" | |
$password = "anonymous" | |
# Create a FTPWebRequest object to handle the connection to the ftp server | |
$ftprequest = [System.Net.FtpWebRequest]::create($sourceuri) | |
# set the request's network credentials for an authenticated connection |