From b50ccc96f4a18ba1efd2b536ade45393f46ca988 Mon Sep 17 00:00:00 2001 From: Violet Hansen Date: Sat, 21 Dec 2024 10:50:45 +0200 Subject: [PATCH] added filtering to the automatic actions run --- .github/workflows/CodeQL Advanced - Security.yml | 8 ++++++-- .github/workflows/powershell.yml | 13 +++++++++++-- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/.github/workflows/CodeQL Advanced - Security.yml b/.github/workflows/CodeQL Advanced - Security.yml index c655aa206..55655edeb 100644 --- a/.github/workflows/CodeQL Advanced - Security.yml +++ b/.github/workflows/CodeQL Advanced - Security.yml @@ -14,9 +14,13 @@ name: "CodeQL Advanced - Security" on: workflow_dispatch: push: - branches: [ "main" ] + branches: ["main"] + paths: + - "**.cs" pull_request: - branches: [ "main" ] + branches: ["main"] + paths: + - "**.cs" jobs: analyze: diff --git a/.github/workflows/powershell.yml b/.github/workflows/powershell.yml index 508bbcfa5..e263ebd58 100644 --- a/.github/workflows/powershell.yml +++ b/.github/workflows/powershell.yml @@ -11,9 +11,18 @@ name: PSScriptAnalyzer on: push: - branches: [ "main" ] + branches: ["main"] + paths: + - "**.ps1" + - "**.psm1" + - "**.psd1" + pull_request: - branches: [ "main" ] + branches: ["main"] + paths: + - "**.ps1" + - "**.psm1" + - "**.psd1" permissions: contents: read