How to speed up the production of Jekyll / Octopress?

I use Octopress as the mechanism of my blog. It's fine. But if there are many messages, for example, 400+ messages, the generation speed is too slow.

So, is there a way to speed up Jekyll / Octopress generation?

Thanks.

+7
source share
5 answers

Obviously, if you are just working on a single message, there is no need to wait until the entire site is created. What you are looking for is the rake isolate [partial_post_name] task.
Using rake isolate , you can "isolate" only the post you are working on and move all the others to the source/_stash . The partial_post_name parameter is just a few words in the file name for the message. For example, if I want to isolate the message from the previous example, I would use

 rake isolate[plain-english] 

This will move all other messages to source/_stash and save the message 2011-09-29-just-type-the-title-of-the-post-here-in-plain-english.markdown to source/_posts . You can also do this while using rake preview . It just detects massive changes and only regenerates this message since then.

@ Pavan Podil
More info: Tips for speeding up your Octopress site

Update for 2013.01.08:
Hexo - Fast, simple and powerful blog structure powered by Node.js.
Features: Incredibly fast - generate static files at a glance

Update 2013.6.20:
gor - Static websites and the blog generator engine written in Go gor has the following amazing advantages: 1. Speed ​​- Less than 1 second when compiling all of my nearly 200 blogs on wendal.net 2. Simple - only one executable file generated after compilation no other dependency

+3
source

Install Ruby GSL

 gem install gsl 

You should notice an increase in speed.

+1
source

hexo is powered by Node.js. I use it much faster than Octopress. And it provides an easy way to transfer your articles to hexo very easily.

+1
source

You can only create one post at a time using

 rake isolate[your-post] 

and then

 rake integrate 

to return to normal operation.

To fully answer your question, you cannot create only one message . You can see Octopress' Issue No. 395 on this subject, which explains that this is due to a restriction on Jekyll's side.

+1
source

I reached this post with the same problem, but then I didn’t quite like the idea of ​​looting. Also, the built-in task does not integrate with the _drafts workflow. So, what I used is to create a custom config.yml with the excluded _posts folder (using exclude) and only create the draft folder. You can pass another configuration file as a command line parameter to jekyll. I just used this when actively writing new posts, and while posting uses the same old approach (which still takes some time). This approach only builds a message design, and I'm good at it.

 jekyll build --watch --drafts --config _previewconfig.yml 

For those interested in a full worklow, look here.

0
source

All Articles