Update php version in workflows #31
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://help.github.com/en/categories/automating-your-workflow-with-github-actions | |
name: "Compile PHAR without publishing" | |
on: | |
pull_request: | |
push: | |
branches: | |
- '**' # matches every branch | |
- '!master' # excludes master | |
jobs: | |
compile: | |
name: "Compile PHAR without publishing with ${{ matrix.php-version }}" | |
runs-on: "ubuntu-latest" | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- php-version: '8.0' | |
- php-version: '8.1' | |
- php-version: '8.2' | |
steps: | |
- name: "Checkout" | |
uses: "actions/checkout@v2" | |
with: | |
fetch-depth: 0 | |
- name: "Install PHP" | |
uses: "shivammathur/setup-php@v2" | |
with: | |
coverage: "none" | |
php-version: ${{ matrix.php-version }} | |
tools: composer:v2 | |
env: | |
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: "Cache dependencies" | |
uses: "actions/cache@v2" | |
with: | |
path: "~/.composer/cache" | |
key: "php-${{ matrix.php-version }}-composer-${{ hashFiles('**/composer.json') }}" | |
restore-keys: "php-${{ matrix.php-version }}-composer-" | |
- name: "Install dependencies" | |
run: "composer install --no-interaction --no-progress --no-suggest --no-dev" | |
- name: "Download box" | |
run: wget -O box.phar https://github.com/box-project/box/releases/download/${BOX_VERSION}/box.phar | |
env: | |
BOX_VERSION: 3.11.0 | |
- name: "Prepare config File" | |
run: cat box.json.dist | jq 'del(.key)' | jq 'del(.algorithm)' > box.json | |
- name: "Compile PHAR" | |
run: php box.phar compile | |
- name: "Run phar to see if it works" | |
run: php nanbando.phar | |
- name: "Try plugins install inside of the example directory" | |
run: cd example && php ../nanbando.phar plugins:install |