Skip to content

Commit

Permalink
Merge pull request #62 from techthoughts2/Enhancements
Browse files Browse the repository at this point in the history
Enhancements
  • Loading branch information
techthoughts2 authored Nov 6, 2022
2 parents 8405155 + aa018ec commit fe9de27
Show file tree
Hide file tree
Showing 20 changed files with 187 additions and 121 deletions.
136 changes: 74 additions & 62 deletions .github/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.2.6]

- Catesta template module changes
- Fixed casing issue in all templates that caused Catesta to have an issue on certain Linux distros
- Fixed bug where vault templates were referencing an incorrect version of Microsoft.PowerShell.SecretManagement
- InvokeBuild bumped from `5.9.11` to `5.10.1`
- PSScriptAnalyzer bumped from `1.20.0` to `1.21.0`
- Catesta primary module changes
- Added infrastructure tests to check for casing violations
- InvokeBuild bumped from `5.9.11` to `5.10.1`
- PSScriptAnalyzer bumped from `1.20.0` to `1.21.0`

## [1.2.3]

- Minor spelling corrections throughout
Expand All @@ -20,108 +32,108 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- Catesta template module changes
- Improved plaster references throughout Catesta to better handle situations when a user choose Pester 4 vs Pester 5. While this affects a few minor files it primarily focuses on updating the way VSCode tasks are engaged.
- ```tasks.json```
- ```PesterTest```, ```Pester-Single-Coverage```, ```Pester-Single-Detailed```, ```DevCC-Single``` tasks no longer use legacy parameters for Pester 5
- Updated to no longer reference the Module name directly. Instead ```${workspaceFolderBasename}``` is used throughout the tasks file now.
- `tasks.json`
- `PesterTest`, `Pester-Single-Coverage`, `Pester-Single-Detailed`, `DevCC-Single` tasks no longer use legacy parameters for Pester 5
- Updated to no longer reference the Module name directly. Instead `${workspaceFolderBasename}` is used throughout the tasks file now.
- All bootstrap files:
- Pester bumped from ```5.3.1``` to ```5.3.3```
- InvokeBuild bumped from ```5.8.8``` to ```5.9.11```
- Microsoft.PowerShell.SecretManagement bumped from ```1.1.1``` to ```1.1.2```
- Pester bumped from `5.3.1` to `5.3.3`
- InvokeBuild bumped from `5.8.8` to `5.9.11`
- Microsoft.PowerShell.SecretManagement bumped from `1.1.1` to `1.1.2`
- AWS CodeBuild CI/CD changes:
- ```PowerShellCodeBuildGit.yml```
- ```aws/codebuild/windows-base:2019-1.0``` to ```aws/codebuild/windows-base:2019-2.0```
- ```aws/codebuild/standard:5.0``` to ```aws/codebuild/standard:6.0```
- All Lambdas updated from ```Runtime: python3.6``` to ```Runtime: python3.9```
- ```PowerShellCodeBuildGit.yml```
- ```aws/codebuild/windows-base:2019-1.0``` to ```aws/codebuild/windows-base:2019-2.0```
- ```aws/codebuild/standard:5.0``` to ```aws/codebuild/standard:6.0```
- `PowerShellCodeBuildGit.yml`
- `aws/codebuild/windows-base:2019-1.0` to `aws/codebuild/windows-base:2019-2.0`
- `aws/codebuild/standard:5.0` to `aws/codebuild/standard:6.0`
- All Lambdas updated from `Runtime: python3.6` to `Runtime: python3.9`
- `PowerShellCodeBuildGit.yml`
- `aws/codebuild/windows-base:2019-1.0` to `aws/codebuild/windows-base:2019-2.0`
- `aws/codebuild/standard:5.0` to `aws/codebuild/standard:6.0`
- buildspec updates
- Updated runtime version from ```dotnet: 3.1``` to ```dotnet: 6.0```
- ```buildspec_pwsh_linux.yml```
- ```buildspec_pwsh_windows.yml```
- ```install_modules.ps1```
- AWS.Tools.Common bumped from ```4.1.17.0``` to ```4.1.133```
- Minimum version of ```Microsoft.PowerShell.SecretManagement``` for vault builds is now ```1.2.3```
- Updated runtime version from `dotnet: 3.1` to `dotnet: 6.0`
- `buildspec_pwsh_linux.yml`
- `buildspec_pwsh_windows.yml`
- `install_modules.ps1`
- AWS.Tools.Common bumped from `4.1.17.0` to `4.1.133`
- Minimum version of `Microsoft.PowerShell.SecretManagement` for vault builds is now `1.2.6`
- Catesta primary module changes
- ```tasks.json```
- ```PesterTest```, ```Pester-Single-Coverage```, ```Pester-Single-Detailed```, ```DevCC-Single``` tasks no longer use legacy parameters for Pester 5
- Pester bumped from ```5.3.1``` to ```5.3.3```
- InvokeBuild bumped from ```5.8.8``` to ```5.9.11```
- `tasks.json`
- `PesterTest`, `Pester-Single-Coverage`, `Pester-Single-Detailed`, `DevCC-Single` tasks no longer use legacy parameters for Pester 5
- Pester bumped from `5.3.1` to `5.3.3`
- InvokeBuild bumped from `5.8.8` to `5.9.11`

