Skip to content

Commit 55659dd

Browse files
committed
create GH release automatically
1 parent 6b128b7 commit 55659dd

File tree

1 file changed

+25
-2
lines changed

1 file changed

+25
-2
lines changed

.github/workflows/ci.yml

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
# https://help.github.com/en/categories/automating-your-workflow-with-github-actions
22

33
on:
4-
- pull_request
5-
- push
4+
pull_request:
5+
push:
6+
branches: *
7+
tags:
8+
- '[0-9]+.[0-9]+.[0-9]+*'
69

710
name: CI
811

@@ -116,6 +119,7 @@ jobs:
116119
key: php${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-${{ hashFiles('**/composer.json') }}
117120
restore-keys: |
118121
php${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-
122+
119123
- name: Install lowest dependencies with composer
120124
if: matrix.dependencies == 'lowest'
121125
run: composer update --no-ansi --no-interaction --no-progress --no-suggest --prefer-lowest
@@ -132,3 +136,22 @@ jobs:
132136
env:
133137
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
134138
run: bash <(curl -s https://codecov.io/bash) || true
139+
140+
release:
141+
if: startsWith( github.ref, 'refs/tags/')
142+
name: Create release
143+
144+
runs-on: ubuntu-latest
145+
needs: ["coding-guidelines", "type-checker", "tests"]
146+
147+
steps:
148+
- name: Create Release
149+
id: create_release
150+
uses: actions/create-release@v1
151+
env:
152+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
153+
with:
154+
tag_name: ${{ github.ref }}
155+
release_name: ${{ github.ref }}
156+
draft: false
157+
prerelease: false

0 commit comments

Comments
 (0)