Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
# To have launchd start mongodb at login: | |
ln -sfv /usr/local/opt/mongodb/*.plist ~/Library/LaunchAgents | |
# Then to load mongodb now: | |
launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mongodb.plist | |
# Or, if you don't want/need launchctl, you can just run: | |
mongod --config /usr/local/etc/mongod.conf |
" _ _ " | |
" _ /|| . . ||\ _ " | |
" ( } \||D ' ' ' C||/ { % " | |
" | /\__,=_[_] ' . . ' [_]_=,__/\ |" | |
" |_\_ |----| |----| _/_|" | |
" | |/ | | | | \| |" | |
" | /_ | | | | _\ |" | |
It is all fun and games until someone gets hacked! |
var mongoose = require("mongoose"); | |
var ObjectId = mongoose.Schema.Types.ObjectId; | |
//create schema for a post | |
var PostSchema = new mongoose.Schema({ | |
nonce: ObjectId, //this is used for protecting against concurrent edits: http://docs.mongodb.org/ecosystem/use-cases/metadata-and-asset-management/ | |
name: String, | |
dateCreated: { type: Date, default: Date.now }, | |
dateLastChanged: { type: Date, default: Date.now }, | |
postData: mongoose.Schema.Types.Mixed |
apply plugin: 'groovy' | |
apply plugin: 'application' | |
startScripts.deleteAllActions() | |
jar { | |
manifest { | |
// Make sure the app's jar can be used with a simple -cp | |
attributes 'Class-Path': configurations.runtime.collect { "${it.getName()}" }.join(' ') | |
} |