Skip to content

Instantly share code, notes, and snippets.

View AmeliaBR's full-sized avatar

Amelia Bellamy-Royds AmeliaBR

View GitHub Profile
function Mutilator(data, name, context) {
this.n = name || `mutilation-${+new Date()}`;
this.d = data;
this.c = context || window;
this.isArr = function(p) {
return this.d[p].constructor == Array;
};
this.dispatch = function(p, v, t) {
this.c.dispatchEvent(
new CustomEvent(this.n, {
@Ketrel
Ketrel / relBase.html
Last active October 11, 2023 12:17
Relative url base for jekyll
{% assign relBase = '' %}
{% assign tempDepth = page.url | append: 'hackish-solution' | split: '/' | size | minus: 2 %}
{% for i in (1..tempDepth) %}
{% assign relBase = relBase | append: "../" %}
{% endfor %}
{% if relBase == '' %}
{% assign relBase = './' %}
{% endif %}
@nnja
nnja / gist:9136152c163091614e70defcf3753d06
Created May 26, 2016 20:25
How to access the raw markdown source for a github wiki page
https://raw.github.com/wiki/user/repo/page.md?login=login&token=token
@KelseyDH
KelseyDH / ruby_rails_windows.md
Last active September 4, 2020 05:24
Ruby on Rails Microsoft Windows Troubleshooting Tips

Ruby on Rails Windows Troubleshooting Tips & Survival Guide

Intro/Overview

The Ruby on Rails Windows Troubleshooting tips & Survival Guide is a random catalogue of issues I faced working with Ruby on Rails on Windows (Windows 7 specifically). This guide is not exhaustive, but covers many of the challenges that causes Windows Ruby developers to jump ship to Linux or Mac. If you're reading this guide then you're probably new to Ruby/Rails, so also included is more general beginner advice to help you get going.

Personal Side Note

Before you follow this guide, I strongly recommend you consider using Linux or Mac OS X for Ruby Development instead. Looking to prove a point as a challenge, I ignored this strongly given advice while learning Ruby/Rails. While I eventually did succeed in getting Ruby on Rails to work in Windows, it was not easy, and I easily lost 40+ hours on StackOverFlow to Windows/Ruby configuration issues--time I could have devoted to learning more about th