Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update deps #6

Merged
merged 2 commits into from
Apr 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,14 @@
#

/.github export-ignore
/.phan export-ignore
/build export-ignore
/tests export-ignore
/.editorconfig export-ignore
/.gitattributes export-ignore
/.gitignore export-ignore
/.travis.yml export-ignore
/.phan.php export-ignore
/demo.php export-ignore
/phpunit.xml.dist export-ignore
/Makefile export-ignore

* text eol=lf
86 changes: 70 additions & 16 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# @link https://github.com/JBZoo/SimpleTypes
#

name: Continuous Integration
name: CI

on:
pull_request:
Expand All @@ -21,53 +21,107 @@ on:
branches:
- 'master'
schedule:
- cron: '15 */8 * * *'
- cron: '25 */8 * * *'

env:
COLUMNS: 120
TERM_PROGRAM: Hyper

jobs:
phpunit:
name: Tests
name: PHPUnit
runs-on: ubuntu-latest
env:
JBZOO_COMPOSER_UPDATE_FLAGS: ${{ matrix.composer_flags }}
strategy:
matrix:
php-version: [ 7.2, 7.3, 7.4 ]
experimental: [ false ]
php-version: [ 7.2, 7.3, 7.4, 8.0 ]
composer_flags: [ "--prefer-lowest", "" ]
include:
- php-version: "8.0"
experimental: true
- php-version: "8.1"
experimental: true
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup PHP and composer
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
coverage: xdebug
tools: composer

- name: Build the Project
continue-on-error: ${{ matrix.experimental }}
run: make update --no-print-directory

- name: 🧪 PHPUnit Tests
continue-on-error: ${{ matrix.experimental }}
run: make test --no-print-directory

- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: PHPUnit - ${{ matrix.php-version }} - ${{ matrix.coverage }}
path: build/


linters:
name: Linters
runs-on: ubuntu-latest
strategy:
matrix:
php-version: [ 7.2, 7.3, 7.4, 8.0 ]
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
extensions: ast
tools: composer

- name: Build the Project
run: make update --no-print-directory

- name: 👍 Code Quality
continue-on-error: ${{ matrix.experimental }}
run: make codestyle --no-print-directory

- name: 📝 Build All Reports at Once
continue-on-error: ${{ matrix.experimental }}
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: Linters - ${{ matrix.php-version }}
path: build/


report:
name: Reports
runs-on: ubuntu-latest
strategy:
matrix:
php-version: [ 7.2, 7.3, 7.4, 8.0 ]
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
coverage: xdebug
tools: composer

- name: Build the Project
run: make update --no-print-directory

- name: 📝 Build Reports
run: make report-all --no-print-directory

- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: Reports - ${{ matrix.php-version }}
path: build/
2 changes: 1 addition & 1 deletion .phan/config.php → .phan.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

declare(strict_types=1);

$default = include __DIR__ . '/../vendor/jbzoo/codestyle/src/phan/default.php';
$default = include __DIR__ . '/vendor/jbzoo/codestyle/src/phan/default.php';

return array_merge($default, [
'directory_list' => [
Expand Down
10 changes: 3 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,14 @@ language: php
os: linux
dist: xenial

git:
depth: false

php:
- 7.2
- 7.3
- 7.4
- 8.0
- nightly

jobs:
fast_finish: true
allow_failures:
- php: 8.0
- php: nightly

env:
matrix:
Expand Down
27 changes: 13 additions & 14 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,45 +1,44 @@
{
"name" : "jbzoo/simpletypes",
"type" : "library",
"description" : "The universal PHP library to convert any values and measures",
"license" : "MIT",
"keywords" : [
"name" : "jbzoo/simpletypes",
"type" : "library",
"description" : "The universal PHP library to convert any values and measures",
"license" : "MIT",
"keywords" : [
"converter", "acceleration", "area", "degree", "info", "length", "money", "number", "pressure", "speed",
"temperature", "time", "volume", "weight"
],
"authors" : [
"authors" : [
{
"name" : "Denis Smetannikov",
"email" : "admin@jbzoo.com",
"role" : "lead"
}
],

"require" : {
"require" : {
"php" : ">=7.2"
},

"require-dev" : {
"jbzoo/toolbox-dev" : "^2.11.0",
"jbzoo/utils" : "^4.4.0"
"require-dev" : {
"jbzoo/toolbox-dev" : "^2.13.1"
},

"autoload" : {
"autoload" : {
"psr-4" : {
"JBZoo\\SimpleTypes\\" : "src"
}
},

"autoload-dev" : {
"autoload-dev" : {
"classmap" : ["tests"],
"files" : ["tests/phpunit-functions.php"]
},

"config" : {
"config" : {
"optimize-autoloader" : true
},

"extra" : {
"extra" : {
"branch-alias" : {
"dev-master" : "2.x-dev"
}
Expand Down