## [1.0.0]

- Catesta template module changes
- All build yaml files - added commented line for easily retrieving modules/variables/env variables are available in the build image
- All bootstrap files:
- Pester bumped from ```5.2.2``` to ```5.3.1```
- InvokeBuild bumped from ```5.8.0``` to ```5.8.8```
- PSScriptAnalyzer bumped from ```1.19.1``` to ```1.20.0```
- Microsoft.PowerShell.SecretManagement bumped from ```1.0.0``` to ```1.1.1```
- Pester bumped from `5.2.2` to `5.3.1`
- InvokeBuild bumped from `5.8.0` to `5.8.8`
- PSScriptAnalyzer bumped from `1.19.1` to `1.20.0`
- Microsoft.PowerShell.SecretManagement bumped from `1.0.0` to `1.1.1`
- AWS CodeBuild CI/CD changes:
- ```PowerShellCodeBuildGit.yml```
- `PowerShellCodeBuildGit.yml`
- Now enables user to specify Branch name on Webhook filter. Default is set to main.
- Updated reference links
- ```install_modules.ps1```
- `install_modules.ps1`
- Minor spelling correction
- AWS.Tools.Common bumped from ```4.1.2.3``` to ```4.1.17.0```
- ```New-PowerShellProject.ps1``` & ```New-VaultProject.ps1```
- AWS.Tools.Common bumped from `4.1.2.6` to `4.1.17.0`
- `New-PowerShellProject.ps1` & `New-VaultProject.ps1`
- Minor formatting updates
- Appveyor CI/CD changes:
- ```appveyor.yml```
- `appveyor.yml`
- Updated windows images to more recent versions
- Windows Powershell from 2017 to 2019
- PowerShell from 2019 to 2022
- Azure DevOps CI/CD changes:
- ```azure-pipelines.yml```
- `azure-pipelines.yml`
- ubuntu-latest
- No longer installs PowerShell core (PowerShell 7 is now native to image)
- switched from script using ```pwsh -c ''``` style to native ```-pwsh: |``` call
- switched from script using `pwsh -c ''` style to native `-pwsh: |` call
- macOS-latest
- switched from script using ```pwsh -c ''``` style to native ```-pwsh: |``` call
- ```tasks.json```
- switched from script using `pwsh -c ''` style to native `-pwsh: |` call
- `tasks.json`
- Adjusted formatting
- Updated documentation
- Updated references to align with new tasks requirements
- Catesta primary module changes
- **Updated primary branch name from master to main**
- Updated references from master to main throughout repository
- Pester bumped from ```5.2.2``` to ```5.3.3```
- InvokeBuild bumped from ```5.8.0``` to ```5.9.11```
- PSScriptAnalyzer bumped from ```1.19.1``` to ```1.20.0```
- ```tasks.json```
- Pester bumped from `5.2.2` to `5.3.3`
- InvokeBuild bumped from `5.8.0` to `5.9.11`
- PSScriptAnalyzer bumped from `1.19.1` to `1.20.0`
- `tasks.json`
- Adjusted formatting
- Updated documentation
- Updated references to align with new tasks requirements
- ```Catesta.build.ps1```
- `Catesta.build.ps1`
- Updated pester module import to use a min/max value
- Documentation updates
- Minor README corrections/updates
- AWS
- Updated ```Catesta-AWS.md```
- Updated `Catesta-AWS.md`
- Re-did several AWS diagrams and included raw drawio diagrams
- Updated screenshots
- AppVeyor
- Updated ```Catesta-AppVeyor.md```
- Updated `Catesta-AppVeyor.md`
- Added diagram
- Updated screenshots
- GitHub Actions
- Updated ```Catesta-GHActions.md```
- Updated `Catesta-GHActions.md`
- Added diagram
- Azure DevOps
- Updated ```Catesta-Azure.md```
- Updated `Catesta-Azure.md`
- Added diagram
- Updated ```Catesta-FAQ.md```
- Updated ```Catesta-Vault-Extension.md```
- Updated `Catesta-FAQ.md`
- Updated `Catesta-Vault-Extension.md`

