Skip to content

Instantly share code, notes, and snippets.

Avatar
👨‍💻
Producing legacy code

Yuri Golobokov nimf

👨‍💻
Producing legacy code
View GitHub Profile
@nimf
nimf / build-notifier.rb
Last active Jul 3, 2018 — forked from zoul/build-notifier.rb
Posts a message to the OS X notification center when a Jekyll build is finished. Requires TerminalNotifier, see http://git.io/5X99Eg or “gem install terminal-notifier”.
View build-notifier.rb
begin
require 'terminal-notifier'
module Jekyll
class Site
alias jekyll_process process
def process
jekyll_process
TerminalNotifier.notify("🍻 Jekyll rebuild finished")
rescue => e
TerminalNotifier.notify("💥 Jekyll rebuild failed: #{e.message}")
@nimf
nimf / Rakefile.rb
Last active Feb 12, 2016 — forked from drogus/Rakefile.rb
I found this in the answer by Jason to this question http://stackoverflow.com/questions/19206764/how-can-i-load-activerecord-database-tasks-on-a-ruby-project-outside-rails. This is a Rakefile for using ActiveRecord without Rails. It loads ActiveRecord's databases.rake file making ActiveRecord rake tasks available for your non-rails app.
View Rakefile.rb
require 'bundler/setup'
require 'active_record'
include ActiveRecord::Tasks
class Seeder
def initialize(seed_file)
@seed_file = seed_file
end
You can’t perform that action at this time.