All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Pinned GitVersion to v5 in the pipeline since v6 is not yet supported, also updated templates to pin GitVersion v5. Workaround for issue #477.
- Fix issue template in repository and Plaster template (issue #483).
- Added extensions.json for vscode
- Automatic wiki documentation for public commands.
- Update template for SECURITY.md and add it to Sampler repository as well.
- Built module is now built in a separate folder. This is to split the paths
for the built module and all required modules, to avoid returning duplicate
modules when using
Get-Module -ListAvailable
. The templates already has this configuration. - Now PSResourceGet always default to the latest released version if no specific version is configured or passed as parameter.
- Templates was changed to use PSResourceGet as the default method of resolving dependencies. It is possible to change to the method PowerShellGet & PSDepend by changing the configuration. Also default to using PowerShellGet v3 which is a compatibility module that is a wrapper for the equivalent command in PSResourceGet.
- Switch to build worker
windows-latest
for the build phase of the pipeline due to a issue usingPublish-Module
on the latest updated build worker in Azure Pipelines. - Set_PSModulePath: The PSModulePath is now expanded and can therefore also contain variables.
- Switch to build worker
windows-latest
for the build phase of the pipeline due to a issue usingPublish-Module
on the latest updated build worker in Azure Pipelines. - Public command documentation has been moved from README.md to the GitHub repository Wiki.
- Update order of deploy tasks for the Plaster templates to make it easier to re-run a deploy phase when a GitHub token has expired.
- Update template for module.tests.ps1. Fixes #465
- Now the tasks work when using
Set-SamplerTaskVariable
with tasks that do not have the parameterChocolateyBuildOutput
. - Remove duplicate SECURITY.md template files, and fix templates to point to the single version.
- Correct description of the parameter
GalleryApiToken
in the build task script release.module.build.ps1. Fixes #442 - ModuleFast now supports resolving individual pre-release dependencies that is part of RequiredModules.psd1. It is also possible to specify NuGet version ranges in RequiredModules.psd1, although then the file is not compatible with PSResourceGet or PSDepend (so no fallback can happen).
- Now it won't import legacy PowerShellGet and PackageManagement when PSResourceGet or ModuleFast is used.
- Now it works saving PowerShellGet compatibility module when configured.
- Now if both ModuleFast and PowerShellGet compatibility module is configured PSResourceGet is automatically added as a dependency. This is for example needed for publishing built module to the gallery.
- Update pipeline so build not fail.
- Integration tests to build and import a module created using the Plaster template SimpleModule.
- Support ModuleFast when
restoring dependencies by adding the parameter
UseModuleFast
to thebuild.ps1
, e.g../build.ps1 -Tasks noop -ResolveDependency -UseModuleFast
or by enabling it in the configuration file Resolve-Dependency.psd1. Using ModuleFast will resolve dependencies much faster, but requires PowerShell 7.2. - Support for PSResourceGet (beta release).
If the modules PSResourceGet can be bootstrapped they will be used. If
PSResourceGet cannot be bootstrapped then it will revert to using
PowerShellGet v2.2.5. If the user requests or configures to use ModuleFast
then that will override both PSResourceGet and PowerShellGet. The method
PSResourceGet can be enabled in the configuration file Resolve-Dependency.psd1.
It is also possible to use PSResourceGet by adding the parameter
UsePSResourceGet
to thebuild.ps1
, e.g../build.ps1 -Tasks noop -ResolveDependency -UsePSResourceGet
. - When using PSResourceGet to resolve dependencies it also possible to
use PowerShellGet v2.9.0 (previous CompatPowerShellGet). To use the
compatibility module it can be enabled in the configuration file Resolve-Dependency.psd1.
It is also possible to use it by adding the parameter
UsePowerShellGetCompatibilityModule
to thebuild.ps1
, e.g../build.ps1 -Tasks noop -ResolveDependency -UsePSResourceGet -UsePowerShellGetCompatibilityModule
. The 2.9.0-preview has since then been unlisted, the compatibility module will now be released as PowerShellGet v3.0.0.
- Task
publish_nupkg_to_gallery
- Add support for publishing a NuGet package to a gallery using the .NET SDK in addition to using nuget.exe. Fixes #433
- Split up unit tests and integration tests in separate pipeline jobs since
integration tests could change state on a developers machine, and in the
current PowerShell session. Integration tests no longer run when running
./build.ps1 -Tasks test
. To run integration tests pass the parameterPesterPath
, e.g../build.ps1 -Tasks test -PesterPath 'tests/Integration'
. - Added sample private function and public function samples to Plaster template
SimpleModule so that it is possible to run task
test
without it failing. - Sample Private function tests updated to Pester 5.
- Sample Public function tests updated to Pester 5.
- Sampler's build.ps1 and the template build.ps1 was aligned.
- PowerShell Team will release the PSResourceGet compatibility module
(previously known as CompatPowerShellGet) as PowerShellGet v2.9.0 (or
higher). The resolve dependency script, when PowerShellGet is used, will
use
MaximumVersion
set to2.8.999
to make sure the expected PowerShellGet version is installed, today that it is v2.2.5. The 2.9.0-preview has since then been unlisted, the compatibility module will now be released as PowerShellGet v3.0.0.
- Fix unit tests that was wrongly written and failed on Pester 5.5.
- There was different behavior on PowerShell and Windows PowerShell when
creating the module manifest. So when the
modify
section that was meant to reuse the already present but commentedPrerelease
key it also ran themodify
statement that adds aPrerelease
key that is needed for a module manifest that is created under Windows PowerShell. This resulted in twoPrerelease
keys when creating a module under PowerShell 7.x. Now it will add a commentedPerelease
key and then nextmodify
statement will remove the comment, making it work on all version of PowerShell. Fixes #436. - The QA test template was updated so that it is possible to run the tests
without the need to add a git remote (remote
origin
).
- Fix Azure Pipeline bug to resolve errors and delays during the build process. Shallow fetch has been disabled to ensure complete repository cloning. Fixes #424
- Fix a bug that prevented downloading of dependent modules that has a dependency on the module PowerShell-Yaml. Fixes #421.
- Template
SimpleModule
- The template has been changed to create a module with the minimum scaffolding when using default values for the template questions. The minimum scaffolding enable the building and testing of the module, but default there is no pipeline so it possible to use any platform to run the pipeline.
- Additional template parameters have been added which will add additional
functionality to the module.
UseGit
- This parameter enables project files that helps with the use of Git for the project. The template will ask if Git should be used, default is No.UseGitVersion
- This parameter adds project files that helps with the use of GitVersion for the project. GitVersion is dependent on Git being used for the project. The template will ask if GitVersion should be used if the use of Git was chosen, default is No.UseCodeCovIo
- This parameter adds project files that helps with the use of CodeCov.io for the project. CodeCov.io is dependent on Git being used for the project. The template will ask if CodeCov.io should be used if the use of Git was chosen, default is No.UseGitHub
- This parameter adds project files that helps with the use of GitHb.com for the project. GitHub.com is dependent on Git being used for the project. The template will ask if GitHub.com should be used if the use of Git was chosen, default is No.UseAzurePipelines
- This parameter adds project files that enables the project to run the pipeline in Azure Pipelines (in Azure DevOps). The template will ask if Azure Pipelines should be used, default is No.UseVSCode
- This parameter adds project files that helps when using Visual Studio Code as the project code editor. The template will ask if Visual Studio Code should be used, default is No.
- The file
build.yaml
will only contain tasks fromSampler.GitHubTasks
if template parameterUseGitHub
is set to true (the answer to the template question is Yes). - The file
RequiredModules.psd1
will only contain the moduleSampler.GitHubTasks
if template parameterUseGitHub
is set to true (the answer to the template question is Yes). - If Git is not used (
UseGit
is false) the QA test that uses Git is removed for the generated filemodule.tests.ps1
.
- Removed module Plaster from the template file
RequiredModules.psd1.template
since it is not direct requirement for any project. It will still be saved tooutput/RequiredModules
for a project as it is defined as a required module in Sampler's module manifest, and Sampler is still a required modul. - Pipeline script for resolving dependencies improved.
- Evaluating PowerShellGet version now supports parameter
AllowOldPowerShellGetModule
(still not recommended to use this parameter). - Now defaults to save the modules PowerShellGet and PackageManagement
to the folder
output/RequiredModules
(same logic as for module PSDepend) to not make permanent changes to the contributors machine. If parameterPSDependTarget
is either set toCurrentUser
orAllUsers
the modules are installed.
- Evaluating PowerShellGet version now supports parameter
- Removed duplicate header in template file
README.md.template
. - Fix typo in the file
about_ModuleName.help.template
and inmodule.template
. - Integration tests clean up the test drive after each test.
- Update generated module manifest to have recommended values for properties. Fixes #326.
- Now correctly uses the key
CodeCoverage
in the filebuild.yaml.template
. Fixes #359. - Pipeline script for resolving dependencies improved.
Get-PackageProvider
no longer throws an exception when NuGet provider is missing (in Windows PowerShell in a clean Windows install).Install-PackageProvider
now defaults to installing in the current user scope to avoid requiring an elevated prompt. This is the only change that is permanent on the contributors machine. It is not possible to avoid this as long at the module PowerShellGet requires the NuGet package provider.- Remove duplicate code that set
AllowPrerelease
when installing package provider. - Fixed wrong splatting variable that prevented
Install-PackageProvider
to run. - Removing all existing PowerShellGet and PackageManagement module that is loaded into the session to load the newly saved or installed.
- Handle parameter
AllowOldPowerShellGetModule
when loading PowerShellGet module version. - Fix message on
Write-Progress
statement. - Small style cleanups.
- Fixed aliases in
prefix.ps1
to support ModuleBuild v3.0.0. The fix makes ModuleBuilder not seeing the aliases (using AST) so that the module manifest is not changed during build, instead they are exported during module import. In the future we could add a separate public file that defines the aliases to export so the module manifest is updated during build.
- Script
Set-SamplerTaskVariable.ps1
- Added debug output of PSModulePath
- Task
Build_ModuleOutput_ModuleBuilder
- Fixed #402: Using parameter
Filter
instead ofInclude
to get MOF files.
- Fixed #402: Using parameter
Get-MofSchemaName
- Permanently skipped a test that the build worker
ubuntu-latest
were unable to run due to missing shared library 'libmi'.
- Permanently skipped a test that the build worker
- Now the QA test that verifies that the Unreleased section header is present in the CHANGELOG.md correctly supports ChangelogManagement v3.0.1.
- Task
Convert_Pester_Coverage
- No longer throws an exception when there was just one missed command for a test suite. Fixes #407.
- Task
Build_ModuleOutput_ModuleBuilder
- Proper support for DSC composite resources (*.schema.psm1).
- Added task
Set_PSModulePath
.- Added function
Set-SamplerPSModulePath
. - Added tests for the task and function.
- Added task
Set_PSModulePath
tobuild.yml
Plaster template for project typedsccommunity
.
- Added function
- The QA tests can now be debugged by
Invoke-Pester
directly, before it had to be started by the build scriptbuild.ps1
. This will also help the Pester Tests VS Code extension to be able to run the tests.
- Removed the task
Set_Build_Environment_Variables
since it is not used, and build helpers are not in use anymore. Fixes #376. - Removed MOF based DSC resources from the CompleteModule sample.
- Added more unit tests to raise code coverage.
- Deprecated Pester 4 HQRM tests was removed from code coverage. The new Pester 5 HQRM test are in module DscResource.Test and is tested there.
- Task
copy_paths_to_choco_staging
- Now handle property
Exclude
andForce
correctly.
- Now handle property
Merge-JaCoCoReport
- Improvements to be able to merge missing elements, like entire element
<class>
,<sourcefile>
,<method>
.
- Improvements to be able to merge missing elements, like entire element
Get-MofSchemaName
- Correctly throws an error if the schema MOF cannot be parsed.
- Task
Convert_Pester_Coverage
- Removed one unused line of code.
- Moved one line of code so that code coverage threshold value will output correctly in some circumstances.
Set-SamplerTaskVariable
- Reverted code that was removed in pull request #383. The code is
necessary because how the commands
Get-BuiltModuleVersion
,Get-SamplerBuiltModuleManifest
,Get-SamplerBuiltModuleBase
, andGet-SamplerModuleRootPath
are currently built. The code that was reverted handles resolving the wildcard (*
) in the returned paths from the mentioned commands.
- Reverted code that was removed in pull request #383. The code is
necessary because how the commands
RequiredModules.psd1.template
- Fixes #397,
ModuleType
Plaster parameter.
- Fixes #397,
Resolve-Dependency.ps1
- Fixes #394,
AllowPrerelease
is ignored for bootstrap.
- Fixes #394,
module.tests.ps1.template
- Fixed code style according to this project's standard.
- Supports using a private Nuget repository, e.g. a Azure DevOps Server Pipelines feed that is using Windows integrated security, or a feed with no security.
- Now supports getting module version from
dotnet-gitversion
if it is available. - Tests now run in Pester 5.
- Added task
Create_Release_Git_Tag
to create a Git tag for a preview release. Fixes #351 - Added task
Create_Release_Branch
to push a branch containing the updated change log after release. Fixes #351
- The QA test that verifies that a change log entry has been added to CHANGELOG.md will no longer fail if the CHANGELOG.md has not been committed but is staged or unstaged. This makes it possible to get the QA tests to pass without having to first commit changes.
- Task
package_module_nupkg
now correctly adds the release notes to the Nuget package. Fixes #373 - Task
publish_module_to_gallery
now correctly adds the release notes to the published module. Fixes #373 - Fix a evaluation in the script
Set-SamplerTaskVariable
so it can be tested individually outside of the pipeline (usingInvoke-Pester
). - Fix all source files to UTF8 to comply with the HQRM tests (due to a bug in the HQRM tests that runs in Pester 4 this has not been detected until moving to Pester 5).
- Remove HQRM rule suppression in source file for
New-SamplerJaCoCoDocument
since it no longer required. - Fixed QA test that was breaking release.
- Fixed #384: It not tag is defined,
Create_Release_Git_Tag
throws an error.
- New task
Pester_Run_Times
that outputs each test's run time. Only works for Pester 5. The task will be skipped if Pester 4 is used.
- Fixed a problem which occurred on certain machined when using Sampler in Windows PowerShell. Fixes #350
- The module manifest is now correctly updated with release notes from the changelog. Fixes #358
- The task
Invoke_Pester_Tests_v5
generated a unexpected filename for the test results, compared to the Pester 4 task. Fixes #355
- Fixed GuestConfiguration build task on MOF file name equal to
localhost.mof
- Fixed explicit parameter value in
build.ps1
while calling.\Resolve-Dependency.ps1
- When running test using Pester 5, and the build configuration (
build.yaml
) do not specify the location of tests in the keyPath
, the pipeline will no longer run the tests twice. Fixes #337
- Switch to installing GitVersion using
dotnet tool install
. Fixes #348 - Updated pipeline to use the build worker image 'ubuntu-latest'.
- Updated pipeline to use the build worker image 'windows-latest'.
- Updated the Plaster templates
- to use 'dotnet tool install' in the pipeline.
- to use build image 'ubuntu-latest' in the pipeline.
- to use build image 'windows-latest' in the pipeline.
- Template file
Build/RequiredModules.psd1
that was not used.
- Added Pipeline to build chocolatey packages.
- Added Sample to add Chocolatey Package source files.
- Added New-SamplerPipeline to create build, Sampler Module or Chocolatey pipeline.
- Extra configuration files for passing to Azure Policy Guest Configuration Package on creation.
- Fixed
Resolve-Dependency.ps1
to not fail whenPowerShell-yaml
module was specified but already loaded (handle on dll). Fixes #335 - Fixed default source folder to source and not src.
- Fixed failed loading when there's no project name (when calling
Set-SamplerTaskVariable
). Fixes #331. - Fixed
Get-SamplerAbsolutePath
returning the wrong path in PowerShell and ISE. Fixes #341. - The templates was using the task
Create_ChangeLog_GitHub_PR
in the meta task publish that is also specifically run in a separate Azure Pipelines task. This made the task to run twice. - Fixed missing full stop (
.
) in the CONTRIBUTING.md and the template file. Fixes #333.
- Making sure the
Set-SamplerTaskVariable
does not fail when there's no Module manifest (i.e. when using Sampler for other reasons than building a module). - Switched the pipeline to use Ubuntu 18.04 instead of Ubuntu 16.04 as the build worker for some tasks.
- Template
SimpleModule
have been modified to remove unnecessary configuration (issue #277). - Template files are updated.
- Module script file no longer contain code that is irrelevant.
- Now asks if GitVersion should be used.
- Now asks if CodeCov.io should be used.
- Now asks for the upstream GitHub organization or account name to be used in Azure Pipelines.
- GitVersion.yml now uses the correct chosen default branch.
- Codecov.yml now uses the correct chosen default branch.
- Fixed GuestConfiguration compilation to work with GuestConfiguration module version 4.0.0-preview0002.
- Set the default type to AuditAndSet, but supporting override by creating a '$GCPackageName.psd1' file along with the config.
- Removed
PesterOutputFormat
parameter inDeployAll.PSDeploy.build.ps1
fix (issue #292). - Removed the template
newDscCommunity
which is replaced by the templatedsccommunity
.
- Added -WhatIf parameter to
release.module.build.ps1
- Merged both templates
dsccommunity
andnewDscCommunity
into the templatedsccommunity
. - All templates now defaults to using
main
as the default branch. - Updated Sampler documentation in README.md.
- Fix azure-pipelines.yml where variables are not possible to use (triggers and deploy condition).
- Fixed GitHub templates for the Sampler repository.
- Fixed GitHub templates in the DSC Community Plaster template.
- Task
Pester_If_Code_Coverage_Under_Threshold
- Now the code code coverage threshold is correctly reported using decimals.
- Added pester tests for
Set-SamplerVariableTask.ps1
.
- Changed Plaster Template (
Sampler/Templates/Sampler/plasterManifest.xml
), so that all functions will be exported by default, which in turn correlates with the template code inSampler/Sampler.psm1
, which usesExport-ModuleMember
to export all functions loaded from thePublic
(sub-)folder.
- Removed
$BuiltModuleSubdirectory
definition in thebegin
bloc ofbuild.ps1
template (issue #299). - Replaced
$ModudulePath
with$BuiltModuleBase
for therelease.module.build.ps1
task file.
- Added support of
BuiltSubDirectoryDirectory
in build configuration files (issue #299)
- The task
Invoke_Pester_Tests_v5
no longer fails when using Pester v5.3.0-alpha5 (issue #307). - The task
Convert_Pester_Coverage
no longer fails when using a preview version of Pester (issue #301).
- Task
Invoke_Pester_Tests_v4
- It now once again works using a hashtable together with parameter
PesterScript
(issue #303).
- It now once again works using a hashtable together with parameter
- If the Pester build configuration key
ExcludeFromCodeCoverage
does not specify a value, the taskInvoke_Pester_Tests_v5
no longer fails.
- Now the task
Pester_If_Code_Coverage_Under_Threshold
correctly honors the zero value (0
) of the parameterCodeCoverageThreshold
when usingbuild.ps1
, and honors the zero value (0
) of the Pester advanced build configuration keyCoveragePercentTarget
. If the value is set to0
the task will now be skipped since code coverage was disabled.
- Now the task
Pester_If_Code_Coverage_Under_Threshold
report the code coverage and correctly fail if the code coverage is under the code coverage threshold. - Task
Invoke_Pester_Tests_v5
- Now the Pester advanced configuration correctly handles
false
values in the build configuration files. - Now the Pester object, that is written to file by the pipeline, correctly
holds all expected objects.
Export-CliXml
defaulted to two levels of depth, now it exports five levels.
- Now the Pester advanced configuration correctly handles
- Added new public command
New-SamplerJaCoCoDocument
. - Added new public command
Out-SamplerXml
. - Added new private function
New-SamplerXmlJaCoCoCounter
. - Added new build task
Import_Pester
(issue #223). - Added new build task
Invoke_Pester_Tests_v5
(issue #223).- Task
Invoke_Pester_Tests_v5
will not run if Pester 4 is used in the pipeline.
- Task
- Added unit test for public command
Get-BuildVersion
.
- Renamed default branch to
main
(issue #235). - Added a public alias
Set-SamplerTaskVariable
that points to the scriptSet-SamplerTaskVariable.ps1
in the tasks folder. This alias is used to dot-source task variables for re-use over multiple build tasks. - Moved code from build task
Convert_Pester_Coverage
into a public functionNew-SamplerJaCoCoDocument
. - It is now possible to specify module's semantic version in the build.yml using
the key
SemVer
, e.g.SemVer: '99.0.0-preview1'
. This can be used if the preferred method of using GitVersion is not available, and it is not possible to set the session environment variable$env:ModuleVersion
, nor setting the variable$ModuleVersion
in the PowerShell session (parent scope) before running the taskbuild
(issue #279). - Templates
- build.yaml
- Comment Pester tag exclusion for all templates so that the default is to use all QA test.
- Added comment task
Convert_Pester_Coverage
for the test task. - Removed leftovers from key DscTest that was kept when using template 'SimpleModule'.
- Updated with entries to support several code coverage scenarios, some initially commented.
- azure-pipelines_dsccommunity.yml
- Updated with the latest code coverage scenarios, some initially commented.
- azure-pipelines.yml
- Updated with the latest code coverage merge scenario.
- codecov_dsccommunity.yml
- Removed and replaced with codecov.yml.template
- codecov.yml.template
- Codecov.yml is now added for several templates and features. Content is dependent on the template that is used.
- Now the template 'dsccommunity' gets a
README.md
file.
- build.yaml
- Task
Invoke_Pester_Test
was renamed toInvoke_Pester_Tests_v4
.- Pester 5 support was removed from the task and replaced with
Invoke_Pester_Tests_v5
- Task
Invoke_Pester_Tests_v4
will not run if Pester 5 is used in the pipeline.
- Pester 5 support was removed from the task and replaced with
- Meta build task
Pester_Tests_Stop_On_Fail
was change to runImport_Pester
,Invoke_Pester_Tests_v4
(previouslyInvoke_Pester_Test
), andInvoke_Pester_Tests_v5
.- Task
Invoke_Pester_Tests_v4
will not run if Pester 5 is used in the pipeline. - Task
Invoke_Pester_Tests_v5
will not run if Pester 4 is used in the pipeline.
- Task
- The task Convert_Pester_Coverage was changed to support converting Pester 5 code coverage.
- The function
Get-CodeCoverageThreshold
was changed to support Pester 5 advanced build configuration. - The function
Get-SamplerCodeCoverageOutputFile
was changed to support Pester 5 advanced build configuration.
- Renamed task file from
Merge-CodeCoverageFiles.pester.build.ps1
toJaCoCo.coverage.build.ps1
. - Move task Convert_Pester_Coverage to task file
JaCoCo.coverage.build.ps1
. - Resolve-Dependency.ps1: fix MinimumPSDependVersion comparison.
- Resolve-Dependency.ps1: add -Force to all Save-Module.
New-SamplerJaCoCoDocument
- Fixed counters when a method only had either one hit line or one missed line.
- Now unit tests properly test the function in the built module, not the ones that the pipeline dot-sources into session to be able to dogfooding itself.
- Fix so that Convert_Pester_Coverage correctly replaces build version with source folder in JaCoCo file.
- Fix task Convert_Pester_Coverage so it is skipped when
CodeCoverageThreshold
is0
.
- Resolve-Dependency.ps1 PSDependTarget param no longer includes period.
- Resolve-Dependency.ps1 Save-Module added -Force switch to create non-existent directory.
- Support for Generating MAML help files (all Locale/Culture) from PlatyPS Markdown Source.
- Support for Updating the PlatyPS Markdown source in your repo (this is a dev task to do before a commit).
- Support for Generating MAML file from Comment-based help (not recommended).
- Support for code coverage when using ModuleBuilder pattern for building module.
Update-JaCoCoStatistic
- Added unit test.
- Pipeline updated to support merging code coverage between operating system pipeline jobs.
Merge-JaCoCoReport
- Now correctly adds new packages to the original document.
- Moves the
report
element'scounter
elements to the bottom of thereport
element to comply with the DTD.
Update-JaCoCoStatistic
- Fixed so that statistics are updated correctly for the 'CLASS' counter.
- Fixed codecov.yml to parse version number in paths correctly.
- Fix uploading to Azure Code Coverage.
- Merge_CodeCoverage_Files
- Fixed so the file that is outputted is in UTF-8 (without BOM) to support Codecov.io.
- The task now only searches for the file pattern inside the
./output/testResults
folder. - The merge process is not attempted if
CodeCoverageThreshold
is set to0
. - Updated so that build.yaml now have a key
CodeCoverage
which have to settingsCodeCoverageMergedOutputFile
andCodeCoverageFilePattern
.
- Convert_Pester_Coverage
- The backup file now have the extension
.bak
(instead of.bak.xml
) so that is not mistakenly used by a task Merge_CodeCoverage_Files. - Some code cleanup.
- The backup file now have the extension
- Fixed issue with uncommenting release notes in module manifest
- Fix to use the correct path when determine class-based resources.
- Fix issue when there is no root module.
- Fix to use the correct path when determine class-based resources.
- Error when the Module has no RootModule script (manifest only with DSC resources).
- Fixed #247 where Building submodule would fail on linux (but not WSL).
- Fixed #239 to re-add support for BuiltModuleSubdirectory more consistently.
- Fixed bug when using CopyOnly nested resources.
- Made Convert-SamplerHashtableToString public function.
- Refactored a lot of Path resolution into Sampler public function for consitency and re-usability.
- Updated the Tasks to use those Sampler functions.
- Updated Get-BuiltModuleVersion to support $BuiltModuleSubdirectory as per #239.
- Added Get-SamplerAbsolutePath, Get-SamplerBuiltModuleBase, Get-SamplerModuleInfo, Get-SamplerBuiltModuleManifest, Get-SamplerModuleRootPath.
- New DSC Community template (
New-SampleModule -ModuleType newDscCommunity
).
- Fixes #222: Adding *.dll binary to gitattributes.
- Fixes eol for file types .sh .svg .sh .mof
- Fixes #225 by asking the question or assuming the default is
main
in most cases. - Readded the
Create_ChangeLog_GitHub_PR
task to the publish workflow and template. - Fixes newDscCommunity template missing the psm1 and the Required modules.
- Extracted the Common functions to be within the main Sampler module to enable re-usability.
- Updated this project's
build.ps1
to load the Private/Public *.ps1 so it can build itselves without impacting Sampler templates. - Added empty functions' Unit test files (for subsequent PR when writing moving to Pester 5).
- Added Comment-based help for the extracted functions.
- Dropped the CodeCoverage Threshold of the project to reflect the newly discovered code (
Common.Functions.psm1
wasn't counted for code coverage).
- Removed the GitHub functions to publish them in the
Sampler.GitHubTasks
module.
- Added the build_guestconfiguration_packages task to create GuestConfig packages using the GuestConfiguration module.
- Added GCPackage template so that you can use
Add-Sample -Sample GCPackage
to add a GC Package to your Sampler project. - Added the gcpack meta task to call clean, build, and build_guestconfiguration_packages for you.
- Fixed bug when using
PesterScript
with the build taskInvoke_Pester_Tests
when running Pester 5.
- Update
build.ps1
with an aliasPesterPath
for the parameterPesterScript
so that repositories that move over to Pester 5 can future-proof the fileazure-pipelines.yml
(for example when splitting tests over several jobs). The parameterPesterScript
is deprecated and will be removed when Pester 4 support is removed some time in the future. Change scripts toPesterPath
when migrating to Pester 5 tests.
- The Deploy tasks
publish_nupkg_to_gallery
andpublish_module_to_gallery
are now made mutually exclusive. For each deploy pipeline you must choose to use either one.publish_nupkg_to_gallery
is usingnuget
to publish to the gallery.publish_module_to_gallery
is using the cmdletPublish-Module
to publish to the gallery.
- Fix issue in DscResourcesToExport task to properly process DscResource schema (issue #230).
- Fix uploading of code coverage when using the DSC Community template.
- Update the Readme.md to fix a few typos.
- Fix wrong resource name is added in module manifest property DscResourcesToExport (issue #220)
- Updating all azure-pipeline.yaml to change Build Artifacts to Pipeline Artifacts (issue #159).
- Update plasterManifest.xml call by New-SampleModule :
- Changing ClassResource.
- Add generic content in the class.
- Add pester tests.
- Add localizeddata.
- Update plasterManifest.xml.
- Add private functions.
- Add pester tests.
- Update Sampler integration tests.
- Changing the Reasons property in the classes based resource template. It's now NotConfigurable.
- Renamed Build_Module_ModuleBuilder task to Build_ModuleOutPut_ModuleBuilder. Build_Module_ModuleBuilder is now a metatask that calls Build_ModuleOutPut_ModuleBuilder and Build_DscResourcesToExport_ModuleBuilder tasks.
- Added new template ClassFolderResource
- Added new function Get-ClassBasedResourceName on Common.Functions.psm1 module. It's used to find the class-based resource defined in psm1 file.
- Added new task Build_DscResourcesToExport_ModuleBuilder. On build, it adds DscResources (class or Mof) in DscResourcesToExport manifest key.
- Fixed Test-ModuleManifest (issue #208) in tasks.
- Added GitHub config element template.
- Added vscode config element template.
- Added a new template file for azure-pipelines.yml when using the
module type
'dsccommunity'
. - Added a new template and configuration for Codecov.io when using
module type
'dsccommunity'
.
- Renamed the moduleType 'CompleteModule' to CompleteSample.
- Updated changelog (removed folder creation on simple modules).
- Updated doc.
- Updated code style to match the DSC Community style guideline.
- Updated logic that handles the installation on PSDepend in the bootstrap
file
Resolve-Dependency.ps1
. - Updated year in LICENSE.
- Updated the template GitVersion.yml to use specific words to bump major version (previously it bumped if the word was found anywhere in the commit message even if it was part of for example a code variable).
- Updated the template file build.yaml to make it more clean when using
the module type
'dsccommunity'
. - Updated so that the module type
'dsccommunity'
will add a CHANGELOG.md. - Updated so that the module type
'dsccommunity'
will add the GitHub templates.
- Fixed missing 'PSGallery' in build files when the Plaster parameter
CustomRepo
is not assigned a value. - Fixed a whitespace issue in the template file Resolve-Dependency.psd1.
- Rephrased comments in the template file build.yaml.
- Removed the CompletModule_noBuild template as it's unecessary and add complexity to the template.
- Fixed the Build of template with DSC Resource by adding required modules, config & helper modules tests.
- Fixed the issue with the Publish module task (always use Publish-Module unless you want to UseNugetPush).
- Fixed build error when the "Update changelog" PR is created (and no changes exists).
- Fixed when creating a Module from template and the Build.yml does not copyPaths: DscResources.
- Fixed #192 where the
Build-Module
command from module builder returns a rooted path (sometimes).
- Added New-SampleModule command to invoke the template.
- Added Add-Sample command to invoke component templates
- Fixed pack action & nuget push.
- Fixed
New-Release.GitHub.build.ps1
taskCreate_ChangeLog_GitHub_PR
so that it respectsMainGitBranch
if passed.
- Added Templates for:
- DSC Composite
- Class-based DSC Resource with reasons
- MOF based DSC Resource and tests
- Private Function and tests
- Public Function and tests
- Public function calling a Private function and tests
- Classes and tests
- Enum
- Added integration tests for the Plaster templates.
- Added support to use an alternate name for the trunk branch in
New-Release.GitHub.build.ps1
(issue #182). - Added additional log output to
New-Release.GitHub.build.ps1
. - Corrected markdown format in CHANGELOG.md to remove linting messages.
- Removing main module's BOM from built PSM1 when built in Windows PowerShell.
- Resolve-Dependency when running in vscode and PS7 is installed.
- Fixed
module.tests.ps1
to be able to run locally.
- Duplicate integration test for template.
- Added fix to support Pester 4 parameters.
- Fix for Pester 5.0.1 making sure only to use the
Simple
ParameterSet. - Fix typo in
DscResource.Test
task. - Updated style in
generateHelp.PlatyPS
task.
- Added Pester 5 support in the CI pipeline
test
andhqrmtest
task. - Pinned the module Pester to v4.10.1 in the file
RequiredModule.psd1
until this repo is converted to Pester 5. - Update build task to pass the full path to the module manifest to
Build-Module
to be able to build without a build manifest. - Remove the build manifest from Sampler and Plaster template.
- Change the build.yaml to use
CopyPaths
instead ofCopyDirectories
.
- Removed not needed attempt to use ModuleBuilder's build manifest (build.psd1)
from the build task. It was trying to determine the source path by using
the
SourcePath
property from the build manifest. But since the build manifest is in the source path the source path must already be known to be able to import the build manifest. Catch 22. The code also wrongly assumed that theSourcePath
needed to include the module manifest file which it should not since that is determined by ModuleBuilder using the source path as base path.
- Updated README.md with a section
Task Variables
and described each of the build taskBuild-Module.ModuleBuilder
's task variables. - When there are multiple module manifest found in the repository the build now fails with a a better error error message (issue #155).
- Now the the module does not export the helper function modules as tasks aliases (issue #161).
- Fixed so module version can be detected using GitVersion on macOS and Linux.
- Update tasks to reduce code duplication (issue #125).
- Task 'Merge_CodeCoverage_Files' did not use the parameter
ProjectName
to that parameter was removed. - Tasks that are not setting the version in the module manifest or otherwise need to evaluate the module version are now using the the module version from the built module's module manifest (issue #160).
- The helper function
Get-ModuleVersion
was split into two cmdlets. A new helper functionGet-BuildVersion
that evaluates and returns the next module version, andGet-BuiltModuleVersion
that always returns the module's version from the built module manifest.
- The task build will no longer fail if GitVersion is not installed and there are no output folder.
- Add new build task
Generate_Wiki_Content
for the DSC Community module type.
- Update the repository to always use the latest version of the module
ModuleBuilder
.
- Now the prerelease is cleaned so that it does not contain any dashes by
removing any suffix after a dash, for example
pr054-0012
will be changed to justpr054
as the prerelease string. This is due to a bug in the cmdletPublish-Module
together with a newer version of the moduleModuleBuilder
.
- It no longer updates the module manifest release notes in the task
publish_module_to_gallery
, because that is already done in the taskcreate_changelog_release_output
that is run in the build step. The taskpublish_module_to_gallery
was still dependent on the taskcreate_changelog_release_output
was run for it to be able to update the release notes in the module manifest, sopublish_module_to_gallery
could never have been run independent of taskcreate_changelog_release_output
.
- The regular expression for
minor-version-bump-message
in the fileGitVersion.yml
was changed to only raise minor version when the commit message contain the wordadd
,adds
,minor
,feature
, orfeatures
.
- Correctly evaluate the module version in task
publish_module_to_gallery
.
- Now the module manifest release notes is only updated with the latest release. This fixes the issue with the limitation for the release notes in the module manifest when releasing a module to PowerShell Gallery. If all the change log entries for the latest release still exceed the max hard limit then the release notes will be truncated to the max hard limit.
- The CI pipeline was updated with working build images.
- Changed build tasks to use the helper function
Get-ModuleVersion
to reduce code duplication. - Changed each build task so that the default value of the parameter
ModuleVersion
always returns the sematic version (x.y.z-prerelease), and not the informational version (issue #130).
- Added the functionality to merge multiple JaCoCo code coverage files into one file.
- Added warning messages to all build task if the task couldn't be imported because of an invalid PSD1 file.
build.ps1
will now dynamically determine the build configuration if not specified via the-BuildConfig
parameter.- Updated the PesterScript parameter to allow the specification of hastables, to enable specifying parameters to Pester.
- Add conceptual build step for DSC resources issue #122.
- Added the option to specify
CodeCoverageOutputFile
andCodeCoverageOutputFileEncoding
in the filebuild.yml
. For example if a code coverage provider need the file to be named in a certain way.
- Added new common functions for build tasks to reduce code duplication.
- Removed Azure-Pipelines.yml on simple module type.
- Ensuring Pester version above 4.0 is used and loaded.
- build.yaml, RequiredModules.psd1 and Resolve-Dependency.psd1 are now templated assets with conditional content.
- HQRM tests to run only when using the dsccommunity module type.
- Updated simple module to not contain sample scripts & tests.
- supports setting CustomRepo to pull dependencies from a private gallery other than PSGallery.
- Update the plaster template to replace 'synedgy' with 'dsccommunity' if the module type is 'dsccommunity'.
- The deploy step is no longer run if the Azure DevOps organization URL does not contain 'synedgy'.
- VSCode template setting
pipelineIndentationStyle
.
- Update GitVersion.yml with the correct regular expression.
- Fix casing in key names in
azure-pipelines.yml
.
- Set a display name on all the jobs and tasks in the CI pipeline.
- Azure Pipelines will no longer trigger on changes to just the CHANGELOG.md.
- Updated
build.ps1
to add DscTestTag, DscTestExcludeTag parameters. - Updated module manifest to support PS 5.0.
- updated Contributing.md to redirect to dsccommunity.org
- Set
testRunTitle
for PublishTestResults steps inazure-pipelines.yml
so that a helpful name is displayed in Azure DevOps for each test run. - Removed unnecessary comments from
azure-pipelines.yml
.
- Fixing the codecoverage threshold issues reported by Daniel (As param set to 0 should not bypass).
- Removing QA tests from dsccommunity template.
- Added Module manifest in build.psd1 template to fix issue resolving Project on linux.
- Added DSC Resources & Supporting modules (including one from PSGallery, one from source).
- Added PesterScript parameter in Build.ps1 so that it can be overridden at runtime (in azure-pipelines.yml).
- Added
Modules
commented out to thebuild.yml
- Added CodeCoverageThreshold parameter to fail when under threshold
(configurable in
build.yaml
). Will skip all code coverage when set to 0 (build.ps1 parameter override build.yml config). - Added Tasks.json with build and test tasks. (VSCode bug when you click on Problems, Integrated terminal crashes).
- Made Code Coverage threshold to load from config file, and be skipped completely if set to 0 or absent.
- Updating Code of Conduct to the DSC Community one.
- Made build.ps1 & Resolve-Dependency.ps1 compliant with DSC Style guidelines
- removed unnecessary file from Plaster template
- Fixed when the SourcePath is not enough for finding ModuleManifest (ModuleBuilder bug)
- Updating QA tests function discovery to look within loaded module
- Support for Pester parameter in Config File
- Making Plaster Template Discoverable by Get-PlasterTemplate -IncludeInstalledModules
- Template not including RootModule anymore
- Uncomment ReleaseNotes from module manifest before updating
- Skip Changelog test when not in a git repo
- Shields badge on the readme page
- Release notes to module manifest
- Changelog compiled to release notes
- use release notes for publishing to GH
- fixed template
- fixed the publishing to also pack Nupkg
- Added hidden files as template assets
- fixed git test to skip test on new module scaffolding
- fixed default DscResources from copy-item in build yaml
- old file reference with wrong case
- remove kitchen yaml from template
- Add condition to trigger deployment stage when building a tag (not master)
- Fixing GitHub config for creating Changelog PR
- Changed the Tags trigger to include "v*" but still exclude "-"
- Packaging module to nupkg
- Adding Auto-creation of GitHub PR for Changelog update on release
- for changes in existing functionality.
- changed continuous deployment to continuous delivery in gitversion
- extracted GitHub functions into separate file
- for soon-to-be removed features.
- in case of vulnerabilities.
- Fixing Create ChangeLog PR Get-Variable
- fixing versioning by reverting to gitversions' continuousDeployment mode
- fixed #22: marking github releases as pre-release when there's a PreReleaseTag
- fix call to add assets to GH release.
- for any bug fixes.
- for now removed features.
- dummy release for example