brew install mongodb
Set up launchctl to auto start mongod
$ ln -sfv /usr/local/opt/mongodb/*.plist ~/Library/LaunchAgents
/usr/local/opt/mongodb/
is a symlink to /usr/local/Cellar/mongodb/x.y.z
(e.g., 2.4.9
)
// For Firefox's Web Console, creates the functions showAsPrint() and undoShowAsPrint() | |
// to roughly emulate print media and revert | |
function showAsPrint(){ | |
var docSS = document.styleSheets, ss, oldMedia, newMedia, rules; | |
var p2s = function(media){ | |
if (media.indexOf('all') > -1) return media; //no need to change | |
if (media == 'print') return 'all, wasprint'; //show on screen, too | |
if (media.indexOf('print') > -1 && media.indexOf('screen') > -1) return media; //no need to change | |
if (media == 'screen') return 'wasscreen'; //hide these rules | |
if (media.indexOf('screen') > -1) return media.replace('screen', 'wasscreen'); //hide these rules |
// config/env/development.js | |
/** | |
* Development environment settings | |
* | |
* This file can include shared settings for a development team, | |
* such as API keys or remote database passwords. If you're using | |
* a version control solution for your Sails app, this file will | |
* be committed to your repository unless you add it to your .gitignore | |
* file. If your repository will be publicly viewable, don't add | |
* any private information to this file! |
IE6 Only | |
================== | |
_selector {...} | |
IE6 & IE7 | |
================== | |
*html or { _property: } | |
IE7 Only | |
================== |
/*! | |
* from: http://stackoverflow.com/questions/7127600/which-jquery-plugin-design-pattern-should-i-use | |
*/ | |
(function ($) { | |
// the constructor | |
var MyClass = function (node, options) { | |
// node is the target | |
this.node = node; |
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
package main | |
import ( | |
"fmt" | |
"io" | |
"os" | |
) | |
var path = "/Users/novalagung/Documents/temp/test.txt" |
function genEmail(){ | |
var nouns = ["man", "world", "hand", "room", "face", "thing", "place", "door", "woman", "house", "money", "father", "government", "country", "mother", "water", "state", "family", "voice", "fact", "moment", "power", "city", "business", "war", "school", "system", "car", "number", "office", "point", "body", "wife", "air", "mind", "girl", "home", "company", "table", "group", "boy", "problem", "bed", "death", "hair", "child", "sense", "job", "light", "question", "idea", "law", "word", "party", "food", "floor", "book", "reason", "story", "son", "heart", "friend", "interest", "right", "town", "history", "land", "program", "game", "control", "matter", "policy", "oil", "window", "nation", "position", "ground", "blood", "action", "wall", "street", "husband", "fire", "mouth", "arm", "sound", "service", "chance", "information", "price", "building", "road", "paper", "court", "attention", "space", "trouble", "form", "society", "art", "market", "force", "effect", "nature", "chair", "period", "order", "t |
#hero { width:100%;height:100%;background:url('{$img_ps_dir}cms/how-it-works/hero.jpg') no-repeat top center; } | |
.videoWrapper { position:relative;padding-bottom:56.25%;padding-top:25px;max-width:100%; } | |
@media (min-width:1000px) { | |
#hero { background-size:cover; } | |
} | |
@media (max-width:767px) { | |
#hero { width:100%;height:94%!important;background:url('{$img_ps_dir}cms/how-it-works/hero-mobile.jpg') no-repeat top center;background-position: 0 -155px;height: 273px!important;background-position:0 -209px; } | |
} | |
@media (max-width:540px) { |
<?php | |
/* | |
OCP - Opcache Control Panel (aka Zend Optimizer+ Control Panel for PHP) | |
Author: _ck_ (with contributions by GK, stasilok) | |
Version: 0.1.6 | |
Free for any kind of use or modification, I am not responsible for anything, please share your improvements | |
* revision history | |
0.1.6 2013-04-12 moved meta to footer so graphs can be higher and reduce clutter | |
0.1.5 2013-04-12 added graphs to visualize cache state, please report any browser/style bugs |