Skip to content

Instantly share code, notes, and snippets.

@baldowl
baldowl / import.rb
Created January 8, 2012 16:41 — forked from juniorz/import.rb
Import a blogger archive to jekyll (octopress version)
require 'rubygems'
require 'nokogiri'
require 'fileutils'
require 'date'
require 'uri'
# usage: ruby import.rb my-blog.xml
# my-blog.xml is a file from Settings -> Basic -> Export in blogger.
data = File.read ARGV[0]
@baldowl
baldowl / god.rb
Created June 24, 2010 08:49 — forked from defunkt/god.rb
How to avoid untracked rake processes
rails_root = "/data/github/current"
20.times do |num|
God.watch do |w|
w.dir = rails_root
w.env = {'RAILS_ENV' => 'production'}
w.name = "dj-#{num}"
w.group = 'dj'
w.interval = 30.seconds