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 $ = require('gulp-load-plugins')(); | |
gulp.task('default', ['watchJs', 'watchTests']); | |
// make sure you do not start a path with ./ | |
// there's some bug in gaze that causes globs with ./ to not fire | |
var unitTestPaths = [ | |
'tests/**/*_tests.js' | |
]; |
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
Remove osxfuse if installed via homebrew: | |
> brew uninstall osxfuse | |
Install osxfuse binary and choose to install the MacFUSE compatibility layer: | |
http://sourceforge.net/projects/osxfuse/files/latest/download?source=files | |
Reboot (optional but recommended by osxfuse) | |
Install ntfs-3g via homebrew: | |
> brew update && brew install ntfs-3g |
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
// npm install --save-dev gulp gulp-babel babelify through2 gulp-rename gulp-load-plugins | |
var gulp = require('gulp'); | |
var $ = require('gulp-load-plugins')(); | |
var browserify = require('browserify'); | |
var through2 = require('through2'); | |
var babelify = require('babelify'); | |
var srcApp = './src/app.js'; | |
var srcWatchPath = './src/**/*.js' |
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
context.Database.ExecuteSqlCommand("sp_MSForEachTable 'ALTER TABLE ? NOCHECK CONSTRAINT ALL'"); | |
context.Database.ExecuteSqlCommand("sp_MSForEachTable 'IF OBJECT_ID(''?'') NOT IN (ISNULL(OBJECT_ID(''[dbo].[__MigrationHistory]''),0)) DELETE FROM ?'"); | |
context.Database.ExecuteSqlCommand("EXEC sp_MSForEachTable 'ALTER TABLE ? CHECK CONSTRAINT ALL'"); |
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/ruby | |
require 'date' | |
class Girl | |
def initialize(name, date_of_birth, weight_in_kg) | |
@name = name | |
@date_of_birth = date_of_birth | |
@weight_in_kg = weight_in_kg | |
end |
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
{ | |
// These are the old commands | |
//"cmd": ["ruby", "$file"], | |
//"cmd": ["/usr/local/bin/ruby", "$file"], | |
"cmd": ["/Users/kiwidev/.rbenv/shims/ruby", "$file"], | |
"file_regex": "^(...*?):([0-9]*):?([0-9]*)", | |
"selector": "source.ruby" | |
} |
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
from peewee import * | |
db = PostgresqlDatabase(None) | |
# custom type for postgres Text[] array column | |
class TextArrayField(Field): | |
db_field = 'Text[]' | |
def db_value(self, value): | |
return value |
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
# Start a basic, 4 node, local, ipython cluster, using: | |
# ipcluster start -n 4 | |
# | |
# then run: | |
# ipython parallel_process_images.py | |
# | |
# this example reads in ./test_images/*.jpg | |
# and outputs a bunch of .png files to ./resized_test_images/ |
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
(id="Content\w*") |
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
#!/bin/sh | |
xfce4-terminal \ | |
-T scratch \ | |
--working-directory=/opt/colors/ \ | |
-e 'env PROMPT_COMMAND="unset PROMPT_COMMAND; source ./_env/bin/activate; s . &" bash' \ | |
--tab -T pry \ | |
--working-directory=/opt/colors/ \ | |
-e 'env PROMPT_COMMAND="unset PROMPT_COMMAND; source ./_env/bin/activate; cd ./apps ; ./pry_with_models.sh" bash' \ | |
--window -T public_site \ | |
--working-directory=/opt/colors/ \ |
OlderNewer