This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
// http://play.golang.org/p/jZ5pa944O1 <- will not display the colors | |
import "fmt" | |
const ( | |
InfoColor = "\033[1;34m%s\033[0m" | |
NoticeColor = "\033[1;36m%s\033[0m" | |
WarningColor = "\033[1;33m%s\033[0m" | |
ErrorColor = "\033[1;31m%s\033[0m" | |
DebugColor = "\033[0;36m%s\033[0m" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Start stock xenial | |
> docker run -it ubuntu:xenial bash | |
# Prepare image | |
apt-get update \ | |
&& apt-get install vim software-properties-common wget apt-transport-https | |
add-apt-repository -y "deb https://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main" \ | |
&& wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Highlight no responses | |
// @namespace https://support.heroku.com/ | |
// @version 0.1 | |
// @description Highlight no responses | |
// @author Jon McCartie | |
// @include https://support.heroku.com/tags/* | |
// @grant none | |
// ==/UserScript== | |
$('.row.ticket').each(function(index, value) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) | |
require 'the_geek' | |
require 'webmock/rspec' | |
WebMock.disable_net_connect!(allow_localhost: true) | |
RSpec.configure do |config| | |
config.before(:each) do | |
stub_request(:get, /www.boardgamegeek.com/). | |
with(headers: {'Accept'=>'*/*', 'User-Agent'=>'Ruby'}). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# ----------------------------------------------------------------------- | |
# Installs Ruby 2.3 using rbenv/ruby-build on the Raspberry Pi (Raspbian) | |
# | |
# Run from the web: | |
# bash <(curl -s raw_script_url_here) | |
# ----------------------------------------------------------------------- | |
# Set up variables |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'google/apis/gmail_v1' | |
require 'uri' | |
require 'mail' | |
Gmail = Google::Apis::GmailV1 | |
class MailService | |
def initialize(params) | |
@params = params |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Physics(function (world) { | |
var viewportBounds = Physics.aabb(0, 0, window.innerWidth, window.innerHeight) | |
,edgeBounce | |
,renderer | |
; | |
renderer = Physics.renderer('canvas', { | |
el: 'viewport' | |
}); |