Skip to content

chore: bump version in composer.json #4

chore: bump version in composer.json

chore: bump version in composer.json #4

Workflow file for this run

name: "Release"
permissions:
contents: write
on:
push:
tags:
- "v*"
jobs:
tag:
runs-on: ubuntu-24.04
outputs:
version: ${{ steps.tag.outputs.tag }}
prerelease: ${{ (!!steps.prerelease.outputs.is_prerelease) || false }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Get Tag
if: startsWith(github.ref, 'refs/tags/v')
uses: olegtarasov/[email protected]
id: tag
with:
tagRegex: "v(.*)"
- name: Get Prerelease
if: contains(github.ref, '-rc') || contains(github.ref, '-pre') || contains(github.ref, '-alpha') || contains(github.ref, '-beta')
run: echo "is_prerelease=true" >> $GITHUB_OUTPUT
id: prerelease
build:
runs-on: ubuntu-24.04
needs: ['tag']
strategy:
matrix:
php: ['8.1', '8.1-zts', '8.2', '8.2-zts', '8.3', '8.3-zts']
os: ['ubuntu-22.04', 'ubuntu-24.04']
driver: ['scylladb', 'cassandra']
fail-fast: true
container: malusevd99/scylladb-php-driver:${{ matrix.os }}-php-${{ matrix.php }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: recursive
- name: Build Driver
shell: bash
run: |
./build.sh ${{ matrix.driver }} ${{ needs.tag.outputs.version }}
tar czf ${{ matrix.os }}-php-${{ matrix.php }}-${{ matrix.driver }}.tar.gz cassandra.so cassandra.ini
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}-php-${{ matrix.php }}-${{ matrix.driver }}.tar.gz
path: ${{ matrix.os }}-php-${{ matrix.php }}-${{ matrix.driver }}.tar.gz
if-no-files-found: error
retention-days: 5
overwrite: true
release:
runs-on: ubuntu-24.04
needs: ["build", 'tag']
steps:
- uses: actions/download-artifact@v4
id: artifacts
with:
merge-multiple: true
- name: Release
uses: softprops/action-gh-release@v2
id: release
with:
make_latest: ${{ !needs.tag.outputs.prerelease }}
name: "v${{ needs.tag.outputs.version }}"
tag_name: "v${{ needs.tag.outputs.version }}"
generate_release_notes: true
append_body: true
prerelease: ${{ needs.tag.outputs.prerelease }}
files: |
${{ steps.artifacts.outputs.download-path }}/*.tar.gz
fail_on_unmatched_files: true
- name: "Generate release changelog"
uses: heinrichreimer/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
author: true
releaseUrl: ${{ steps.release.outputs.url }}
issues: true
pullRequests: true
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "Update CHANGELOG.md"
branch: v1.3.x
commit_options: "--no-verify --signoff"
file_pattern: CHANGELOG.md