## [0.12.4]

- ```*.build.ps1```
- Test task now correctly references ```$script:UnitTestsPath``` instead of overall ```$script:TestsPath```
- DevCC task now correctly references ```$script:UnitTestsPath``` instead of ```'Tests\Unit'```
- Infra task now correctly references ```$script:InfraTestsPath``` instead of ```'Tests\Infrastructure'```
- Adjusted ValidateRequirements task to work with ```[version]``` type when verifying minimum version of PowerShell to validate
- `*.build.ps1`
- Test task now correctly references `$script:UnitTestsPath` instead of overall `$script:TestsPath`
- DevCC task now correctly references `$script:UnitTestsPath` instead of `'Tests\Unit'`
- Infra task now correctly references `$script:InfraTestsPath` instead of `'Tests\Infrastructure'`
- Adjusted ValidateRequirements task to work with `[version]` type when verifying minimum version of PowerShell to validate
- Added new BuildNoInfra task for building module without running Infra tests
- ```tasks.json```
- `tasks.json`
- Added new VSCode tasks
- BuildNoInfra - runs BuildNoInfra tasks
- Pester-Single-Coverage - enables user to run pester test for single function and get code coverage report
Expand All @@ -130,7 +142,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [0.12.1]

- Changed the Pester 5 minimum version requirement from ```v5.0.0``` to ```v5.2.2```
- Changed the Pester 5 minimum version requirement from `v5.0.0` to `v5.2.2`
- Updated CloudFormation GitHub template to use CodeBuild image version 5.0.

## [0.12.0]
Expand All @@ -140,19 +152,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Some CICD containers have the Pester module loaded into memory. Added explicit remove in the build file to account for this.
- Moved Pester import handling from the buildspec/yaml to InvokeBuild
- Updated pester tests that were using legacy Should syntax (without dashes)
- Fixed ```tasks.json``` VSCode file to be valid json (was missing comma)
- Fixed `tasks.json` VSCode file to be valid json (was missing comma)
- Added prompt on ModuleOnly module type to prompt user if they want helpful .vscode files for their module project
- Catesta now deploys the initial sample module in a style that better reflects a real-world module
- The private sample function was renamed to Get-Day and gets the day of the week
- The public sample function now returns hello world with the day of the week included
- Sample tests are now created for these sample functions in the appropriate public/private folders under the Tests/Unit folder
- Sample tests now actually test the sample functions
- AppVeyor CI/CD changes:
- Updated Ubuntu image from ```Ubuntu1804``` to ```Ubuntu2004```
- Updated Ubuntu image from `Ubuntu1804` to `Ubuntu2004`
- Azure DevOps CI/CD changes:
- The latest macOS image [now includes PowerShell](https://github.com/actions/virtual-environments/blob/main/images/macos/macos-10.15-Readme.md) by default - removed step in yaml to install PowerShell.
- AWS CodeBuild CI/CD changes:
- CB Linux Image updated in CFN from ```Image: aws/codebuild/standard:4.0``` to use latest: ```Image: aws/codebuild/standard:5.0```
- CB Linux Image updated in CFN from `Image: aws/codebuild/standard:4.0` to use latest: `Image: aws/codebuild/standard:5.0`
- Updated buildspec_pwsh_windows.yml to use the new syntax for installing PowerShell 7.

```bash
Expand All @@ -161,20 +173,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
```

- Added additional documentation links to the buildspec files
- InvokeBuild bumped from ```5.6.1``` to ```5.8.0```
- InvokeBuild bumped from `5.6.1` to `5.8.0`
- Catesta primary module changes
- Updated pester tests that were using Legacy Should syntax (without dashes)
- Updated pester tests to support v5+
- InvokeBuild bumped from ```5.6.1``` to ```5.8.0```
- InvokeBuild bumped from `5.6.1` to `5.8.0`

## [0.11.0]

- Adjusted vault templates to include the new capabilities in SecretManagement RC2
- New optional cmdlets
- New metadata parameter on several cmdlets
- Added new optional vault parent .psm1 example file
- Catesta now references the GA version of ```Microsoft.PowerShell.SecretManagement```
- Added best practice naming suggestion to ```New-VaultProject```
- Catesta now references the GA version of `Microsoft.PowerShell.SecretManagement`
- Added best practice naming suggestion to `New-VaultProject`
- Corrected verbiage on several commands to properly reflect which module project was being scaffold
- Fixed bug where module would fail to scaffold on Linux systems due to case sensitivity of path

Expand Down Expand Up @@ -220,7 +232,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Added build steps which import the module manifest explicitly
- Adjusted ExportedFunctions.Tests.ps1 to check for included example rather than example count
- Updated a few areas of documentation/help to provide more clarification
- Updated .vscode settings to use ```${workspaceFolderBasename}``` instead of hard-coded Catesta name
- Updated .vscode settings to use `${workspaceFolderBasename}` instead of hard-coded Catesta name

## [0.9.0]

Expand Down
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
"Catesta",
"CICD",
"cmdlets",
"distros",
"dotnet",
"drawio",
"Evalz",
Expand Down
4 changes: 2 additions & 2 deletions actions_bootstrap.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ $null = $modulesToInstall.Add(([PSCustomObject]@{
# https://github.com/nightroman/Invoke-Build
$null = $modulesToInstall.Add(([PSCustomObject]@{
ModuleName = 'InvokeBuild'
ModuleVersion = '5.9.11'
ModuleVersion = '5.10.1'
}))
# https://github.com/PowerShell/PSScriptAnalyzer
$null = $modulesToInstall.Add(([PSCustomObject]@{
ModuleName = 'PSScriptAnalyzer'
ModuleVersion = '1.20.0'
ModuleVersion = '1.21.0'
}))
# https://github.com/PowerShell/platyPS
# older version used due to: https://github.com/PowerShell/platyPS/issues/457
Expand Down
2 changes: 1 addition & 1 deletion docs/Catesta.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Module Name: Catesta
Module Guid: 6796b193-9013-468a-b022-837749af2d06
Download Help Link: NA
Help Version: 1.2.3
Help Version: 1.2.6
Locale: en-US
---

Expand Down
2 changes: 1 addition & 1 deletion src/Catesta/Catesta.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
RootModule = 'Catesta.psm1'

# Version number of this module.
ModuleVersion = '1.2.3'
ModuleVersion = '1.2.6'

# Supported PSEditions
# CompatiblePSEditions = @()
Expand Down
10 changes: 5 additions & 5 deletions src/Catesta/Resources/AWS/Vault/plasterManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<metadata>
<name>AWSCBVaultExtension</name>
<id>58d9f168-a786-43e6-8b79-0766ded4fd22</id>
<version>1.2.3</version>
<version>1.2.6</version>
<title>Catesta - SecretManagement extension vault module template for AWS CodeBuild</title>
<description>Scaffolds a new PowerShell SecretManagement extension vault module project intended for CI/CD workflow using AWS CodeBuild</description>
<author>Jake Morrison</author>
Expand Down Expand Up @@ -68,9 +68,9 @@
<file source='' destination='src\Tests\Infrastructure'/>
<file source='' destination='src\Tests\Unit'/>
<file source='' destination='src\${PLASTER_PARAM_ModuleName}'/>
<templateFile source='..\..\editor\VSCode\tasks.json' destination='.vscode\tasks.json' />
<file source='..\..\editor\VSCode\extensions.json' destination='.vscode\extensions.json' />
<templateFile source='..\..\editor\VSCode\settings.json' destination='.vscode\settings.json' />
<templateFile source='..\..\Editor\VSCode\tasks.json' destination='.vscode\tasks.json' />
<file source='..\..\Editor\VSCode\extensions.json' destination='.vscode\extensions.json' />
<templateFile source='..\..\Editor\VSCode\settings.json' destination='.vscode\settings.json' />

<templateFile condition="$PLASTER_PARAM_Pester -eq '4'" source='..\..\Vault\src\Tests\v4\Unit\PSVault-Module.Tests.ps1' destination='src\Tests\Unit\${PLASTER_PARAM_ModuleName}-Module.Tests.ps1' />
<templateFile condition="$PLASTER_PARAM_Pester -eq '4'" source='..\..\Vault\src\Tests\v4\Unit\ExportedFunctions.Tests.ps1' destination='src\Tests\Unit\ExportedFunctions.Tests.ps1' />
Expand Down Expand Up @@ -116,7 +116,7 @@
<requireModule condition="$PLASTER_PARAM_Pester -eq '5'" name="Pester" minimumVersion="5.2.2" message="Without Pester, you will not be able to run the provided Pester test to validate your module manifest file."/>
<requireModule name="InvokeBuild" minimumVersion="5.8.0" message="Without InvokeBuild, you will not be able to run local builds."/>
<requireModule name="platyPS" requiredVersion ="0.12.0" message="This template requires platyPS v0.12.0 module to properly generate help."/>
<requireModule name="Microsoft.PowerShell.SecretManagement" minimumVersion ="1.2.3" message="Without the PowerShell SecretManagement you will not be able to properly test your extension."/>
<requireModule name="Microsoft.PowerShell.SecretManagement" minimumVersion ="1.1.2" message="Without the PowerShell SecretManagement you will not be able to properly test your extension."/>

<message>

Expand Down
4 changes: 2 additions & 2 deletions src/Catesta/Resources/AWS/install_modules.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,13 @@ $null = $modulesToInstall.Add(([PSCustomObject]@{
%>
$null = $modulesToInstall.Add(([PSCustomObject]@{
ModuleName = 'InvokeBuild'
ModuleVersion = '5.9.11'
ModuleVersion = '5.10.1'
BucketName = '<%=$PLASTER_PARAM_S3Bucket%>'
KeyPrefix = ''
}))
$null = $modulesToInstall.Add(([PSCustomObject]@{
ModuleName = 'PSScriptAnalyzer'
ModuleVersion = '1.20.0'
ModuleVersion = '1.21.0'
BucketName = '<%=$PLASTER_PARAM_S3Bucket%>'
KeyPrefix = ''
}))
Expand Down
8 changes: 4 additions & 4 deletions src/Catesta/Resources/AWS/plasterManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<metadata>
<name>AWSCBManifestPS</name>
<id>83670531-579c-4a4c-a70a-ddc60eaefa40</id>
<version>1.2.3</version>
<version>1.2.6</version>
<title>Catesta - PowerShell Module Template for AWS CodeBuild</title>
<description>Scaffolds a new PowerShell module project intended for CI/CD workflow using AWS CodeBuild</description>
<author>Jake Morrison</author>
Expand Down Expand Up @@ -77,9 +77,9 @@
<file source='' destination='src\${PLASTER_PARAM_ModuleName}'/>
<file source='' destination='src\${PLASTER_PARAM_ModuleName}\Public'/>
<file source='' destination='src\${PLASTER_PARAM_ModuleName}\Private'/>
<templateFile source='..\editor\VSCode\tasks.json' destination='.vscode\tasks.json' />
<file source='..\editor\VSCode\extensions.json' destination='.vscode\extensions.json' />
<templateFile source='..\editor\VSCode\settings.json' destination='.vscode\settings.json' />
<templateFile source='..\Editor\VSCode\tasks.json' destination='.vscode\tasks.json' />
<file source='..\Editor\VSCode\extensions.json' destination='.vscode\extensions.json' />
<templateFile source='..\Editor\VSCode\settings.json' destination='.vscode\settings.json' />

<templateFile condition="$PLASTER_PARAM_Pester -eq '4'" source='..\Module\src\Tests\v4\Unit\PSModule-Module.Tests.ps1' destination='src\Tests\Unit\${PLASTER_PARAM_ModuleName}-Module.Tests.ps1' />
<templateFile condition="$PLASTER_PARAM_Pester -eq '4'" source='..\Module\src\Tests\v4\Unit\ExportedFunctions.Tests.ps1' destination='src\Tests\Unit\ExportedFunctions.Tests.ps1' />
Expand Down
Loading

0 comments on commit fe9de27

Please sign in to comment.