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
from __future__ import print_function | |
import httplib2 | |
import os | |
from apiclient import discovery | |
import oauth2client | |
from oauth2client import client | |
from oauth2client import tools | |
from oauth2client.service_account import ServiceAccountCredentials |
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
<form> | |
<fieldset> | |
<div class='form-group'> | |
<input type="email" class='form-control' name="entry[email]" placeholder="Enter Your Email" required> | |
</div> | |
<div class='form-group'> | |
<input type="text" class='form-control' name="entry[name]" placeholder="Enter Your Name" required> | |
</div> | |
</fieldset> | |
<fieldset class='form-group'> |
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
window.jQuery(function() { | |
var $ = window.jQuery; | |
var submittable = $('[data-submittable="true"]'); | |
submittable.find('[data-submit-state]:not([data-submit-state="unsubmitted"])').hide(); | |
submittable.find('[data-submit-state="unsubmitted"]').show(); | |
function watchForSubscriptionSuccess(submittable) { | |
_GT.active_context.on('change', function(changes) { |
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
# Use this setup block to configure all options for Bandit. | |
Bandit.setup do |config| | |
bandit_store = ENV['BANDIT_STORE'] || 'redis' | |
bandit_store_config = { } | |
case bandit_store | |
when 'redis' | |
bandit_store_config['url'] = ENV['REDIS_URL'] | |
when 'dalli' | |
bandit_store_config['host'] = ENV['MEMCACHE_SERVERS'] || '127.0.0.1' | |
bandit_store_config['namespace'] = ENV['BANDIT_NAMESPACE'] || 'bandit' |
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
# --- | |
# Doorman is yet another feature flipper. You can use Doorman to limit access | |
# of features on a global or per object scale to specific users or accounts. | |
# | |
# Doorman uses Rolify to store state and keeps the global list of features | |
# in Redis (or maybe in PG - depending on what's easier). | |
# | |
# :section Example Usage | |
# | |
# Setting up instructions |
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
Mongoose: pings.ensureIndex({ timestamp: -1 }) { safe: undefined, background: true } | |
Mongoose: checkevents.ensureIndex({ timestamp: -1, check: 1 }) { safe: undefined, background: true } | |
Mongoose: checkhourlystats.ensureIndex({ timestamp: -1, check: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoose: checkdailystats.ensureIndex({ timestamp: -1, check: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoose: checkmonthlystats.ensureIndex({ timestamp: -1, check: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoose: checkyearlystats.ensureIndex({ timestamp: -1, check: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoose: taghourlystats.ensureIndex({ timestamp: -1, name: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoose: tagdailystats.ensureIndex({ timestamp: -1, name: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoose: tagmonthlystats.ensureIndex({ timestamp: -1, name: 1 }) { safe: undefined, background: true, unique: true } | |
Mongoos |
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
%!TEX TS-program = xelatex | |
\documentclass[12pt]{scrartcl} | |
% The declaration of the document class: | |
% The second line here, i.e. | |
% \documentclass[12pt]{scrartcl} | |
% is a standard LaTeX document class declaration: | |
% we say what kind of document we are making in curly brackets, | |
% and specify any options in square brackets. |
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
$('pre > code').each(function(index) { | |
var _this = $(this); | |
var text = _this.text(); | |
lines = text.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/); | |
indent = 0; | |
var firstCharFinder = /^\s*\S/i; | |
var leftTrimLength = 0; | |
var contentStarted = false; | |
adjusted_lines = $.map(lines, function(line, i) { | |
if(!contentStarted) { |
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
<script> | |
function onInteraction(e) { | |
// Run the discount code here. | |
// Important - interaction events can happen multiple times with a given overlay so | |
// you'll want to ensure the discount is only applied once. | |
} | |
$(window).on('message', function(e) { | |
// Make sure the message is coming from Rooster | |
if (e.originalEvent.origin + '/' !== window.location.protocol + _GT_config.gt_host) { |
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
#Your normal .bashrc code should go here | |
# adding RVM | |
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # This loads RVM into a shell session. | |
# Use current directory bin path first | |
export PATH=./bin/$PATH | |
#load bash bash colours and git completion for a pretty and efficient workflow | |
source ~/bash-colours.sh |
NewerOlder