Merge branch 'development'
* development: Add a refrence to themes_path realpath returns the canonicalized absolute pathname Dont set theme-variant if there is none Add Vulkan Tutorial to list of sites using the framework Fix autoloading and prioritize getting it as a dependency Change the way the commands are declare, separate "generate" and "serve" Support BOM at the beginning of content, fixes #372 Applied fixes from StyleCI Add the daux --serve command to simplify writing documentation and reading. Fix the way front matter is handled, fixes #345 Create a "daux" binary Add badges and code coverage Mark as non compatible with PHP 5.4 Applied fixes from StyleCI Added .travis.yml file Build latest phar Add the ability to do relative links in documentations Compile latest version Minify files Remove Bootstrap and simplify styles # Conflicts: # libs/DauxHelper.php # libs/bootstrap.php
This commit is contained in:
commit
fb5fb41e96
@ -35,13 +35,14 @@ class DauxHelper
|
|||||||
}
|
}
|
||||||
|
|
||||||
$theme = explode('-', $params['html']['theme']);
|
$theme = explode('-', $params['html']['theme']);
|
||||||
// do we have a variant or only a theme ?
|
|
||||||
if(isset($theme[1])) {
|
// do we have a variant or only a theme ?
|
||||||
$params['html']['theme-variant'] = array_pop($theme);
|
if (isset($theme[1])) {
|
||||||
$params['html']['theme'] = implode('-', $theme);
|
$params['html']['theme-variant'] = array_pop($theme);
|
||||||
} else {
|
$params['html']['theme'] = implode('-', $theme);
|
||||||
$params['html']['theme'] = array_pop($theme);
|
} else {
|
||||||
}
|
$params['html']['theme'] = array_pop($theme);
|
||||||
|
}
|
||||||
|
|
||||||
if (!is_dir(realpath(($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])))) {
|
if (!is_dir(realpath(($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])))) {
|
||||||
throw new \RuntimeException("Theme '{$params['html']['theme']}' not found");
|
throw new \RuntimeException("Theme '{$params['html']['theme']}' not found");
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
// Loaded as a dependency
|
||||||
|
if (file_exists(__DIR__ . '/../../../autoload.php')) {
|
||||||
|
return require_once __DIR__ . '/../../../autoload.php';
|
||||||
|
}
|
||||||
|
|
||||||
// Loaded in the project itself
|
// Loaded in the project itself
|
||||||
if (file_exists(__DIR__ . '/../vendor/autoload.php')) {
|
if (file_exists(__DIR__ . '/../vendor/autoload.php')) {
|
||||||
return require_once __DIR__ . '/../vendor/autoload.php';
|
return require_once __DIR__ . '/../vendor/autoload.php';
|
||||||
}
|
}
|
||||||
|
|
||||||
// Loaded as a dependency
|
|
||||||
if (file_exists(__DIR__ . '/../../../../autoload.php')) {
|
|
||||||
return require_once __DIR__ . '/../../../../autoload.php';
|
|
||||||
}
|
|
||||||
|
|
||||||
// Loaded in the project itself, when vendor isn't installed
|
// Loaded in the project itself, when vendor isn't installed
|
||||||
if (file_exists(__DIR__ . '/../daux.phar')) {
|
if (file_exists(__DIR__ . '/../daux.phar')) {
|
||||||
define('PHAR_DIR', __DIR__ . '/..');
|
define('PHAR_DIR', __DIR__ . '/..');
|
||||||
|
Loading…
Reference in New Issue
Block a user