DO's:
- Use explicit contracts to pipe data & events between systems
- Business rules should bubble towards the top, UI and semantics should sink towards the bottom
DONT's:
| { | |
| // The command to execute for the terminal, leave blank for the OS default | |
| // On OS X the terminal can be set to iTerm.sh to execute iTerm | |
| "terminal": "C:\\Tools\\cmder\\Cmder.exe", | |
| // A list of default parameters to pass to the terminal, this can be | |
| // overridden by passing the "parameters" key with a list value to the args | |
| // dict when calling the "open_terminal" or "open_terminal_project_folder" | |
| // commands | |
| "parameters": ["/START", "%CWD%"] |
| # Hello, and welcome to makefile basics. | |
| # | |
| # You will learn why `make` is so great, and why, despite its "weird" syntax, | |
| # it is actually a highly expressive, efficient, and powerful way to build | |
| # programs. | |
| # | |
| # Once you're done here, go to | |
| # http://www.gnu.org/software/make/manual/make.html | |
| # to learn SOOOO much more. |
| // this setup assumes you are using gulp-config for file.src & file.dest | |
| // but can be adapted to vanilla easily. | |
| 'use strict'; | |
| var transform = require('vinyl-transform'), | |
| browserify = require('browserify'), | |
| watchify = require('watchify'), | |
| // consider using gulp-load-plugins |
| var gulp = require('gulp'); | |
| var browserify = require('browserify'); | |
| var notify = require('gulp-notify'); | |
| var source = require('vinyl-source-stream'); | |
| var watchify = require('watchify'); | |
| var plumber = require('gulp-plumber'); | |
| var less = require('gulp-less'); | |
| var csso = require('gulp-csso'); | |
| var watch = require('gulp-watch'); | |
| var envify = require('envify'); |
| # mimic osx pbcopy/pbpaste | |
| alias pbcopy="xclip -selection clipboard -i" | |
| alias pbpaste="xclip -selection clipboard -o" |
| # | |
| # CORS header support | |
| # | |
| # One way to use this is by placing it into a file called "cors_support" | |
| # under your Nginx configuration directory and placing the following | |
| # statement inside your **location** block(s): | |
| # | |
| # include cors_support; | |
| # | |
| # As of Nginx 1.7.5, add_header supports an "always" parameter which |
| // USAGE ------ | |
| // ============ | |
| var shell = require('./shellHelper'); | |
| // execute a single shell command | |
| shell.exec('npm test --coverage', function(err){ | |
| console.log('executed test'); | |
| }}); |