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
brew update | |
brew versions FORMULA | |
cd `brew --prefix` | |
git checkout HASH Library/Formula/FORMULA.rb # use output of "brew versions" | |
brew install FORMULA | |
brew switch FORMULA VERSION | |
git checkout -- Library/Formula/FORMULA.rb # reset formula | |
## Example: Using Subversion 1.6.17 | |
# |
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
<div class="fade" ng-class="{in:someData.length}"> | |
I'm not visible until someData is there! | |
</div> |
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
SET FOREIGN_KEY_CHECKS = 1; | |
DROP TABLE IF EXISTS `User3s`; | |
CREATE TABLE IF NOT EXISTS `User3s` (`username` VARCHAR(255), `id` INTEGER NOT NULL auto_increment , `createdAt` DATETIME NOT NULL, `updatedAt` DATETIME NOT NULL, PRIMARY KEY (`id`)) ENGINE=InnoDB; | |
DROP TABLE IF EXISTS `Task3s`; | |
CREATE TABLE IF NOT EXISTS `Task3s` (`title` VARCHAR(255), `id` INTEGER NOT NULL auto_increment , `createdAt` DATETIME NOT NULL, `updatedAt` DATETIME NOT NULL, `User3Id` INTEGER, PRIMARY KEY (`id`), FOREIGN KEY (`User3Id`) REFERENCES `User3s` (`id`) ON DELETE RESTRICT) ENGINE=InnoDB; | |
INSERT INTO `User3s` (`username`,`id`,`createdAt`,`updatedAt`) VALUES ('foo',NULL,'2013-07-23 06:55:35','2013-07-23 06:55:35'); | |
INSERT INTO `Task3s` (`title`,`id`,`createdAt`,`updatedAt`,`User3Id`) VALUES ('task',NULL,'2013-07-23 06:55:35','2013-07-23 06:55:35',NULL); | |
SELECT * FROM `Task3s` WHERE `User3Id` = '1' AND `User3Id` = '1' LIMIT 1; | |
UPDATE `Task3s` SET `title`='task',`id`=1,`createdAt`='2013-07-23 06:55:35',`updatedAt`='2013-07-23 06:55:35 |
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
MacBook-Pro sequelize → λ git master → npm install | |
npm WARN package.json [email protected] No repository field. | |
> [email protected] install /Users/daniel/github/sequelize/node_modules/ref | |
> node-gyp rebuild | |
gyp http GET http://nodejs.org/dist/v0.11.2/node-v0.11.2.tar.gz | |
gyp http 200 http://nodejs.org/dist/v0.11.2/node-v0.11.2.tar.gz | |
CXX(target) Release/obj.target/binding/src/binding.o | |
../src/binding.cc:122:45: warning: 'New' is deprecated [-Wdeprecated-declarations] |
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/bin/env bash | |
if [ $# -lt 2 ] | |
then | |
echo "Usage: hat [hat directory] [hat] [output directory]" | |
exit 1 | |
fi | |
if [ $# -lt 3 ] | |
then | |
dir=$HOME/.hat/ |
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/bin/env bash | |
PROJ_NAME="" | |
PROJ_GIT_DIR="" | |
PROJ_DIR="" | |
PROJ_ROOT="" | |
PROJ_GIT_ROOT="" | |
PWD=$(pwd) | |
function set_config_vars () { |
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
/* | |
--- | |
name: guilloche | |
script: guilloche.js | |
description: guilloche | |
provides: [Guilloche] | |
... | |
*/ |
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/bin/env ruby | |
# Made by Pieter de Bie <[email protected]> | |
# Based on a "Pastie" task by someone | |
require "tempfile" | |
GIST_URL = 'http://gist.github.com/gists' | |
GIST_LOGIN_URL = 'https://gist.github.com/session' | |
USERNAME = "martinisoft" | |
TOKEN = "6ef8395fecf207165f1a82178ae1b984" |
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 data = sequelize.define('NativeDataType', { | |
aBoolean3: Sequelize.BOOLEAN, | |
aBoolean4: {type: Sequelize.BOOLEAN} | |
}) | |
console.log(data); |
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
$ git log | tail -n5 | |
commit 5e3aa42c84bbd7c82b1d0b595ca13b49d3a6e8bf | |
Author: James Halliday <[email protected]> | |
Date: Wed Mar 13 15:16:33 2013 -0700 | |
happstack article | |
$ git filter-branch --env-filter 'if [ "$GIT_COMMIT" = "5e3aa42c84bbd7c82b1d0b595ca13b49d3a6e8bf" ]; then GIT_AUTHOR_DATE="2009-10-25 09:59:47 UTC"; fi' | |
Rewrite 85a994a56fc0fae5c9f082b1e2dbb2ee8ee23ceb (7/7) | |
Ref 'refs/heads/master' was rewritten |