Skip to content

Commit 01bc982

Browse files
Panquesito7tjgurwara99github-actions[bot]
authored
feat: label when the build fails (#1254)
* feat: label when the build fails * updating DIRECTORY.md --------- Co-authored-by: Taj <[email protected]> Co-authored-by: github-actions[bot] <[email protected]>
1 parent 05ff277 commit 01bc982

File tree

2 files changed

+17
-2
lines changed

2 files changed

+17
-2
lines changed

.github/workflows/awesome_workflow.yml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ jobs:
9292
build:
9393
name: Compile checks
9494
runs-on: ${{ matrix.os }}
95+
permissions:
96+
pull-requests: write
9597
needs: [MainSequence]
9698
strategy:
9799
matrix:
@@ -100,5 +102,17 @@ jobs:
100102
- uses: actions/checkout@v3
101103
with:
102104
submodules: true
103-
- run: cmake -B ./build -S .
104-
- run: cmake --build build
105+
- run: |
106+
cmake -B ./build -S .
107+
cmake --build build
108+
- name: Label on PR fail
109+
uses: actions/github-script@v6
110+
if: ${{ failure() && matrix.os == 'ubuntu-latest' && github.event_name == 'pull_request' }}
111+
with:
112+
script: |
113+
github.rest.issues.addLabels({
114+
issue_number: context.issue.number,
115+
owner: context.repo.owner,
116+
repo: context.repo.repo,
117+
labels: ['Autochecks are failing']
118+
})

DIRECTORY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,7 @@
238238
* [Qr Decomposition](https://github.com/TheAlgorithms/C/blob/HEAD/numerical_methods/qr_decomposition.c)
239239
* [Qr Eigen Values](https://github.com/TheAlgorithms/C/blob/HEAD/numerical_methods/qr_eigen_values.c)
240240
* [Realtime Stats](https://github.com/TheAlgorithms/C/blob/HEAD/numerical_methods/realtime_stats.c)
241+
* [Secant Method](https://github.com/TheAlgorithms/C/blob/HEAD/numerical_methods/secant_method.c)
241242
* [Simpsons 1 3Rd Rule](https://github.com/TheAlgorithms/C/blob/HEAD/numerical_methods/simpsons_1_3rd_rule.c)
242243
* [Variance](https://github.com/TheAlgorithms/C/blob/HEAD/numerical_methods/variance.c)
243244

0 commit comments

Comments
 (0)