Directory structure of Octopress
Asked Answered
D

1

6

I want to understand the entire directory structure of Octopress. Each and every folder and how they fit in together. Could not find any docs online.

ex: What is the difference between public and _deploy folder?

Help and Pointers would be much appreciated.

Dicker answered 8/9, 2012 at 7:15 Comment(2)
Are you asking for someone to explain every folder to you?Topcoat
I am just asking the purpose of every folder. It is documented nowhere so a Stack Overflow question will help a lot of people.Dicker
F
11

_deploy/:

(After run rake generate rake deploy)This will generate your blog, copy the generated files into _deploy/, add them to git, commit and push them up to the master branch. In a few seconds you should get an email from Github telling you that your commit has been received and will be published on your site. via Deploying to Github Pages

public: compiled site directory,your public directory will be synced to your remote page.

Difference:public/ is a rack convention and it gets wiped with each generate. _deploy/ is contains a git repo for gh-pages deployment. via @Brandon Mathis

root:               # Mapping for relative urls (default: /)
    source/         # Directory for site source files
      _includes/    # Main layout partials
        custom/     # <- Customize head, header, navigation, footer, and sidebar here
        asides/     # Theme sidebar partials
        post/       # post metadata, sharing & comment partials
      _layouts/     # layouts for pages, posts & category archives

permalink:          # Permalink structure for blog posts
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

Here’s a list of files for configuring Octopress.

_config.yml       # Main config (Jekyll's settings)
Rakefile          # Configs for deployment
config.rb         # Compass config
config.ru         # Rack config

See the full documentation at Octopress Documentation

Finesse answered 10/9, 2012 at 16:31 Comment(4)
Thanks for the explanation. I still dont understand the purpose of public. For serving remote pages we have _deploy right? Why public? Sorry if its too much of a newbie question.Dicker
_deploy directory isn't keep in version control. More infoFinesse
public/ is a rack convention and it gets wiped with each generate. _deploy/ is contains a git repo for gh-pages deployment. via @Brandon Mathis More infoFinesse
_deploy/ is only created if you're deploying to GitHub pages. It contains a .git directory which would be wiped out by Jekyll each time it is generated if it were used as the "compiled site" directory. For those who are deploying to Heroku, some rack server of their own, public is a standard name for "files to be hosted publicly" and it is automatically served up by Rack.Gyatt

© 2022 - 2024 — McMap. All rights reserved.