Skip to content

Instantly share code, notes, and snippets.

@paulyuk
Last active June 20, 2023 21:00
Show Gist options
  • Save paulyuk/2d86810c792e27bcabe595039a07bc77 to your computer and use it in GitHub Desktop.
Save paulyuk/2d86810c792e27bcabe595039a07bc77 to your computer and use it in GitHub Desktop.
Install tools for Azure Functions PowerShell prerelease

PowerShell

install latest - 7.3

winget search Microsoft.PowerShell
winget install --id Microsoft.Powershell

or alternatively:

OPTIONAL install PowerShell preview - 7.4

winget install --id Microsoft.Powershell.Preview --source winget

.NET dependencies

install .NET 6.x SDK

winget install --id Microsoft.DotNet.SDK.6

install .NET 8.x preview SDK

winget install --id Microsoft.DotNet.SDK.Preview

Note: given issue #48, #49 you currently need .NET 8 Preview 4 and not Preview 5 which is the default.

Check .NET runtimes and SDKs include 6.x and 8.x:

dotnet --list-sdks
dotnet --list-runtimes

Functions

Install AzureFunctions module for PowerShell (0.0.3)

Install-Module -Name AzureFunctions.PowerShell.SDK

Answer Y when prompts on untrusted registry. Note this brings in the Microsoft.Azure.Functions.CoreTools.4.0.5210.nupkg Nuget package so you don't need to bring it in explicitly.

Install Azure Functions Core Tools

Do manually for now using drop from Build server. It's still private only build.
Ensure you get func-cli-4.0.5210-x64.msi.

Public release looks like this:

winget install --id Microsoft.Azure.FunctionsCoreTools --source winget

In a new (restarted) PowerShell terminal window, verify install with:

func version

Output should be: 4.0.5210

If you're having path problems you can do this:

$env:Path += ';C:\Program Files\Microsoft\Azure Functions Core Tools\'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment