We are, for now, just using the official github copilot CLI, but they didn't really have hooks for PowerShell, so I wrote a few functions to implement it.
It works great, as you can see:
We are, for now, just using the official github copilot CLI, but they didn't really have hooks for PowerShell, so I wrote a few functions to implement it.
It works great, as you can see:
filter Expand-Property { | |
<# | |
.SYNOPSIS | |
Expands an array property, creating a duplicate object for each value | |
.EXAMPLE | |
[PSCustomObject]@{ Name = "A"; Value = @(1,2,3) } | Expand-Property Value | |
Name Value | |
---- ----- | |
A 1 |
#require -version 5.1 | |
#Usage: iwr https://tinyurl.com/VSCodeServer | iex | |
#Parameterized usage: & ([ScriptBlock]::Create((iwr https://tinyurl.com/VSCodeServer))) -Your -Options | |
param( | |
#Path to install the vscode binary to. This defaults to a folder in your Local AppData path. Must be writable by your current user without sudo | |
[ValidateNotNullOrEmpty()] | |
[string]$InstallPath = $(Join-Path -Path ([System.Environment]::GetFolderPath('LocalApplicationData')) -ChildPath 'vscode-cli'), | |
#Installation architecture. This is normally autodetected. | |
$Arch, | |
$OS, |
#requires -version 7 -module Microsoft.Graph.Applications | |
using namespace Microsoft.Graph.PowerShell.Models | |
using namespace System.Collections.Generic | |
enum MicrosoftGraphServicePrincipalType { | |
Application | |
Delegated | |
} | |
class MgServicePrincipalPermission { |