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
Vagrant.configure("2") do |config| | |
config.vm.box = "ubuntu/bionic64" | |
config.vm.network "forwarded_port", guest: 80, host: 8080 | |
config.vm.network "forwarded_port", guest: 443, host: 443 | |
config.vm.network "forwarded_port", guest: 2222, host: 2222 | |
config.vm.network "forwarded_port", guest: 4567, host: 4567 | |
config.vm.synced_folder "./conf", "/etc/gitlab" | |
config.vm.synced_folder "./docker", "/home/vagrant/docker" |
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
language: node_js | |
node_js: | |
- "4.2.1" | |
sudo: required | |
dist: trusty | |
before_install: | |
- mkdir -p gnatsd | |
- "wget https://github.com/nats-io/gnatsd/releases/download/v0.6.4/gnatsd-v0.6.4-linux-amd64.tar.gz -qO - | tar -zxvC gnatsd/" | |
- export PATH=$PATH:$PWD/gnatsd/ | |
- gnatsd& |
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
{ | |
"states" = [ | |
{ | |
"abbreviation": "AL", | |
"capital": "Montgomery", | |
"zip": 36101 | |
}, | |
{ | |
"abbreviation": "AK", | |
"capital": "Juneau", |
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
return { | |
encapsulate: function(o) { | |
function process(prop, key) { | |
var primary = prop[key]; | |
if (!Array.isArray(prop[key])) { | |
for (var i in primary) { | |
if (primary[i] !== null && typeof primary[i] === 'object') { | |
process(primary, i); | |
} else if (typeof primary[i] !== 'function') { | |
var secondary = primary[i]; |
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 generateAddress (obj) { | |
var odds = Math.floor(Math.random() * 999) + 1, | |
multiplier = '', | |
streetLength = Math.floor(Math.random() * 5 + 1), | |
streetNumber = '', | |
apartmentTypes = ['Unit', 'Apt.', 'Suite'], | |
apartmentLetters = ['A','B','C','D','E','F','G'], | |
apartmentLetter = '', | |
apartmentType = '', | |
apartmentNumber = '', |
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
/** | |
* Checks to see if a given string ends with a particular file extension | |
* @param {string} f String representing a possible file name with extension | |
* @param {string} e The sought extension | |
* @returns {boolean} | |
*/ | |
function hasExtension (f, e) { | |
if (e[0] !== '.') { | |
e = '.' + e; | |
} |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. |
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
// Slides | |
var divSlider = function () { | |
var ds = this; | |
var transitionClass = "ds-faded"; | |
ds.n = 0; | |
ds.pause = function () { clearInterval(ds._intervalId); } | |
ds.toggle = function () { | |
console.log(ds.n, ds.slides.length-1); | |
ds.n < ds.slides.length-1 ? ds.n++ : ds.n = 0; | |
var prev = ds.n; |
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 strict'; | |
var PLUGIN_NAME = 'gulp-compass', | |
spawn = require('child_process').spawn, | |
gutil = require('gulp-util'), | |
path = require('path'), | |
which = require('which').sync, | |
defaults = { | |
style: false, | |
comments: true, |
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
/* | |
* Base Gulp.js workflow | |
* for simple front-end projects | |
* author: Aaron John Schlosser | |
* url: http://www.aaronschlosser.com | |
*/ | |
var gulp = require("gulp"), | |
gutil = require("gulp-util"), | |
concat = require("gulp-concat"), |
NewerOlder