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
var browserSync = require('browser-sync'), | |
common = require('./__common__'), | |
gulp = require('gulp'), | |
watch = require('gulp-watch'); | |
gulp.task('default', [ | |
'less' | |
], function () { | |
browserSync({ | |
server: { |
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
import Alt from './' | |
// the magic sauce | |
import { createTransform } from './utils/frp' | |
// decorator utilities | |
import { createStore, bind } from './utils/decorators' | |
const alt = new Alt() |
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 python | |
"""Test wordlist parsing speed. | |
See http://news.ycombinator.com/item?id=2716714 | |
Use with /usr/share/dict/words, | |
or e.g. http://www.freebsd.org/cgi/cvsweb.cgi/src/share/dict/web2?rev=1.14;content-type=text/plain | |
""" | |
import pickle |
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
def accept_languages(browser_pref_langs): | |
"""Parses the request and return language list. | |
browser_pref_langs is the plain Accept-Language http request header | |
value. | |
Stolen from Products.PloneLanguageTool, under GPL (c) Plone Foundation, | |
slightly modified. | |
Taken from tweetengine http://github.com/Arachnid/tweetengine/ | |
""" | |
browser_pref_langs = browser_pref_langs.split(',') | |
i = 0 |
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
# Copyright 2008 Google Inc. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, |
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
source :rubygems | |
# V8 JavaScript Engine (for Uglifier) | |
gem "therubyracer" | |
# SASS & Compass | |
gem "sass", "~> 3.2.0.alpha" | |
gem "compass" | |
# For concatenation/compression |
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 refreshLink(link) { | |
var instance = this; | |
var pageDomain = window.location.href.match(/\/\/([^\/]+)/); | |
var linkDomain = link.href.match(/\/\/([^\/]+)/); | |
if (!pageDomain || !linkDomain || pageDomain[1] != linkDomain[1]) { | |
return instance; | |
} |
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 Link to Story 2 | |
// @namespace loominate.net | |
// @version 1.4 | |
// @description Used on github.com to convert a story id to a link to the pivotal tracker story. | |
// @include https://github.com/*/commits/* | |
// @include https://github.com/*/commits | |
// @include https://github.com/*/commit/* |
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 adler32(string) { | |
var length = string.length | |
, modulus = 65521 | |
, index = 0 | |
, a = 1 | |
, b = 0 | |
while (index < length) { | |
a += string.charCodeAt(index++) | |
a %= modulus |
OlderNewer