(from Understanding Nginx Server and Location Block Selection Algorithms - https://goo.gl/YyzshP)
server {
(from Understanding Nginx Server and Location Block Selection Algorithms - https://goo.gl/YyzshP)
server {
##Sass Functions Cheat Sheet
Install on OS X: sudo gem install sass
Version info: sass -v
These rules are adopted from the AngularJS commit conventions.
Magic words:
psql -U postgres
Some interesting flags (to see all, use -h
or --help
depending on your psql version):
-E
: will describe the underlaying queries of the \
commands (cool for learning!)-l
: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)/** | |
* Example : | |
* var a = [2,7,9]; | |
* binaryInsert(8, a); | |
* | |
* It will output a = [2,7,8,9] | |
* | |
*/ | |
function binaryInsert(value, array, startVal, endVal){ |
git branch -m old_branch new_branch # Rename branch locally | |
git push origin :old_branch # Delete the old branch | |
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote |
var | |
// Local ip address that we're trying to calculate | |
address | |
// Provides a few basic operating-system related utility functions (built-in) | |
,os = require('os') | |
// Network interfaces | |
,ifaces = os.networkInterfaces(); | |
// Iterate over interfaces ... |
/* | |
http://stackoverflow.com/questions/4915462/how-should-i-do-floating-point-comparison | |
*/ | |
var EPSILON = 0.000001; | |
function fp_less_than(A, B, Epsilon) { | |
Epsilon = Epsilon || EPSILON; | |
return (A - B < Epsilon) && (Math.abs(A - B) > Epsilon); | |
}; |
In addition to the charts that follow, you might want to consider the Frequently Asked Questions section for a selection of common questions about MongoDB.
The following table presents the MySQL/Oracle executables and the corresponding MongoDB executables.