octopress

How do I update Octopress?


The official guide says:

git pull octopress master # Get the latest Octopress
bundle install # Keep gems updated
rake update_source # update the template's source
rake update_style # update the template's style

I am stuck at rake update_source:

Welcome to Git (version 1.8.5.2-preview20131230)

MrD@MRSD /c/Dropbox/Udun/octopress (source) # source, where I write the blog
$ git checkout master
Branch master set up to track remote branch master from octopress.
Switched to a new branch 'master'
MrD@MRSD /c/Dropbox/Udun/octopress (master)
$ git pull octopress master
From git://github.com/imathis/octopress
 * branch            master     -> FETCH_HEAD
Already up-to-date.
MrD@MRSD /c/Dropbox/Udun/octopress (master)
$ bundle install
Fetching gem metadata from https://rubygems.org/........
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Using rake (0.9.2.2)
# ...
Using bundler (1.3.5)
Your bundle is complete!
Use `bundle show [gemname]` to see where a bundled gem is installed.
MrD@MRSD /c/Dropbox/Udun/octopress (master)
$ rake update_source
## Set the codepage to 65001 for Windows machines
mkdir source.old
cp -r source/. source.old
## Copied source into source.old/
cp -r --remove-destination .themes/classic/source/. source
cp -r --remove-destination source.old/_includes/custom/. source/_includes/custom
/
rake aborted!
No such file or directory - source.old/_includes/custom/.
c:/Dropbox/Udun/octopress/Rakefile:206:in `block in <top (required)>'
Tasks: TOP => update_source
(See full trace by running task with --trace)

So how do I proceed ?

EDIT: I opened an issue on Jul 16, 2014: https://github.com/imathis/octopress/issues/1604

I have since rebased source on master (need I say I do not care about the source history nor my typos are meant to be shared) and the blog functions but I'd like some feedback on this - namely:

do I need to rebase my source branch on master to properly update ?


Solution

  • Well the real answer is I should never have checked out master. The process went smoothly when I did it from source...

    MrD@MRSD /c/Dropbox/Udun/octopress (source)
    $ rake update_source
    ## Removed existing source.old directory
    rm -r source.old
    mkdir source.old
    cp -r source/. source.old
    ## Copied source into source.old/
    cp -r --remove-destination .themes/classic/source/. source
    cp -r --remove-destination source.old/_includes/custom/. source/_includes/custom
    /
    cp source.old/favicon.png source
    ## Updated source ##
    
    MrD@MRSD /c/Dropbox/Udun/octopress (source)
    $ rake update_style
    mv sass sass.old
    ## Moved styles into sass.old/
    cp -r .themes/classic/sass/ sass
    cp -r sass/custom/. sass.old/custom
    ## Updated Sass ##
    

    Still it overwrote:

    source/_includes/navigation.html
    source/_layouts/post.html
    

    on rake update_source and:

    sass/custom/_styles.scss
    

    on rake update_style.

    Also I wonder - should I rebase on master ?

    EDIT: to the best of my belief one should issue git rebase master and closing this