Skip to content

Commit 9cd78e5

Browse files
committed
move logic into workflows
1 parent c6a92b3 commit 9cd78e5

File tree

3 files changed

+27
-22
lines changed

3 files changed

+27
-22
lines changed

.github/workflows/add-labels.yml

Lines changed: 0 additions & 22 deletions
This file was deleted.

.github/workflows/check-btcli-tests.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,21 @@ env:
1616
VERBOSE: ${{ github.event.inputs.verbose }}
1717

1818
jobs:
19+
20+
add-labels:
21+
runs-on: ubuntu-latest
22+
if: (github.event.pull_request.base.ref == 'staging' || github.event.pull_request.base.ref == 'main') && github.event_name == 'pull_request' && github.event.action == 'opened'
23+
steps:
24+
- name: Add labels to PR
25+
uses: actions-ecosystem/action-add-labels@v1
26+
with:
27+
github_token: ${{ secrets.GITHUB_TOKEN }}
28+
labels: |
29+
run-bittensor-sdk-tests
30+
run-bittensor-cli-tests
31+
1932
check-labels:
33+
needs: add-labels
2034
runs-on: ubuntu-latest
2135
if: ${{ github.event.pull_request.draft == false }}
2236
outputs:

.github/workflows/check-sdk-tests.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,20 @@ env:
1616
VERBOSE: ${{ github.event.inputs.verbose }}
1717

1818
jobs:
19+
add-labels:
20+
runs-on: ubuntu-latest
21+
if: (github.event.pull_request.base.ref == 'staging' || github.event.pull_request.base.ref == 'main') && github.event_name == 'pull_request' && github.event.action == 'opened'
22+
steps:
23+
- name: Add labels to PR
24+
uses: actions-ecosystem/action-add-labels@v1
25+
with:
26+
github_token: ${{ secrets.GITHUB_TOKEN }}
27+
labels: |
28+
run-bittensor-sdk-tests
29+
run-bittensor-cli-tests
30+
1931
check-labels:
32+
needs: add-labels
2033
runs-on: ubuntu-latest
2134
if: ${{ github.event.pull_request.draft == false }}
2235
outputs:

0 commit comments

Comments
 (0)