Skip to content

Commit

Permalink
Addedf build step.
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexSkrypnyk committed Feb 27, 2024
1 parent 3294b75 commit 61dac9b
Showing 1 changed file with 33 additions and 2 deletions.
35 changes: 33 additions & 2 deletions .github/workflows/test-php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,38 @@ jobs:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}

build-php:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Cache Composer dependencies
uses: actions/cache@v4
with:
path: /tmp/composer-cache
key: ${{ runner.os }}-${{ hashFiles('**/composer.lock') }}

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.1

- name: Install dependencies
run: composer install

- name: Build PHAR
run: composer build

- name: Test PHAR
run: ./.build/php-command.phar || exit 1
#;> PHP_PHAR

# Demonstration of deployment in 'force-push' mode.
deploy-force-push:
needs: test-php
needs:
- test-php
- build-php

runs-on: ubuntu-latest

Expand Down Expand Up @@ -164,7 +193,9 @@ jobs:
# of the second push. This is because the mode is intended to create a new
# branch per artifact deployment.
deploy-branch:
needs: test-php
needs:
- test-php
- build-php

runs-on: ubuntu-latest

Expand Down

0 comments on commit 61dac9b

Please sign in to comment.