Skip to content

Instantly share code, notes, and snippets.

View henrrrik's full-sized avatar

Henrik Sjökvist henrrrik

  • Mobility46
  • Stockholm, Sweden
View GitHub Profile
@henrrrik
henrrrik / henriks-breakfast-smoothie.md
Last active August 29, 2015 14:15
Henrik's Beard Booster Breakfast Smoothie

Henrik's Beard Booster Breakfast Smoothie

Serves 1

  • 2 dl unsweetened almond milk
  • 1 fistful fresh baby spinach
  • 1 tablespoon chia seeds
  • 1 fistful almonds (soaked overnight if possible)
  • 1 banana
  • 1 dl frozen berries (e.g. rasperries and blueberries)

Keybase proof

I hereby claim:

  • I am henrrrik on github.
  • I am henrrrik (https://keybase.io/henrrrik) on keybase.
  • I have a public key whose fingerprint is 0C38 ADD9 D38B F080 7893 0927 2E5A 1778 D3E5 B610

To claim this, I am signing this object:

#!/usr/bin/env ruby
require 'english'
require 'rubocop'
ADDED_OR_MODIFIED = /A|AM|^M/.freeze
changed_files = `git status --porcelain`.split(/\n/).
select { |file_name_with_status|
file_name_with_status =~ ADDED_OR_MODIFIED
@henrrrik
henrrrik / lagg_ut.coffee
Created February 5, 2013 14:08
LÄGG UT!
# Description:
# LÄGG UT
#
module.exports = (robot) ->
robot.hear /lägg ut/i, (msg) ->
msg.send 'http://www.youtube.com/watch?v=H30SvVzluwI?autoplay=true'
@henrrrik
henrrrik / 20120118012543_create_site_configuration.rb
Created October 25, 2012 11:58 — forked from bigfive/20120118012543_create_site_configuration.rb
Ruby on Rails. Key value table for site configuration integrated with Active Admin and Formtastic forms. Updated to use erb instead of haml.
# db/migrations/20120118012543_create_site_configuration.rb
class CreateSiteConfigurations < ActiveRecord::Migration
def change
create_table :site_configurations do |t|
t.string :key
t.text :value
t.string :form_type
t.string :form_collection_command
@henrrrik
henrrrik / rbenvsudo.sh
Created September 18, 2012 15:11 — forked from mrrooijen/rbenvsudo.sh
A little shell function that allows you to perform rbenv (gem) commands with sudo privileges. Similar to rvmsudo.
function rbenvsudo(){
executable=$1
shift 1
sudo $(rbenv which $executable) $*
}
@henrrrik
henrrrik / Gemfile
Created February 22, 2012 12:24 — forked from benatkin/Gemfile
Using rack-ssl-enforcer to secure ActiveAdmin
# Add this to the Gemfile...
gem 'rack-ssl-enforcer', :require => 'rack/ssl-enforcer'
@henrrrik
henrrrik / newpost.rb
Created January 25, 2012 18:26 — forked from bru/newpost.rb
Creates a new Jekyll post, opens it in MacVim, and adds to the git index
#!/usr/bin/env ruby
unless ARGV[0]
puts 'Usage: newpost "the post title"'
exit(-1)
end
blog_root = "/Users/henrik/Project/henrrrik.github.com"
date_prefix = Time.now.strftime("%Y-%m-%d")
postname = ARGV[0].strip.downcase.gsub(/ /, '-')
# $Id$
# Based on work of chuck@acquia.com that's in the MacPorts repository.
PortSystem 1.0
name drush
version 3.1
categories www php
platforms darwin