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
# ~*~ encoding: utf-8 ~*~ | |
require 'faraday' | |
require 'logger' | |
require 'uri' | |
require 'base64' | |
require 'fileutils' | |
BOOTHS = ['Alpha Chi Omega', 'Alpha Epsilon Pi', 'Alpha Kappa Psi', 'Alpha Phi', 'Alpha Phi Omega', 'Asian Students', 'BioSAC', 'Delta Delta Delta', 'Delta Gamma', 'Delta Tau Delta', 'Delta Upsilon', 'Fringe', 'Kappa Alpha Theta', 'Kappa Alpha Theta', 'Kappa Kappa Gamma', 'Kappa Sigma', 'KGB', 'Mayur', 'Mudge', 'Sigma Phi Epsilon', 'Singapore Students', 'Spirit', 'Stever', 'Students Dormitory Council', 'Taiwanese Students'] | |
INTERVAL = 15 * 60 |
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
description "Integrated Protection Against Defacement System" | |
respawn | |
start on runlevel [2345] | |
stop on runlevel [!12345] | |
script | |
AWS_CONFIG_FILE=/etc/aws \ | |
RBENV_ROOT=/usr/local/rbenv \ |
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 | |
prepend () | |
{ | |
# extract branch name | |
branch_name=$(git symbolic-ref -q HEAD) | |
branch_name=${branch_name##refs/heads/} | |
# extract story ID | |
[[ ${branch_name} =~ ^(chore|feature|bug)\/X([[:digit:]]+)$ ]] && sed -i '' '1i\ | |
'"[#${BASH_REMATCH[2]}] " "$1" |
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
basePath = '../'; | |
files = [ | |
JASMINE, | |
JASMINE_ADAPTER, | |
// cdn/vendor files | |
'vendor/assets/javascripts/jquery-*.min.js', | |
'vendor/assets/javascripts/angular/angular.min.js', |
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/sh | |
# install nodejs, if using cloudbees | |
curl -s -o use-node https://repository-cloudbees.forge.cloudbees.com/distributions/ci-addons/node/use-node | |
NODE_VERSION=0.11.1 source ./use-node | |
# install phantomjs, karma | |
[ -d node_modules/phantomjs ] || npm install phantomjs | |
[ -d node_modules/karma ] || npm install karma |
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
#!/usr/bin/env ruby | |
require 'github_api' | |
require 'faraday-http-cache' | |
require 'logger' | |
@store = ActiveSupport::Cache::MemoryStore.new | |
@github = Github::Repos::Contents.new do |config| | |
config.stack.insert_before Github::Response::Jsonize, Faraday::HttpCache, @store | |
end |
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
#!/usr/bin/env ruby | |
# Usage: | |
# load './github.rb' | |
# 10.times { fire } | |
require 'github_api' | |
require 'faraday-http-cache' | |
require 'moneta' | |
require 'active_support/cache/moneta_store' | |
require 'logger' |
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
function conversion(){ | |
var tracker = _gat._createTracker('UA-XXXXXXX-X'); | |
tracker._trackEvent('Users', 'Sign Up'); | |
} | |
$('.LR-sign-up-submit').click(conversion); | |
$('.LR-sign-up-input').keypress(function(c) { | |
(13 == c.which) && conversion(); | |
}); |
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
#!/usr/bin/env ruby | |
unless File.exists?('Gemfile') | |
File.write('Gemfile', <<-GEMFILE) | |
source 'https://rubygems.org' | |
gem 'rails', github: 'rails/rails', branch: 'master' | |
gem 'sqlite3' | |
GEMFILE | |
system 'bundle' | |
end |
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 'mongoid' | |
require 'fabrication' | |
Mongoid::Config.load_configuration({ | |
sessions: { | |
default: { | |
hosts: ['localhost:27017'], | |
database: 'local' | |
} | |
} |