- Open Spotlight Search:
command + spacebar
- Create terminal tab:
command + t
- Close terminal Tab:
command + w
- Switch terminal Tab:
command + shift + arrow_keys
ORcommand + shift + { or }
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
/*============================================================================= | |
Description: A thread safe queue using boost::mutex library to do so. | |
Author: J. Nolan Hager (JNHager) | |
NOTE (JNhager): boost::mutext::scoped_lock locks all resources in the same | |
scope until that scope has resolved. This means all scopes within will be | |
locked as well. | |
=============================================================================*/ |
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
/*============================================================================= | |
Description: A javascript file full of some helpers I come across as I code | |
through daily life. | |
Author: J. Nolan Hager (JNHager) | |
=============================================================================*/ | |
(function(exports){ | |
exports.jshlprs = { | |
isEmptyObj: function(obj){ return !Object.keys(obj).length; } | |
} |
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
(function(exports){ | |
layouts = { | |
'layoutName':'url-for-layout' | |
} | |
exports.layoutHelper = { | |
getLayout: function(layoutName){ | |
var layoutObj = ''; | |
$.ajax({ | |
url: layouts[layoutName], |
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 express = require('express'); | |
var fs = require('fs'); | |
var path = require('path'); | |
var port = 3005; | |
var staticDir = "staticFiles" | |
var app = express(); | |
app.use(function (req, res, next) { | |
//NOTE (JNHager): NEVER DO THIS IN A PRODUCTION SYSTEM. STRICTLY FOR TESTING LOCALLY!!!! |
- List branches that are already merged. (Found this here: [Stackoverflow post][merged_branches])
git branch --merged master #lists branches merged into master git branch --merged lists #branches merged into HEAD (i.e. tip of current branch) git branch --no-merged #lists branches that have not been merged
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 moment = require('moment'); | |
var _dateFormats = { | |
short: "MMMM DD, YYYY", | |
long: "dddd DD.MM.YYYY HH:mm" | |
}; | |
var barsHlprs = {}; | |
barsHlprs.ifIn = function (elem, list, options) { |
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
def twoDim_deep_copy(srcArray, destArray): | |
destArray = [row[:] for row in srcArray] |
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
String.prototype.repeat = string.prototype.repeat || function (rptCnt) { | |
return new Array(rptCnt).join(this); | |
}; |
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
export PS1="\[\033[36m\]\u\[\033[m\]@\[\033[32m\]\h:\[\033[33;1m\]\w\[\033[m\]\$(parse_git_branch)\[\033[00m\]\$ " | |
export CLICOLOR=1 | |
export LSCOLORS=DxFxBxDxCxegedabagacad | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' | |
} | |
OlderNewer