From 05cf9c8291566d7d66208ee5a7e1e6cce02853ab Mon Sep 17 00:00:00 2001 From: Piotr Semenov Date: Wed, 22 May 2024 15:49:11 +0400 Subject: [PATCH] fix(cicd): fail job if steps got failed --- .github/workflows/build-artifacts.yml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-artifacts.yml b/.github/workflows/build-artifacts.yml index ee807ca..dc11001 100644 --- a/.github/workflows/build-artifacts.yml +++ b/.github/workflows/build-artifacts.yml @@ -23,21 +23,29 @@ jobs: nix_path: nixpkgs=channel:nixos-unstable - name: Compile TextMate Grammar + id: compile-tmGrammar run: | - set +e chmod +x ./scripts/compile-grammar.sh ./scripts/compile-grammar.sh - exitcode="$?" - echo "exitcode=$exitcode" >> $GITHUB_OUTPUT - exit "$exitcode" + shell: bash + + - if: steps.compile-tmGrammar.outcome != 'success' + run: | + exit 1 shell: bash - name: Compile Coverage Badge SVG + id: compile-svg run: | sudo apt-get install -y xsltproc make -B $(pwd)/images/coverage-badge.svg shell: bash + - if: steps.compile-svg.outcome != 'success' + run: | + exit 1 + shell: bash + - name: Import GPG key id: import-gpg uses: crazy-max/ghaction-import-gpg@v6.1.0