Merge pull request #1556 from roots/rename-config-to-setup

Rename config.php to setup.php
This commit is contained in:
Ben Word
2015-10-10 15:00:05 -05:00
6 changed files with 10 additions and 9 deletions

View File

@@ -1,4 +1,5 @@
### HEAD
* Rename config.php to setup.php ([#1556](https://github.com/roots/sage/pull/1556))
* Move init.php to config.php ([#1555](https://github.com/roots/sage/pull/1555))
* Use Sass to style search form, remove search template ([#1545](https://github.com/roots/sage/pull/1545))
* Remove Modernizr ([#1541](https://github.com/roots/sage/pull/1541))

View File

@@ -43,13 +43,13 @@ Install the [Soil](https://github.com/roots/soil) plugin to enable additional fe
* Google CDN jQuery snippet from [HTML5 Boilerplate](http://html5boilerplate.com/)
* Google Analytics snippet from [HTML5 Boilerplate](http://html5boilerplate.com/)
## Installation
## Theme installation
Clone the git repo - `git clone https://github.com/roots/sage.git` and then rename the directory to the name of your theme or website.
## Configuration
## Theme setup
Edit `lib/config.php` to enable or disable theme features, setup navigation menus, post thumbnail sizes, post formats, and sidebars.
Edit `lib/setup.php` to enable or disable theme features, setup navigation menus, post thumbnail sizes, post formats, and sidebars.
## Theme development

View File

@@ -1,6 +1,6 @@
<?php
use Roots\Sage\Config;
use Roots\Sage\Setup;
use Roots\Sage\Wrapper;
?>
@@ -23,7 +23,7 @@ use Roots\Sage\Wrapper;
<main class="main">
<?php include Wrapper\template_path(); ?>
</main><!-- /.main -->
<?php if (Config\display_sidebar()) : ?>
<?php if (Setup\display_sidebar()) : ?>
<aside class="sidebar">
<?php include Wrapper\sidebar_path(); ?>
</aside><!-- /.sidebar -->

View File

@@ -11,8 +11,8 @@
*/
$sage_includes = [
'lib/assets.php', // Scripts and stylesheets
'lib/config.php', // Configuration
'lib/extras.php', // Custom functions
'lib/setup.php', // Theme setup
'lib/titles.php', // Page titles
'lib/wrapper.php' // Theme wrapper class
];

View File

@@ -2,7 +2,7 @@
namespace Roots\Sage\Extras;
use Roots\Sage\Config;
use Roots\Sage\Setup;
/**
* Add <body> classes
@@ -16,7 +16,7 @@ function body_class($classes) {
}
// Add class if sidebar is active
if (Config\display_sidebar()) {
if (Setup\display_sidebar()) {
$classes[] = 'sidebar-primary';
}

View File

@@ -1,6 +1,6 @@
<?php
namespace Roots\Sage\Config;
namespace Roots\Sage\Setup;
use Roots\Sage\Assets;