From fd7dffa57a1260a68a83acc801b1eb4bc9a09a38 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Astor?= Date: Thu, 20 Feb 2020 22:35:58 +0100 Subject: [PATCH] :wrench: Delete obsolete branch --- .github/workflows/delete.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 .github/workflows/delete.yml diff --git a/.github/workflows/delete.yml b/.github/workflows/delete.yml new file mode 100644 index 00000000..7bbf25a0 --- /dev/null +++ b/.github/workflows/delete.yml @@ -0,0 +1,20 @@ +name: Coverage Report + +on: [ delete ] + +jobs: + name: Delete obsolete branch + build: + runs-on: ubuntu-latest + if: "startsWith(github.event.ref, 'refs/heads/')" + + - name: Clone report repo + run: | + git clone https://github.com/fennecdjay/gwion-coverage-report + cd gwion-coverage-report + branch=$(basename ${{ github.event.ref }}) + rm -r html/$branch + git config --local user.email "action@github.com" + git config --local user.name "GitHub Action" + git remote set-url origin https://${{ secrets.COVERAGE_TOKEN }}@github.com/fennecdjay/gwion-coverage-report.git + git add html && git commit -m "Delete obsolete branch" && git subtree push --prefix html origin gh-pages || true -- 2.43.0