Using Org-page to Publish to GitHub Pages in Spacemacs
Note: A lot of the steps described below were taken from here.
Install and Configure Org-page
Add org-page to additional-packages in the .spacemacs file.
Add the following to the user-config function in the .spacemacs file:
(require 'org-page) (setq op/repository-directory "/path/to/repository") (setq op/site-domain "http://githubusername.github.io") (setq op/personal-github-link "https://github.com/githubusername") (setq op/site-main-title "Blog Title") (setq op/site-sub-title "Blog Subtitle") (setq op/personal-disqus-shortname "shortname")
Creating a New Repository
Run op/new-repository by pressing SPC SPC op/new-repository. When prompted, specify the path at which the repository should be created.
Creating a New Post
Run op/new-post by pressing SPC SPC op/new-post. Respond to the prompts accordingly.
Publishing a Post
Set the remote in the git repository of the blog:
git remote add origin git@github.com:githubusername/githubusername.github.io git remote -v
Note that org-page does not automatically commit new posts to git; posts need to be committed manually on the source branch prior to running the following command.
Run op/do-publication by pressing SPC SPC op/do-publication. In response to the subsequent prompts, press y, n, y, y.