Hexo and Jenkins atop Os X

In which I ramble a bit about setting up CI for this very blog.

I have a Jenkins server running on my OsX computer. (… or … I’m setting one up anyway) I also have (am establishing?) a blog built by Hexo … because that seems the right way to do this sort of thing. My constraints of “MarkDown“ and “no really - let me use MarkDown because I’m going to have a lot of code fragments” seem alien to most blogging software - “Hexo delivers” as the kids say.

I knew that this would all work from a command line on the computer and a command line on my Windows 7 PC. After a bunch of chewing - I’ve scrawled this post in victory as a sort of test.

NPM setup

Hexo is built in Node.JS. I installed it and played about with it as I was instructed.

npm install hexo
npm install hexo-generator-sitemap --save

After installing Node.JS I encountered various errors and I switching to a stable version of NPM. (… which I thought I had already used but … I guess not)

npm -g install npm

This was discussed here but may be irrelevant.

The Build

I setup Jenkins to poll (and pull) my repository at H/15 * * * *. I had already setup a Hexo site and configured it to deploy to GitHub pages. (… which incidentally don’t seem to do anything interesting for you with Jekyll AFAIK)

The “secret” to this recipe seemed to be that the Jenkins build seems to require installing Hexo itself to work. Not just npm install in the folder but full-on npm install hexo et al. This seems odd to me but it’s what worked … but this is a CI server so longish builds are fine with me.

I used five steps, each a shell command, to perform the generation and deploy the site.

The first command installs Hexo. I tried to install it (globally?) with -g but encountered a security exception.

npm install hexo

The second command installs a sitemap plugin that should make my site reachable from Google-like crawlers

npm install hexo-generator-sitemap --save

The third command … installs … the site? This may be redundant but I’m not interested in going through a “change” > “reboot” > “check” cycle to learn that I’ve broken my configuration.

npm install

The fourth command actually generates the site.

hexo generate

The fifth and final command uploads the generated site. It seems odd to me that this doesn’t implicitly generate the site, but I’m not worried.

hexo deploy


So … yeah … that’s that. This post was the first one that I set to push out through this system.

Next … I need / want to get this theme working on small (mobile) screens.

… and finish the template engine for my other stuff.

… and a script-binding generator.

… and write a blub about setting up Jenkins ; that was way harder than it should have been.

New Digs

I am experimenting with Hexo. I do believe it’s much nicer than my old system.

So far I’ve setup a basic site, a sitemap generator and it deploys to my existing GitHub pages configuration. Now I’m tweaking themes/ and copying over worthwhile articles from previous blogs!

Whole thing weighs in at 480K (or did before I added this sentence) so I’m fighting the Website Obesity Crisis somewhat … right?

… I pass the Taft test I think …


You don’t need members when you’ve got SWAG!

Actually … you don’t get many members with this idea. By casting this I can pass around an immutable structure of up-to sizeof(void*) bytes.

First Post

Can I use polymorphic-static-templates to auto-magically wire meta-functions into a Lua allocator?

Presently I’m using several “make—” functions to “decorate” objects after allocation and enable get/set/run meta-functions. I keep feeling the “smell” that some esoteric template thingies could be used to make these steps declarative (or maybe automatic!)

Hello World

Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any problems when using Hexo, you can find the answer in troubleshooting or you can ask me on GitHub.

Quick Start

Create a new post

$ hexo new "My New Post"

More info: Writing

Run server

$ hexo server

More info: Server

Generate static files

$ hexo generate

More info: Generating

Deploy to remote sites

$ hexo deploy

More info: Deployment