Make sure to npm install github-flavored-markdown
in the mixin directory.
This file contains hidden or 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/local/bin/node | |
var spawn = require('child_process').spawn | |
, exists = require('path').exists | |
, pump = require('util').pump | |
, coffeePath = '/usr/local/bin/coffee'; | |
exists(coffeePath, function(ex) { | |
process.stdin.resume(); |
This file contains hidden or 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
class nodejs ( $version, $logoutput = 'on_failure' ) { | |
$nave_path = '/usr/local/bin/nave' | |
$nave_dir = '/usr/local/lib/nave' | |
package { 'bash': | |
ensure => present, | |
} | |
package { 'curl': | |
ensure => present, |
This file contains hidden or 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
class nginx ( $release = 'stable' ) { | |
$apt-base = '/etc/sources.list.d/nginx' | |
if !defined(Package["python-software-properties"]) { | |
package { "python-software-properties": | |
ensure => installed, | |
} | |
} | |
exec { 'add nginx repository' : |
This file contains hidden or 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
server { | |
server_name something.domain.com; | |
root /home/sites/something.domain.com/static; | |
client_max_body_size 2G; | |
location / { | |
try_files $uri @some_site; | |
} |
This file contains hidden or 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 http = require('http') | |
, fs = require('fs') | |
, out = {}; | |
[ 'process', 'stdio', 'util', 'fs', 'domain', 'net', 'http', 'https', 'tls', 'events', 'crypto', 'path', 'url', 'vm', 'querystring', 'os', 'tty', | |
'punycode', 'zlib', 'dns', 'dgram'].forEach(function(moduleName) { | |
var opts = { | |
host: 'nodejs.org' | |
, port: 80 | |
, path: '/api/' + moduleName + '.json' |
This file contains hidden or 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 isPrivateIP(ip) { | |
return ip.match(/^10\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})/) != null || | |
ip.match(/^192\.168\.([0-9]{1,3})\.([0-9]{1,3})/) != null || | |
ip.match(/^172\.16\.([0-9]{1,3})\.([0-9]{1,3})/) != null || | |
ip.match(/^127\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})/) != null || | |
ip.match(/^169\.254\.([0-9]{1,3})\.([0-9]{1,3})/) != null || | |
ip.match(/^fc00:/) != null || ip.match(/^fe80:/) != null; | |
} |
This file contains hidden or 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
/*! | |
* Strip Trailing Whitespace mixin for Chocolat | |
* Copyright(c) 2012 Nicholas Penree <[email protected]> | |
* MIT Licensed | |
*/ | |
/** | |
* Hook up menu items. | |
*/ |
This file contains hidden or 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
/*! | |
* Convert to JS Array mixin for Chocolat | |
* Copyright(c) 2012 Nicholas Penree <[email protected]> | |
* MIT Licensed | |
*/ | |
/** | |
* Hook up menu items. | |
*/ |
This file contains hidden or 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
/*! | |
* Transmit 4 mixin for Chocolat | |
* Copyright(c) 2012 Nicholas Penree <[email protected]> | |
* MIT Licensed | |
*/ | |
/** | |
* Module dependencies. | |
*/ |