Olai Blog

A flexible but powerful hosted static blog generator

How to post from MarsEdit to Github Pages

Posted: Apr 29, 2015 Tags: marsedit | ghpages |

Content marketing is still the primary marketing strategy for startups and high-growth companies. Within content marketing, blogging reigns as the best tool for inbound marketing.

Wordpress is a tool-of-choice for most bloggers. But it is plagued with security and performance issues. Alternative to Wordpress is static site generators like Jekyll. By moving to Jekyll, you are tied to the laptop in which it is installed. It is not only the mobility that you loose by switching to a static site generator but a whole host of flexibility like blogging using any of the mobile or desktop tools that offer additional functionalities.

As I poured through many sites dedicated to bootstrappers and freelancers, I often read that people were struggling with these problems. Freelancers and small businesses don’t have much time or people to keep Wordpress sites up and running; also they are not geeky enough to setup a tool like Jekyll.

That got me thinking. What if there could be an alternative that could combine the flexibility of CMS with performance and security of static site generators?

I’m excited to announce Olai, which is exactly that.

At its core, Olai is a server with integration on both sides of the blogging process. It integrates with existing desktop clients on the ‘writing’ side and integrates with different ‘hosts’ on the ‘publish’ side.

Olai can already publish to Github pages. Further integrations like, Amazon S3 are planned. On the writing side, I’ve been using Olai with MarsEdit for my blogs – Certainties & Serendipities, finally{}, Tech Snippets at Github for sometime now.

In this post, I’m detailing how to use MarsEdit along with Olai to post to Github pages.

For those who don’t know, GitHub Pages are public webpages hosted and published through Github. Since Github pages are hosted at Github, they are free to host. That is not the only benefit. Source control comes inbuilt with it, so you get a complete history of your posts.

Here are the steps to blog from MarsEdit to Github pages. Some of these steps may be irrelevant if you already have a Github account and Github pages repository. Skip those steps.

Create Github repository & token

  1. Create a Github account at http://github.com.
  2. After login, go to https://github.com/new, to create a new repository.
  3. Enter the name of the repository as username.github.io, replacing username with whatever username you got from Github in the first step. It is imperative that the name of the repository is in this specific pattern.
  4. For security purposes, Olai uses a Github token rather than the password. If you decide to move out of Olai, all that you need to do would be to revoke the token rather than change Github password. If you don’t understand, take it from me that it is a good security practice. Security is a thought built fully into developing Olai.
  5. Visit, https://github.com/settings/tokens/new and generate a token. Be sure that you select only ‘public_repo’ and nothing else. This way, you provide Olai access only to public repositories.
  6. Copy the token. You can’t go back to this page and view the token again. So copy and paste it into a text document.

Creating a site in Olai

  1. Signup for a new account at Olai
  2. Login
  3. Create a new site. Provide userid and the token. Also enter a nickname for your site which will be used within Olai for reference

If you want you can also create new entries from within the web application. Since this post is about blogging from MarsEdit, we will use MarsEdit to write our posts.

Using MarsEdit to post to Olai

  1. Create a new blog (File->New Blog).
  2. Enter a name for your blog & the URL. MarsEdit will try to detect settings but will fail. It is ok.
  3. Select ‘Edit Settings’ from the dialog box
  4. Select ‘Wordpress’ for system name and ‘Wordpress API’ for System API. Enter ‘http://app.olai.in/xmlrpc/’ as API endpoint URL and the blog id from Olai (Id can be seen in the status bar when you point to the sitename within ‘Olai->My Sites’ menu)
  5. If you refresh now, MarsEdit will ask for username and password. Provide your username and password you entered at Olai.
  6. Go ahead and create a new post and publish it.
  7. Navigate to your website (username.github.io). You will see your new post.

There is only one gotcha you need to be aware of if you are integrating with an existing Github page. Olai can’t import existing posts. You need to take a backup and post them again in Olai. If you are just starting with a fresh Github page, you should be fine.

Now go and signup.

Got questions? Reach out to me at twitter or email me at [email protected]

If you want to know more about Github pages, read this tutorial at thinkful.com

Comments

comments powered by Disqus