File tree Expand file tree Collapse file tree 3 files changed +53
-2
lines changed Expand file tree Collapse file tree 3 files changed +53
-2
lines changed Original file line number Diff line number Diff line change @@ -14,13 +14,17 @@ matrix:
14
14
- php : 5.6
15
15
- php : hhvm
16
16
17
+ env :
18
+ global :
19
+ - secure : " Sq+6bVtnPsu0mWX8DWQ+9bGAjxMcGorksUiHc4YIXEJsuDfVmVlH8tTD547IeCjDAx9MxXerZ2Z4HSjxTB70VEnJPvZMHI/EZn4Ny31YLHEthdZbV5Gd1h0TGp8VOzPKGShvGrtGBX6MvMfgpK4zuieVWbSfdKeecm8ZNLMpUd4="
20
+
17
21
before_script :
18
22
# # Composer
19
23
# - curl -s http://getcomposer.org/installer | php
20
24
# - php composer.phar install --prefer-source
21
25
- composer self-update
22
26
- composer require dompdf/dompdf:0.6.*
23
- - composer install --prefer-source
27
+ - composer install --prefer-source --dev
24
28
# # PHP_CodeSniffer
25
29
- pyrus install pear/PHP_CodeSniffer
26
30
- phpenv rehash
@@ -35,6 +39,8 @@ before_script:
35
39
# - phpenv rehash
36
40
# # PHPLOC
37
41
# - curl -o phploc.phar https://phar.phpunit.de/phploc.phar
42
+ # # PHPDocumentor
43
+ - mkdir -p build/docs
38
44
39
45
script :
40
46
# # PHP_CodeSniffer
@@ -48,3 +54,9 @@ script:
48
54
# - php phploc.phar src/
49
55
# # PHPUnit
50
56
- phpunit -c ./ --coverage-text
57
+ # # PHPDocumentor
58
+ - vendor/bin/phpdoc.php -d ./src -t ./build/docs
59
+
60
+ after_script :
61
+ # # PHPDocumentor
62
+ - bash .travis_shell_after_success.sh
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ echo " --DEBUG--"
4
+ echo " TRAVIS_REPO_SLUG: $TRAVIS_REPO_SLUG "
5
+ echo " TRAVIS_PHP_VERSION: $TRAVIS_PHP_VERSION "
6
+ echo " TRAVIS_PULL_REQUEST: $TRAVIS_PULL_REQUEST "
7
+
8
+ if [ " $TRAVIS_REPO_SLUG " == " PHPOffice/PHPWord" ] && [ " $TRAVIS_PULL_REQUEST " == " false" ] && [ " $TRAVIS_PHP_VERSION " == " 5.5" ]; then
9
+
10
+ echo -e " Publishing PHPDoc...\n"
11
+
12
+ cp -R build/docs $HOME /docs-latest
13
+
14
+ cd $HOME
15
+ git config --global user.email
" [email protected] "
16
+ git config --global user.name " travis-ci"
17
+ git clone --quiet --branch=gh-pages https://${GH_TOKEN} @github.com/PHPOffice/PHPWord gh-pages > /dev/null
18
+
19
+ cd gh-pages
20
+ echo " --DEBUG : Suppression"
21
+ git rm -rf ./docs/$TRAVIS_BRANCH
22
+
23
+ echo " --DEBUG : Dossier"
24
+ mkdir docs
25
+ cd docs
26
+ mkdir $TRAVIS_BRANCH
27
+
28
+ echo " --DEBUG : Copie"
29
+ cp -Rf $HOME /docs-latest/* ./$TRAVIS_BRANCH /
30
+
31
+ echo " --DEBUG : Git"
32
+ git add -f .
33
+ git commit -m " PHPDocumentor (Travis Build : $TRAVIS_BUILD_NUMBER - Branch : $TRAVIS_BRANCH )"
34
+ git push -fq origin gh-pages > /dev/null
35
+
36
+ echo -e " Published PHPDoc to gh-pages.\n"
37
+
38
+ fi
Original file line number Diff line number Diff line change 37
37
"ext-zip" : " *"
38
38
},
39
39
"require-dev" : {
40
- "phpunit/phpunit" : " 3.7.*"
40
+ "phpunit/phpunit" : " 3.7.*" ,
41
+ "phpdocumentor/phpdocumentor" :" 2.*"
41
42
},
42
43
"suggest" : {
43
44
"ext-gd2" : " Required to add images" ,
You can’t perform that action at this time.
0 commit comments