From ea2363465039d5559bfd24f25a4b7b91a58abd30 Mon Sep 17 00:00:00 2001 From: Rafal Wiecek Date: Tue, 10 Oct 2023 15:31:15 +0200 Subject: [PATCH] Add CI workflow for PHP 8.2 with release and archive steps This commit adds a new GitHub Actions workflow file `ci.yml` that sets up continuous integration (CI) for PHP 8.2. The workflow includes steps to install dependencies using Composer, archive the project, and create a release using the softprops/action-gh-release action. --- .github/workflows/ci.yml | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..d9ec3eb --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,36 @@ +name: CI + +env: + php_version: "8.2" + blob_name: "simpay-wordpress-*.zip" + archive_format: "zip" + +on: + release: + types: [published] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + - name: Install dependencies + uses: php-actions/composer@v6 + with: + php_version: ${{ env.php_version }} + php_extensions: yaml + - name: Archive project + if: success() || failure() + uses: php-actions/composer@v6 + with: + php_version: ${{ env.php_version }} + php_extensions: yaml + command: archive + args: --format=${{ env.archive_format }} + - name: Release + uses: softprops/action-gh-release@v1 + if: success() || failure() + with: + files: ${{ env.blob_name }} + tag_name: ${{ inputs.version }}