Skip to content
This repository was archived by the owner on Apr 28, 2021. It is now read-only.

Commit 3f18556

Browse files
authored
GitHub Actions (#5)
* Init Github Actions * Fixed code style issues * Fixed custom build in Travis-CI
1 parent 2e9bfab commit 3f18556

File tree

10 files changed

+144
-541
lines changed

10 files changed

+144
-541
lines changed

.gitattributes

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,16 @@
1111
# @link https://github.com/JBZoo/Toolbox-CI
1212
#
1313

14+
/.github export-ignore
1415
/.phan export-ignore
1516
/build export-ignore
1617
/tests export-ignore
1718
/.editorconfig export-ignore
1819
/.gitattributes export-ignore
1920
/.gitignore export-ignore
2021
/.travis.yml export-ignore
22+
/box.json.dist export-ignore
23+
/composer.lock export-ignore
2124
/phpunit.xml.dist export-ignore
2225
/Makefile export-ignore
2326

.github/workflows/main.yml

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
#
2+
# JBZoo Toolbox - Toolbox-CI
3+
#
4+
# This file is part of the JBZoo Toolbox project.
5+
# For the full copyright and license information, please view the LICENSE
6+
# file that was distributed with this source code.
7+
#
8+
# @package Toolbox-CI
9+
# @license MIT
10+
# @copyright Copyright (C) JBZoo.com, All rights reserved.
11+
# @link https://github.com/JBZoo/Toolbox-CI
12+
#
13+
14+
name: Continuous Integration
15+
16+
on:
17+
pull_request:
18+
branches:
19+
- "*"
20+
push:
21+
branches:
22+
- 'master'
23+
schedule:
24+
- cron: '15 */8 * * *'
25+
26+
env:
27+
COLUMNS: 120
28+
TERM_PROGRAM: Hyper
29+
30+
jobs:
31+
phpunit:
32+
name: Tests
33+
runs-on: ubuntu-latest
34+
strategy:
35+
matrix:
36+
php-version: [ 7.2, 7.3, 7.4 ]
37+
experimental: [ false ]
38+
include:
39+
- php-version: "8.0"
40+
experimental: true
41+
- php-version: "8.1"
42+
experimental: true
43+
steps:
44+
- name: Checkout code
45+
uses: actions/checkout@v2
46+
with:
47+
fetch-depth: 0
48+
49+
- name: Setup PHP and composer
50+
uses: shivammathur/setup-php@v2
51+
with:
52+
php-version: ${{ matrix.php-version }}
53+
coverage: xdebug
54+
tools: composer
55+
56+
- name: Build the Project
57+
continue-on-error: ${{ matrix.experimental }}
58+
run: make build --no-print-directory
59+
60+
- name: 🧪 PHPUnit Tests
61+
continue-on-error: ${{ matrix.experimental }}
62+
run: make test --no-print-directory
63+
64+
- name: 👍 Code Quality
65+
continue-on-error: ${{ matrix.experimental }}
66+
run: make codestyle --no-print-directory
67+
68+
- name: 📝 Build All Reports at Once
69+
continue-on-error: ${{ matrix.experimental }}
70+
run: make report-all --no-print-directory

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ language: php
1515
os: linux
1616
dist: xenial
1717

18+
git:
19+
depth: false
20+
1821
php:
1922
- 7.2
2023
- 7.3

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name" : "jbzoo/toolbox-ci",
3-
"type" : "library",
3+
"type" : "project",
44
"description" : "Toolbox for continuous integration system",
55
"license" : "MIT",
66

0 commit comments

Comments
 (0)