Skip to content

Commit 4527543

Browse files
Merge pull request #102 from PowershellFrameworkCollective/development
2.2.6.72
2 parents 3922a0e + 60c7427 commit 4527543

33 files changed

+636
-118
lines changed

PSModuleDevelopment.psprojs

Lines changed: 0 additions & 20 deletions
This file was deleted.

PSModuleDevelopment/PSModuleDevelopment.psd1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
RootModule = 'PSModuleDevelopment.psm1'
55

66
# Version number of this module.
7-
ModuleVersion = '2.2.6.68'
7+
ModuleVersion = '2.2.6.72'
88

99
# ID used to uniquely identify this module
1010
GUID = '37dd5fce-e7b5-4d57-ac37-832055ce49d6'
@@ -42,7 +42,7 @@
4242
# Modules that must be imported into the global environment prior to importing
4343
# this module
4444
RequiredModules = @(
45-
@{ ModuleName = 'PSFramework'; ModuleVersion = '0.10.31.176' }
45+
@{ ModuleName = 'PSFramework'; ModuleVersion = '1.0.19' }
4646
)
4747

4848
# Assemblies that must be loaded prior to importing this module

PSModuleDevelopment/PSModuleDevelopment.psm1

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,9 @@ function Import-PSMDFile
2929
$Path
3030
)
3131

32-
if ($script:doDotSource) { . (Resolve-Path $Path) }
33-
else { $ExecutionContext.InvokeCommand.InvokeScript($false, ([scriptblock]::Create([io.file]::ReadAllText($(Resolve-Path $Path)))), $null, $null) }
32+
$resolvedPath = $ExecutionContext.SessionState.Path.GetResolvedPSPathFromPSPath($Path).ProviderPath
33+
if ($script:doDotSource) { . $resolvedPath }
34+
else { $ExecutionContext.InvokeCommand.InvokeScript($false, ([scriptblock]::Create([io.file]::ReadAllText($resolvedPath))), $null, $null) }
3435
}
3536
#endregion Helper function
3637

PSModuleDevelopment/changelog.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
# Changelog
2+
## 2.2.6.72 (May 27th, 2019)
3+
- New: Template AzureFunction - Creates a basic azure function scaffold
4+
- New: Template AzureFunctionTimer - Creates a timer triggered Azure Function
5+
- Upd: Template AzureFunctionRest - Redesigned to only spawn a function rest endpoint to insert into the base AzureFunction template.
6+
- Upd: Template PSFProject - Improved Azure Functions creation experience, added client module support.
7+
28
## 2.2.6.68 (May 3rd, 2019)
39
- Upd: Template PSFProject - Improved Azure Functions creation experience
410

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
param (
2+
$Path
3+
)
4+
New-PSMDTemplate -ReferencePath "$PSScriptRoot" -OutPath $Path
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
@{
2+
TemplateName = 'AzureFunction'
3+
Version = "1.0.0.0"
4+
AutoIncrementVersion = $true
5+
Tags = 'azure', 'function'
6+
Author = 'Friedrich Weinmann'
7+
Description = 'Basic Azure Function Template'
8+
Exclusions = @("PSMDInvoke.ps1", ".PSMDDependency") # Contains list of files - relative path to root - to ignore when building the template
9+
Scripts = @{ }
10+
}

templates/AzureFunction/host.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"version": "2.0",
3+
"managedDependency": {
4+
"Enabled": true
5+
}
6+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Modules Folder
2+
3+
this folder will be part of the $env:PSModulePath while the function is running.

templates/AzureFunction/profile.ps1

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Azure Functions profile.ps1
2+
#
3+
# This profile.ps1 will get executed every "cold start" of your Function App.
4+
# "cold start" occurs when:
5+
#
6+
# * A Function App starts up for the very first time
7+
# * A Function App starts up after being de-allocated due to inactivity
8+
#
9+
# You can define helper functions, run commands, or specify environment variables
10+
# NOTE: any variables defined that are not environment variables will get reset after the first execution
11+
# Authenticate with Azure PowerShell using MSI.
12+
# Remove this if you are not planning on using MSI or Azure PowerShell.
13+
14+
if ($env:MSI_SECRET -and (Get-Module -ListAvailable Az.Accounts))
15+
{
16+
Connect-AzAccount -Identity
17+
}
18+
19+
# Uncomment the next line to enable legacy AzureRm alias in Azure PowerShell.
20+
# Enable-AzureRmAlias
21+
# You can also define functions or aliases that can be referenced in any of your PowerShell functions.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@{
2+
Az = '1.*'
3+
}

0 commit comments

Comments
 (0)