-
-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
GitHub workflows
- Loading branch information
Showing
7 changed files
with
268 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# This workflow uses actions that are not certified by GitHub. | ||
# They are provided by a third-party and are governed by | ||
# separate terms of service, privacy policy, and support | ||
# documentation. | ||
# | ||
# https://github.com/microsoft/action-psscriptanalyzer | ||
# For more information on PSScriptAnalyzer in general, see | ||
# https://github.com/PowerShell/PSScriptAnalyzer | ||
|
||
name: PSScriptAnalyzer | ||
|
||
on: | ||
push: | ||
branches: [ "develop" ] | ||
pull_request: | ||
branches: [ "develop" ] | ||
schedule: | ||
- cron: '20 16 * * 6' | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
build: | ||
permissions: | ||
contents: read # for actions/checkout to fetch code | ||
security-events: write # for github/codeql-action/upload-sarif to upload SARIF results | ||
actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status | ||
name: PSScriptAnalyzer | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Run PSScriptAnalyzer | ||
uses: microsoft/psscriptanalyzer-action@6b2948b1944407914a58661c49941824d149734f | ||
with: | ||
# Check https://github.com/microsoft/action-psscriptanalyzer for more info about the options. | ||
# The below set up runs PSScriptAnalyzer to your entire repository and runs some basic security rules. | ||
path: .\ | ||
recurse: true | ||
# Include your own basic security rules. Removing this option will run all the rules | ||
includeRule: '"PSAvoidGlobalAliases", "PSAvoidUsingConvertToSecureStringWithPlainText"' | ||
output: results.sarif | ||
|
||
# Upload the SARIF file generated in the previous step | ||
- name: Upload SARIF results file | ||
uses: github/codeql-action/upload-sarif@v3 | ||
with: | ||
sarif_file: results.sarif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Pode CI - Powershell Desktop | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
- '!gh-pages' | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: windows-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Check PowerShell version | ||
shell: powershell | ||
run: | | ||
$PSVersionTable.PSVersion | ||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: 8.0.x | ||
|
||
- name: Install Invoke-Build | ||
shell: powershell | ||
run: | | ||
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 | ||
Install-Module -Name InvokeBuild -RequiredVersion '5.10.5' -Force | ||
- name: Run Pester Tests | ||
shell: powershell | ||
run: | | ||
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 | ||
Invoke-Build Test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Pode CI - pwsh 7.3 on windows-latest | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
- '!gh-pages' | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: windows-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: 8.0.x | ||
|
||
- name: Install Invoke-Build | ||
shell: pwsh | ||
run: | | ||
Install-Module -Name InvokeBuild -RequiredVersion '5.10.5' -Force | ||
# For Windows | ||
- name: Download and extract PowerShell 7.3 | ||
run: | | ||
Invoke-WebRequest -Uri "https://github.com/PowerShell/PowerShell/releases/download/v7.3.11/PowerShell-7.3.11-win-x64.zip" -OutFile "PowerShell-7.3.x-win-x64.zip" | ||
Expand-Archive -LiteralPath "PowerShell-7.3.x-win-x64.zip" -DestinationPath "C:\PowerShell-7.3" | ||
- name: Check PowerShell version | ||
run: | | ||
C:\PowerShell-7.3\pwsh.exe -version | ||
- name: Run Pester Tests | ||
run: | | ||
C:\PowerShell-7.3\pwsh.exe -Command { | ||
Invoke-Build Test | ||
} | ||
- name: Test docker builds | ||
run: | | ||
C:\PowerShell-7.3\pwsh.exe -Command { | ||
Invoke-Build DockerPack -Version '0.0.0' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Pode CI - pwsh 7.4 on windows-latest | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
- '!gh-pages' | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: windows-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: 8.0.x | ||
|
||
- name: Install Invoke-Build | ||
shell: pwsh | ||
run: | | ||
Install-Module -Name InvokeBuild -RequiredVersion '5.10.5' -Force | ||
# For Windows | ||
- name: Download and extract PowerShell 7.4 | ||
run: | | ||
Invoke-WebRequest -Uri "https://github.com/PowerShell/PowerShell/releases/download/v7.4.1/PowerShell-7.4.1-win-x64.zip" -OutFile "PowerShell-7.4.x-win-x64.zip" | ||
Expand-Archive -LiteralPath "PowerShell-7.4.x-win-x64.zip" -DestinationPath "C:\PowerShell-7.4" | ||
- name: Check PowerShell version | ||
run: | | ||
C:\PowerShell-7.4\pwsh.exe -version | ||
- name: Run Pester Tests | ||
run: | | ||
C:\PowerShell-7.4\pwsh.exe -Command { | ||
Invoke-Build Test | ||
} | ||
- name: Test docker builds | ||
run: | | ||
C:\PowerShell-7.4\pwsh.exe -Command { | ||
Invoke-Build DockerPack -Version '0.0.0' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Pode CI - pwsh 7.5 on windows-latest | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
- '!gh-pages' | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: windows-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: 8.0.x | ||
|
||
- name: Install Invoke-Build | ||
shell: pwsh | ||
run: | | ||
Install-Module -Name InvokeBuild -RequiredVersion '5.10.5' -Force | ||
# For Windows | ||
- name: Download and extract PowerShell 7.5 | ||
run: | | ||
Invoke-WebRequest -Uri "https://github.com/PowerShell/PowerShell/releases/download/v7.5.0-preview.2/PowerShell-7.5.0-preview.2-win-x64.zip" -OutFile "PowerShell-7.5.x-win-x64.zip" | ||
Expand-Archive -LiteralPath "PowerShell-7.5.x-win-x64.zip" -DestinationPath "C:\PowerShell-7.5" | ||
- name: Check PowerShell version | ||
run: | | ||
C:\PowerShell-7.5\pwsh.exe -version | ||
- name: Run Pester Tests | ||
run: | | ||
C:\PowerShell-7.5\pwsh.exe -Command { | ||
Invoke-Build Test | ||
} | ||
- name: Test docker builds | ||
run: | | ||
C:\PowerShell-7.5\pwsh.exe -Command { | ||
Invoke-Build DockerPack -Version '0.0.0' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters