From 24d304d31ce3439074deb36e424a95a6f34d0b91 Mon Sep 17 00:00:00 2001 From: Mahinkumar <73975593+Mahinkumar@users.noreply.github.com> Date: Tue, 29 Oct 2024 11:36:06 +0530 Subject: [PATCH] Setup Action build for docs to only run when changes are made in docs folder --- .github/workflows/deploy.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 3860a13..b56b7fa 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -1,10 +1,10 @@ name: Deploy VitePress site to Pages on: - # Runs on pushes targeting the `main` branch. Change this to `master` if you're - # using the `master` branch as the default branch. + #Runs only when push contains files in /docs folder push: - branches: [main] + paths: + - docs/** # Allows you to run this workflow manually from the Actions tab workflow_dispatch: @@ -24,6 +24,8 @@ concurrency: jobs: # Build job build: + # Runs only on root repository and not on forks + # Update or remove this if you want to host on your own if: github.repository == 'mahinkumar/Task_assistant' runs-on: ubuntu-latest steps: