2011-07-19 22:28:48 -04:00
---
layout: page
title: Configuring Octopress
date: July 19 2011
sidebar: false
footer: false
---
2011-07-22 11:48:24 -04:00
[« Previous, Octopress Setup ](/docs/setup )
2011-07-19 22:28:48 -04:00
2011-07-22 00:56:03 -04:00
I've tried to keep configuring Octopress fairly simple and you'll probably only ever change the `Rakefile` and the `_config.yml` .
2011-07-19 22:28:48 -04:00
Here's a list of files for configuring Octopress.
2011-08-02 00:40:15 -04:00
``` sh
_config.yml # Main config (Jekyll's settings)
Rakefile # Configs for deployment
config.rb # Compass config
config.ru # Rack config
```
2011-07-19 22:28:48 -04:00
Configurations in the `Rakefile` are mostly related to deployment and you probably won't have to touch them unless you're using rsync.
## Blog Configuration
In the `_config.yml` there are three sections for configuring your Octopress Blog.
2011-07-22 11:48:24 -04:00
**Spoiler:** You must change `url` , and you'll probably change `title` , `subtitle` and `author` and enable some 3rd party services.
2011-07-19 22:28:48 -04:00
### Main Configs
2011-08-02 00:40:15 -04:00
``` yaml
url: # For rewriting urls for RSS, etc
title: # Used in the header and title tags
subtitle: # A description used in the header
author: # Your name, for RSS, Copyright, Metadata
simple_search: # Search engine for simple site search
2011-12-11 01:32:57 -05:00
description: # A default meta description for your site
2012-05-21 00:39:36 -04:00
date_format: # Format dates using Ruby's date strftime syntax
2011-08-02 00:40:15 -04:00
subscribe_rss: # Url for your blog's feed, defauts to /atom.xml
subscribe_email: # Url to subscribe by email (service required)
2012-05-21 00:39:36 -04:00
category_feeds: # Enable per category RSS feeds (defaults to false in 2.1)
2011-08-02 00:40:15 -04:00
email: # Email address for the RSS feed if you want it.
```
2011-07-22 00:56:03 -04:00
**Note:** If your site is a multi-author blog, you may want to set this config's `author` to the name of your
company or project, and add author metadata to posts and pages to give proper attribution for those works.
2011-07-19 22:28:48 -04:00
### Jekyll & Plugins
2011-07-22 00:56:03 -04:00
These configurations are used by Jekyll and Plugins. If you're not familiar with Jekyll, you should probably have a look at the [configuration docs ](https://github.com/mojombo/jekyll/wiki/Configuration ) which lists more options that aren't covered here.
2011-08-02 00:40:15 -04:00
``` yaml
root: # Mapping for relative urls (default: /)
permalink: # Permalink structure for blog posts
source: # Directory for site source files
destination: # Directory for generated site files
plugins: # Directory for Jekyll plugins
code_dir: # Directory for code snippets (for include_code plugin)
category_dir: # Directory for generated blog category pages
pygments: # Toggle python pygments syntax highlighting
paginate: # Posts per page on the blog index
2011-08-16 01:00:23 -04:00
pagination_dir: # Directory base for pagination URLs eg. /blog/page/2/
2011-08-02 00:40:15 -04:00
recent_posts: # Number of recent posts to appear in the sidebar
default_asides: # Configure what shows up in the sidebar and in what order
blog_index_asides: # Optional sidebar config for blog index page
post_asides: # Optional sidebar config for post layout
page_asides: # Optional sidebar config for page layout
```
2011-07-22 00:56:03 -04:00
If you want to change the way permalinks are written for your blog posts, see [Jekyll's permalink docs ](https://github.com/mojombo/jekyll/wiki/Permalinks ).
2011-08-16 01:00:23 -04:00
**Note:** Jekyll has a `baseurl` config which offers mock subdirectory publishing support by adding a redirect to Jekyll's WEBrick server. **Please don't use this.**
2011-12-11 01:32:57 -05:00
If you want to publish your site to a subdirectory, [(see Deploying Octopress to a Subdirectory) ](/docs/deploying/subdir/ ).
2011-07-19 22:28:48 -04:00
2011-08-01 17:38:25 -04:00
< h3 id = "third_party" > 3rd Party Settings< / h3 >
2011-07-19 22:28:48 -04:00
These third party integrations are already set up for you. Simply fill in the configurations and they'll be added to your site.
2012-05-21 00:39:36 -04:00
- **Github** - *List your github repositories in the sidebar*
2011-08-02 00:40:15 -04:00
- **Twitter** - *Setup a sidebar twitter feed, follow button, and tweet button (for sharing posts and pages).*
- **Google Plus One** - *Setup sharing for posts and pages on Google's plus one network.*
- **Pinboard** - *Share your recent Pinboard bookmarks in the sidebar.*
- **Delicious** - *Share your recent Delicious bookmarks in the sidebar.*
- **Disqus Comments** - *Add your disqus short name to enable disqus comments on your site.*
- **Google Analytics** - *Add your tracking id to enable Google Analytics tracking for your site.*
2012-05-21 00:39:36 -04:00
- **Facebook** - *Add a Facebook like button*
2011-07-19 22:28:48 -04:00
2011-07-22 11:48:24 -04:00
The Octopress layouts read these configurations and only include the javascript and html necessary for the enabled services.
2011-08-02 00:40:15 -04:00
[Next, Blogging with Octopress » ](/docs/blogging/ )