-
-
Notifications
You must be signed in to change notification settings - Fork 24
Description
I have the task BumpVersion that I want the Build task to depend on. That said, I found $PSBPreference.Build.Dependencies and have supplied the following array @('StageFiles', 'BuildHelp', 'BumpVersion'). However, BumpVersion never runs. StageFiles and BuildHelp do run.
Expected Behavior
When running the Build task, additional dependencies listed in $PSBPreference.Build.Dependencies should also run.
Current Behavior
When running the Build task, additional dependencies listed in $PSBPreference.Build.Dependencies do not run. Strangely enough, when supplying $PSBPreference.Build.Dependencies with only BumpVersion the default build task dependencies StageFiles and BuildHelp still run making me think $PSBPreference.Build.Dependencies is not even being correctly passed.
Possible Solution
I've verified $PSBPreference.Build.Dependencies is being supplied to the Build task here:
| task Build -depends $PSBPreference.Build.Dependencies -description 'Builds module and generate help documentation' |
Steps to Reproduce (for bugs)
- simply set
$PSBPreference.Build.Dependenciesin thepropertiesblock of apsakeFile.ps1with the value of @('MyExtraBuildTask') - create a task in the
psakeFile.ps1e.g...
task MyExtraBuildTask {
"doing extra things"
}
- run build.ps1
Context
I have a few extra tasks that I want to run as part of the build. Specifically, a task that bumps the module version if it has not already been incremented and also a task that uploads test results to appveyor when the BuildSystem is appveyor.
Your Environment
- Module version used:
PowerShellBuild = 0.3.0
Psake = 4.8.0 - Operating System and PowerShell version:
MacOS 10.14.6
PowerShell = 6.2.0