Commit 448ebe4e authored by Tino Goratsch's avatar Tino Goratsch

Merge branch 'feature/apidocs' into develop

parents 4743d27c c13f6367
......@@ -3,6 +3,7 @@
/.php_cs.cache
/ACP3/config.yml
/build/logs/
/build/sami/
/cache/*
/node_modules
/tests/cache/
......
<?php
/**
* Copyright (c) by the ACP3 Developers.
* See the LICENCE file at the top-level module directory for licencing details.
*/
use Sami\Sami;
use Symfony\Component\Finder\Finder;
$iterator = Finder::create()
->files()
->name('*.php')
->exclude('Resources')
->exclude('Tests')
->exclude('Modules/ACP3/Filemanager/libraries/kcfinder')
->in($dir = __DIR__ . '/ACP3');
return new Sami($iterator, array(
'title' => 'ACP3 CMS API',
'build_dir' => __DIR__ . '/build/sami/docs',
'cache_dir' => __DIR__ . '/build/sami/cache',
'default_opened_level' => 2,
));
......@@ -54,6 +54,12 @@ deploy:
on:
tags: true
condition: "$TRAVIS_PHP_VERSION = 7.0*"
- provider: script
script: ./build/travis/generate_api_docs.sh
skip_cleanup: true
on:
branch: develop
condition: "$TRAVIS_PHP_VERSION = 7.0*"
cache:
directories:
......
#!/bin/bash
BRANCH_NAME='sami-update'
REPO_DIR='apidocs'
curl -O http://get.sensiolabs.org/sami.phar
git clone https://github.com/ACP3/${REPO_DIR}.git ./build/${REPO_DIR}
cd ./build/${REPO_DIR}
git checkout -q -b ${BRANCH_NAME}
git rm -q -r .
php ../../sami.phar update ../../.sami.php
cp -r ../sami/docs/* .
git add .
git commit -am "Updated the API docs"
git checkout -q master
git merge -q ${BRANCH_NAME}
git branch -q -d ${BRANCH_NAME}
git push --all
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment