From 8aa22963e39892851a17354d38afe96fa71c3d75 Mon Sep 17 00:00:00 2001 From: Carly Gundy Date: Wed, 22 Nov 2023 09:04:23 +0100 Subject: [PATCH 1/3] test --- .github/workflows/check_issue_signed.yml | 35 ++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/check_issue_signed.yml diff --git a/.github/workflows/check_issue_signed.yml b/.github/workflows/check_issue_signed.yml new file mode 100644 index 0000000..be66154 --- /dev/null +++ b/.github/workflows/check_issue_signed.yml @@ -0,0 +1,35 @@ +# Workflow to check if a user has correctly signed the CLA + +name: Check Issue Signed + +on: + issue_comment: + pull_request: + +jobs: + check-signed: + name: Check CLA signed + runs-on: ubuntu-latest + # if: ${{ github.event.pull_request.head.repo.full_name }} == "cla" + steps: + - name: debug + run: echo ${{ github.event.pull_request.head.repo.full_name }} + # - name: Checkout + # uses: actions/checkout@v3 + # with: + # repository: dfinity/public-workflows + # - name: Install Python + # uses: actions/setup-python@v4 + # with: + # python-version: '3.10' + # - name: Install Dependencies + # run: pip install -q -r requirements.txt + # shell: bash + # - name: Check CLA issue + # run: | + # export PYTHONPATH="$PWD/reusable_workflows/" + # python reusable_workflows/check_cla/check_cla_issue.py + # shell: bash + # env: + # GH_TOKEN: ${{ github.token }} + # ISSUE_ID: ${{ github.event.issue.number }} \ No newline at end of file From 5e639f700d994fa205699e9485b55c1772a3b9d7 Mon Sep 17 00:00:00 2001 From: Carly Gundy Date: Wed, 22 Nov 2023 09:06:47 +0100 Subject: [PATCH 2/3] add code --- .github/workflows/check_issue_signed.yml | 43 +++++++++++------------- 1 file changed, 20 insertions(+), 23 deletions(-) diff --git a/.github/workflows/check_issue_signed.yml b/.github/workflows/check_issue_signed.yml index be66154..23400d7 100644 --- a/.github/workflows/check_issue_signed.yml +++ b/.github/workflows/check_issue_signed.yml @@ -4,32 +4,29 @@ name: Check Issue Signed on: issue_comment: - pull_request: jobs: check-signed: name: Check CLA signed runs-on: ubuntu-latest - # if: ${{ github.event.pull_request.head.repo.full_name }} == "cla" + if: ${{ github.event.pull_request.head.repo.full_name }} == "dfinity/cla" steps: - - name: debug - run: echo ${{ github.event.pull_request.head.repo.full_name }} - # - name: Checkout - # uses: actions/checkout@v3 - # with: - # repository: dfinity/public-workflows - # - name: Install Python - # uses: actions/setup-python@v4 - # with: - # python-version: '3.10' - # - name: Install Dependencies - # run: pip install -q -r requirements.txt - # shell: bash - # - name: Check CLA issue - # run: | - # export PYTHONPATH="$PWD/reusable_workflows/" - # python reusable_workflows/check_cla/check_cla_issue.py - # shell: bash - # env: - # GH_TOKEN: ${{ github.token }} - # ISSUE_ID: ${{ github.event.issue.number }} \ No newline at end of file + - name: Checkout + uses: actions/checkout@v3 + with: + repository: dfinity/public-workflows + - name: Install Python + uses: actions/setup-python@v4 + with: + python-version: '3.10' + - name: Install Dependencies + run: pip install -q -r requirements.txt + shell: bash + - name: Check CLA issue + run: | + export PYTHONPATH="$PWD/reusable_workflows/" + python reusable_workflows/check_cla/check_cla_issue.py + shell: bash + env: + GH_TOKEN: ${{ github.token }} + ISSUE_ID: ${{ github.event.issue.number }} From efaf8c0bbf8fbbccefefdb7db3a049580abcd07c Mon Sep 17 00:00:00 2001 From: Carly Gundy <47304080+cgundy@users.noreply.github.com> Date: Wed, 22 Nov 2023 09:31:08 +0100 Subject: [PATCH 3/3] Revert "move CLA check signed to public-workflows" --- .github/workflows/check_issue_signed.yml | 32 ------------------------ 1 file changed, 32 deletions(-) delete mode 100644 .github/workflows/check_issue_signed.yml diff --git a/.github/workflows/check_issue_signed.yml b/.github/workflows/check_issue_signed.yml deleted file mode 100644 index 23400d7..0000000 --- a/.github/workflows/check_issue_signed.yml +++ /dev/null @@ -1,32 +0,0 @@ -# Workflow to check if a user has correctly signed the CLA - -name: Check Issue Signed - -on: - issue_comment: - -jobs: - check-signed: - name: Check CLA signed - runs-on: ubuntu-latest - if: ${{ github.event.pull_request.head.repo.full_name }} == "dfinity/cla" - steps: - - name: Checkout - uses: actions/checkout@v3 - with: - repository: dfinity/public-workflows - - name: Install Python - uses: actions/setup-python@v4 - with: - python-version: '3.10' - - name: Install Dependencies - run: pip install -q -r requirements.txt - shell: bash - - name: Check CLA issue - run: | - export PYTHONPATH="$PWD/reusable_workflows/" - python reusable_workflows/check_cla/check_cla_issue.py - shell: bash - env: - GH_TOKEN: ${{ github.token }} - ISSUE_ID: ${{ github.event.issue.number }}