From 1a707d111b1dee43418a672faf6b10ab5010162a Mon Sep 17 00:00:00 2001 From: Aditya Goel <48102515+adityagoel4512@users.noreply.github.com> Date: Fri, 3 Jan 2025 18:45:28 +0000 Subject: [PATCH] Run CI for forks (#91) --- .github/workflows/array-api.yml | 12 ++++++++++-- .github/workflows/ci.yml | 13 +++++++++++-- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/.github/workflows/array-api.yml b/.github/workflows/array-api.yml index 8354195..f59f8e2 100644 --- a/.github/workflows/array-api.yml +++ b/.github/workflows/array-api.yml @@ -1,7 +1,16 @@ name: Array API coverage tests on: - push: # Run on all branches + # We would like to trigger for CI for any pull request action - + # both from QuantCo's branches as well as forks. + pull_request: + # In addition to pull requests, we want to run CI for pushes + # to the main branch and tags. + push: + branches: + - "main" + tags: + - "*" schedule: - cron: "0 8 * * 0" # Runs weekly at 08:00 UTC on Sunday @@ -20,7 +29,6 @@ jobs: - name: Checkout branch uses: actions/checkout@v4 with: - ref: ${{ github.head_ref }} fetch-depth: 0 submodules: recursive - name: Set up pixi diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 883b492..a9f49ef 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,5 +1,15 @@ name: CI -on: [push] +on: + # We would like to trigger for CI for any pull request action - + # both from QuantCo's branches as well as forks. + pull_request: + # In addition to pull requests, we want to run CI for pushes + # to the main branch and tags. + push: + branches: + - "main" + tags: + - "*" concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -40,7 +50,6 @@ jobs: - name: Checkout branch uses: actions/checkout@v4 with: - ref: ${{ github.head_ref }} fetch-depth: 0 - name: Set up pixi uses: prefix-dev/setup-pixi@ba3bb36eb2066252b2363392b7739741bb777659