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
# EXAMPLEONE | |
upstream exampleone { | |
server host-ip:3000; | |
} | |
# EXAMPLETWO | |
upstream exampletwo { | |
server host-ip:3001; | |
} |
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 Q = require('q'); | |
var async = require('async'); | |
var fs = require('fs'); | |
var gm = require('gm'); | |
var join = require('path').join; | |
var readdir = Q.denodeify(fs.readdir); | |
var dir = join(__dirname, 'images'); | |
var dest = join(__dirname, 'dest'); | |
var logo = join(__dirname, 'resources/tlf-logo-medium.png'); |
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
$ brew install libmagic | |
$ brew link libmagic (if the link is already created is going to fail, don't worry about that) | |
$ env ARCHFLAGS="-arch x86_64" gem install ruby-filemagic -- --with-magic-include=/usr/local/include --with-magic-lib=/usr/local/lib/ |
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
python -m SimpleHTTPServer 8000 |
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 gulp = require('gulp'); | |
var uglify = require('gulp-uglify'); | |
var uglifycss = require('gulp-uglifycss'); | |
var less = require('gulp-less'); | |
var rjs = require('requirejs').optimize; | |
var concat = require('gulp-concat'); | |
var bower = require ('gulp-bower'); | |
var watch = require('gulp-watch'); | |
var batch = require('gulp-batch'); | |
var path = require('path'); |
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.adsbygoogle = window.adsbygoogle || []; | |
var async = ( typeof c != "undefined" && !_.isUndefined(c.script) ) ? c.sript : $.getScript; | |
async("//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"); | |
var GoogleAS = new Backbone.Model({ | |
id: 'GoogleAS', | |
client: 'pub-9565436045946419', | |
currentCount: 0, | |
maxSlots: 3, |
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 isURL = function isUrl(s) { | |
var regexp = /(ftp|http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@!\-\/]))?/ | |
console.info('Is URL ? ', regexp.test(s)); | |
return regexp.test(s); | |
}; |
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 Crop = { | |
elements: { | |
editor: null, | |
container: null, | |
slider: null, | |
img: null, | |
overlay: null, | |
preview: null | |
}, |
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 loadExistingTwigTemplate = function (templateId) { | |
return Twig.twig({ | |
ref: templateId | |
}); | |
}; | |
Marionette.TemplateCache.prototype.compileTemplate = function (template) { | |
switch (template.type) { | |
case 'twig/template': | |
// first, see if the template is already loaded |
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 CacheManager = window.CacheManager = function (storage) { | |
var name = ''; | |
if (typeof storage !== "string") { | |
throw new TypeError('The name of storage needs to be a character string.'); | |
} | |
name = _.capitalize(storage) + 'Storage'; |
NewerOlder