Skip to content

feat(kql): canonical value normalisation for detection rules (2.5.1) #53

feat(kql): canonical value normalisation for detection rules (2.5.1)

feat(kql): canonical value normalisation for detection rules (2.5.1) #53

name: 'Publish PowerShell Module to GitHub Packages'
on:
push:
branches:
- main
paths:
- '**/*.psd1'
workflow_dispatch:
inputs:
working_directory:
type: string
description: What working directory should be passed to the script
default: "github_workspace"
jobs:
test:
name: 'Lint and Test'
runs-on: ubuntu-latest
defaults:
run:
shell: pwsh
steps:
- uses: actions/checkout@v4
- name: Run analyzer and tests
run: ./Invoke-Tests.ps1
run-script:
name: 'Run Script'
needs: test
runs-on: ubuntu-latest
defaults:
run:
shell: pwsh
steps:
- uses: actions/checkout@v3
- name: Build
id: run-script
shell: pwsh
run: |
if ("${{ inputs.working_directory }}" -eq "github_workspace")
{
$workingDirectory = "${{ github.workspace }}"
}
else
{
$workingDirectory = "${{ inputs.working_directory }}"
}
.\Publish-ToGitHubPackages.ps1 `
-WorkingDirectory $workingDirectory
env:
GITHUB_TOKEN: ${{ secrets.github_token }}
GITHUB_REPOSITORY_OWNER: ${{ github.GITHUB_REPOSITORY_OWNER }}