-
Notifications
You must be signed in to change notification settings - Fork 7
47 lines (39 loc) · 1.18 KB
/
Copy pathrelease.yml
File metadata and controls
47 lines (39 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
on:
push:
# Sequence of patterns matched against refs/tags
tags:
- '20*' # Push events to matching "20*", i.e. 2020-08-05, 2022-07-01, 2088-02-04
name: Release
jobs:
build:
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
## box.phar requires php82
php-version: '8.2'
tools: composer:v2
extensions: pcntl
- name: Set env
run: |
echo RELEASE_VERSION=${GITHUB_REF:10} >> $GITHUB_ENV
- name: Checkout code
uses: actions/checkout@v3
- name: Validate composer.json and composer.lock
run: composer validate
- name: Build PHAR
run: ./scripts/build.sh && mv dist/git-scan.phar dist/git-scan-${{ env.RELEASE_VERSION }}.phar
continue-on-error: false
- name: Create release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
draft: true
prerelease: false
body: |
Changes in this Release
- First Change
- Second Change
files: dist/git-scan-*.phar