Skip to content

Commit

Permalink
Update github workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
gigili committed Sep 16, 2022
1 parent c097883 commit b3f878a
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 18 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,33 @@ on:
branches:
- main
env:
extensions: json
defaultPHPVersion: '8.0.3'
extensions: 'json,mbstring'
defaultPHPVersion: '8.1.10'

jobs:
generate_docs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@master
with:
php-version: ${{ env.defaultPHPVersion }}
extensions: ${{ env.extensions }}
ini-values: memory_limit=2G, display_errors=On, error_reporting=-1
tools: pecl

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ~/.composer/cache/files
key: dependencies-composer-${{ hashFiles('composer.lock') }}

- name: Install Composer dependencies
run: |
composer install --no-progress --prefer-dist --optimize-autoloader
run: composer install -q --no-ansi --no-interaction --no-progress --prefer-dist --optimize-autoloader

- name: Generate Documentation
run: |
git config --global user.email "${{ secrets.DOCS_GITHUB_EMAIL }}"
Expand All @@ -42,4 +50,4 @@ jobs:
git push origin main
else
echo "::debug::Nothing to commit and skipping push"
fi
fi
7 changes: 3 additions & 4 deletions .github/workflows/php-pest-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,17 @@ jobs:
- name: Setup PHP with Xdebug
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
php-version: '8.1'
coverage: xdebug

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ~/.composer/cache/files
key: dependencies-composer-${{ hashFiles('composer.json') }}
key: dependencies-composer-${{ hashFiles('composer.lock') }}

- name: Install Dependencies
run: composer install -q --no-ansi --no-interaction --no-progress --prefer-dist --optimize-autoloader

- name: Execute tests
run: vendor/bin/pest

run: vendor/bin/pest
27 changes: 18 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,25 @@
"autoload": {
"psr-4": {
"Gac\\Routing\\": "./src",
"Gac\\Routing\\Exceptions\\": "./src/Exceptions"
"Gac\\Routing\\Exceptions\\" : "./src/Exceptions"
}
},
"require-dev": {
"pestphp/pest": "^1.21"
"require-dev" : {
"pestphp/pest" : "^1.21"
},
"config": {
"sort-packages": true,
"allow-plugins": {
"pestphp/pest-plugin": true
"config" : {
"sort-packages" : true,
"allow-plugins" : {
"pestphp/pest-plugin" : true
},
"optimize-autoloader" : true,
"preferred-install" : "dist"
},
"extra" : {
"branch-alias" : {
"dev-master" : "dev"
}
}
}
},
"prefer-stable" : true,
"minimum-stability" : "dev"
}

0 comments on commit b3f878a

Please sign in to comment.