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
<# | |
QuickStart script for setting up Azure for AKS Edge Essentials and deploying the same on the Windows device | |
#> | |
param( | |
[Parameter(Mandatory)] | |
[String] $AideUserConfigFilePath, | |
[Parameter(Mandatory)] | |
[string] $AksEdgeConfigFilePath, | |
[string] $Tag |
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 -version 7 | |
using namespace Microsoft.PowerShell.Commands | |
using namespace System.Text | |
$ErrorActionPreference = 'Stop' | |
#Suppress useless IRM Verbose output | |
$PSDefaultParameterValues['Invoke-RestMethod:Verbose'] = $false | |
$PSDefaultParameterValues['Invoke-WebRequest:Verbose'] = $false | |
$DebugPreference = 'SilentlyContinue' |
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 PowerAlto, ImportExcel | |
$ErrorActionPreference = 'Stop' | |
if (-not $MacVendorCache) { | |
Write-Warning 'MacVendorCache not found, downloading from maclookup.app. This is common on the first run.' | |
$SCRIPT:MacVendorCache = @{} | |
foreach ($entry in $(ConvertFrom-Csv (Invoke-RestMethod 'https://maclookup.app/downloads/csv-database/get-db'))) { | |
$MacVendorCache[$entry.'Mac Prefix'] = $entry.'Vendor Name' | |
} | |
} |
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
using namespace System.Collections.Generic | |
function Get-OpenApiDefinition { | |
<# | |
Fetches the OpenAPI definition from the specified URI and for every ref, downloads the relative file to the destination folder. Currently only works with relative refs | |
#> | |
param ( | |
#The source | |
[Parameter(Mandatory)] | |
[Uri]$Uri, |
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
var _pageData = "[[1,null,null,null,null,null,null,null,null,null,\"at\",\"AAX3J7BhCRC7IVYMba1r7wDXuj920s9Frw:1706679164531\",\"10080040042915956860\",1706679164532,\"0\",\"en\",false,[null,null,\"justingrote@gmail.com\",\"https://lh4.googleusercontent.com/-R4mL1JYgKEs/AAAAAAAAAAI/AAAAAAAAAAA/-74UcaDbnzk/s32-c/photo.jpg\",\"https://plus.google.com/100005784601014694175/about\",\"Justin Grote\",\"https://lh4.googleusercontent.com/-R4mL1JYgKEs/AAAAAAAAAAI/AAAAAAAAAAA/-74UcaDbnzk/s64-c/photo.jpg\",\"https://lh3.googleusercontent.com/c5dqxl-2uHZ82ah9p7yxrVF1ZssrJNSV_15Nu0TUZwzCWqmtoLxCUJgEzLGtxsrJ6-v6R6rKU_-FYm881TTiMCJ_\\u003ds1600\"],\"https://www.google.com/maps/d/viewer?mid\\u003d1ydRiXegNnQcXEw-KLmsldBty7_xmedM\",\"https://www.google.com/maps/d/embed?mid\\u003d1ydRiXegNnQcXEw-KLmsldBty7_xmedM\\u0026ehbc\\u003d2E312F\",\"https://www.google.com/maps/d/edit?mid\\u003d1ydRiXegNnQcXEw-KLmsldBty7_xmedM\",\"https://www.google.com/maps/d/thumbnail?mid\\u003d1ydRiXegNnQcXEw-KLmsldBty7_xmedM\",null,null,true,\"https:/ |
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
using namespace System.Collections.Generic | |
using namespace Microsoft.PowerShell.Commands.Internal.Format | |
#Inspired by: https://gist.github.com/aaroncalderon/09a2833831c0f3a3bb57fe2224963942 | |
<# | |
.Synopsis | |
Converts PowerShell Objects or Format-Table output to Markdown | |
#> | |
Function ConvertTo-Markdown { | |
[CmdletBinding()] |
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 ThreadJob | |
param( | |
#Filter modules to update by name, otherwise will update all modules | |
[string[]]$Name = @(), | |
[ValidateSet('AllUsers', 'CurrentUser')] | |
$Scope = 'CurrentUser', | |
$ThrottleLimit = 30 | |
) | |
try { |
This file has been truncated, but you can view the full file.
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
//---------------------- | |
// <auto-generated> | |
// Generated using the NSwag toolchain v13.20.0.0 (NJsonSchema v10.9.0.0 (Newtonsoft.Json v13.0.0.0)) (http://NSwag.org) | |
// </auto-generated> | |
//---------------------- | |
#nullable enable | |
#pragma warning disable 108 // Disable "CS0108 '{derivedDto}.ToJson()' hides inherited member '{dtoBase}.ToJson()'. Use the new keyword if hiding was intended." | |
#pragma warning disable 114 // Disable "CS0114 '{derivedDto}.RaisePropertyChanged(String)' hides inherited member 'dtoBase.RaisePropertyChanged(String)'. To make the current member override that implementation, add the override keyword. Otherwise add the new keyword." |
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
using namespace System.Collections.Generic | |
class Pet { | |
[string]$Name | |
[string]$Type | |
hidden [int] GetHashCode() { | |
$uniqueString = $this.Name + $this.Type | |
return $uniqueString.GetHashCode() | |
} |
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
using namespace System.Management.Automation | |
using namespace System.Collections.Generic | |
[List[Job2]]$jobs = @() | |
[List[Object]]$Result = @() | |
$baseUri = 'https://www.powershellgallery.com/api/v2/Packages?$skip=' | |
$maxPackages = 309000 | |
for ($i = 0; $i -lt $maxPackages; $i += 100) { |
NewerOlder