forked from hakobyansen/entrust
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docs.php
24 lines (19 loc) · 666 Bytes
/
docs.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php require __DIR__ . '/vendor/autoload.php';
use Sami\Sami;
use Sami\Version\GitVersionCollection;
use Symfony\Component\Finder\Finder;
$iterator = Finder::create()
->files()
->name('*.php')
->in($dir = __DIR__ . '/src');
$versions = GitVersionCollection::create($dir)
->add('master', 'master branch')
->addFromTags('2.*');
$options = array(
'versions' => $versions,
'title' => 'Entrust API',
'build_dir' => __DIR__ . '/build/docs/%version%',
'cache_dir' => __DIR__ . '/build/cache/docs/%version%',
'default_opened_level' => 2,
);
return new Sami($iterator, $options);