Skip to content

Commit 90aec5e

Browse files
Refactor GitHub Actions: Consolidate Install-PSModuleHelpers into Install-PSModule
- Added PSScriptAnalyzer configuration file for code analysis rules. - Created main script for Install-PSModule action to manage module installation. - Removed Install-PSModuleHelpers action and associated files. - Updated workflows to replace Install-PSModuleHelpers with Install-PSModule.
1 parent b615f64 commit 90aec5e

21 files changed

Lines changed: 54 additions & 225 deletions

File tree

.github/actions/Build-PSModule/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ inputs:
2828
runs:
2929
using: composite
3030
steps:
31-
- name: Install-PSModuleHelpers
32-
uses: ./_wf/.github/actions/Install-PSModuleHelpers
31+
- name: Install-PSModule
32+
uses: ./_wf/.github/actions/Install-PSModule
3333

3434
- name: Run Build-PSModule
3535
shell: pwsh

.github/actions/Document-PSModule/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ inputs:
1818
runs:
1919
using: composite
2020
steps:
21-
- name: Install-PSModuleHelpers
22-
uses: ./_wf/.github/actions/Install-PSModuleHelpers
21+
- name: Install-PSModule
22+
uses: ./_wf/.github/actions/Install-PSModule
2323

2424
- name: Document-PSModule
2525
shell: pwsh

.github/actions/Initialize-PSModule/README.md

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

.github/actions/Initialize-PSModule/action.yml

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

.github/actions/Initialize-PSModule/src/main.ps1

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

.github/actions/Install-PSModuleHelpers/README.md renamed to .github/actions/Install-PSModule/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Install-PSModuleHelpers
1+
# Install-PSModule
22

33
A GitHub Action to install and configure the PSModule helper modules for use in continuous integration and delivery (CI/CD) workflows. This action is
44
a critical component for setting up a standardized PowerShell environment across repositories using the PSModule framework.
@@ -18,7 +18,7 @@ This action helps maintain consistency and reliability across workflows that dep
1818

1919
```yaml
2020
- name: Install PSModule Helpers
21-
uses: PSModule/Install-PSModuleHelpers@v1
21+
uses: PSModule/Install-PSModule@v1
2222
```
2323
2424
## Inputs
@@ -35,7 +35,7 @@ This action does not provide any outputs.
3535
3636
## Example
3737
38-
Here's a complete workflow example demonstrating how to use the Install-PSModuleHelpers action:
38+
Here's a complete workflow example demonstrating how to use the Install-PSModule action:
3939
4040
```yaml
4141
name: CI
@@ -53,7 +53,7 @@ jobs:
5353
- uses: actions/checkout@v4
5454

5555
- name: Install PSModule Helpers
56-
uses: PSModule/Install-PSModuleHelpers@v1
56+
uses: PSModule/Install-PSModule@v1
5757

5858
- name: Run additional steps
5959
shell: pwsh
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
name: Install-PSModule
2+
description: Installs PSModule.
3+
4+
runs:
5+
using: composite
6+
steps:
7+
- name: Install-PSModule
8+
shell: pwsh
9+
run: |
10+
# Install-PSModule
11+
${{ github.action_path }}/src/main.ps1
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
@{
2+
RootModule = 'PSModule.psm1'
3+
ModuleVersion = '999.0.0'
4+
}

.github/actions/Install-PSModuleHelpers/src/Helpers/Helpers.psm1 renamed to .github/actions/Install-PSModule/src/PSModule/PSModule.psm1

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1348,4 +1348,3 @@ function Import-TestData {
13481348
Add-EnvFromMap -Map $data.secrets -Name 'secrets' -Mask
13491349
Add-EnvFromMap -Map $data.variables -Name 'variables'
13501350
}
1351-

.github/actions/Install-PSModuleHelpers/src/Helpers/PSScriptAnalyzer.Tests.psd1 renamed to .github/actions/Install-PSModule/src/PSModule/PSScriptAnalyzer.Tests.psd1

File renamed without changes.

0 commit comments

Comments
 (0)