Skip to content

Commit bdf8b29

Browse files
committed
Added Github actions integration
1 parent 792968b commit bdf8b29

File tree

4 files changed

+225
-345
lines changed

4 files changed

+225
-345
lines changed

.github/workflows/ci.yaml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,44 @@ jobs:
4343
- name: "Build documentation"
4444
run: make -C _build SPHINXOPTS="-nqW -j auto" html
4545

46+
build-php:
47+
name: Symfony doc builder
48+
49+
runs-on: ubuntu-latest
50+
51+
continue-on-error: true
52+
53+
steps:
54+
- name: "Checkout"
55+
uses: actions/checkout@v2
56+
57+
- name: "Set-up PHP"
58+
uses: shivammathur/setup-php@v2
59+
with:
60+
php-version: 7.2
61+
coverage: none
62+
tools: "composer:v2"
63+
64+
- name: Get composer cache directory
65+
id: composercache
66+
working-directory: _build
67+
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
68+
69+
- name: Cache dependencies
70+
uses: actions/cache@v2
71+
with:
72+
path: ${{ steps.composercache.outputs.dir }}
73+
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
74+
restore-keys: ${{ runner.os }}-composer-
75+
76+
- name: "Install dependencies"
77+
working-directory: _build
78+
run: composer install --prefer-dist --no-progress
79+
80+
- name: "Build the docs"
81+
working-directory: _build
82+
run: php build.php -vvv
83+
4684
doctor-rst:
4785
name: DOCtor-RST
4886

_build/build.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@
3333

3434
$process = new Process($command);
3535
$process->setTimeout(3600);
36-
$process->run();
36+
37+
$this->getHelper('process')->run($output, $process);
3738

3839
if (!$process->isSuccessful()) {
3940
throw new ProcessFailedException($process);

_build/composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"minimum-stability": "dev",
3+
"prefer-stable": true,
34
"repositories": [
45
{ "type": "git", "url": "https://github.com/weaverryan/docs-builder" }
56
],

0 commit comments

Comments
 (0)