This file contains 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
Go to your Cordova Project | |
Root Folder -> CordovaLib -> Right Click CordovaLib.xcodeproj -> Show Package Contents -> Open project.pbxproj | |
Replace all occurrences of (I had 4) | |
buildSettings = { | |
ALWAYS_SEARCH_USER_PATHS = NO;//in 2 out of 4 occurrences | |
"ARCHS[sdk=iphoneos*]" = armv7; | |
"ARCHS[sdk=iphoneos6.*]" = ( |
This file contains 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
# tmux cheat sheet | |
(C-x means ctrl+x, M-x means alt+x) | |
## Prefix key | |
The default prefix is C-b. If you (or your muscle memory) prefer C-b, you need to add this to `~/.tmux.conf`: | |
# remap prefix to Control + a |
This file contains 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
# editorconfig.org | |
root = true | |
[*] | |
charset = utf-8 | |
end_of_line = lf | |
insert_final_newline = true | |
trim_trailing_whitespace = true |
This file contains 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
socketServer.server.removeListener('request', socketServer.server.listeners('request')[0]); //Work around to disable CORS |
This file contains 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
# First install tmux | |
brew install tmux | |
# For mouse support (for switching panes and windows) | |
# Only needed if you are using Terminal.app (iTerm has mouse support) | |
Install http://www.culater.net/software/SIMBL/SIMBL.php | |
Then install https://bitheap.org/mouseterm/ | |
# More on mouse support http://floriancrouzat.net/2010/07/run-tmux-with-mouse-support-in-mac-os-x-terminal-app/ |
This file contains 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
sudo -s launchctl load -w /System/Library/LaunchDaemons/ftp.plist | |
sudo -s launchctl unload -w /System/Library/LaunchDaemons/ftp.plist |
This file contains 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 clone <repo-address> | |
git tag -l | |
git checkout <tag-name> | |
git branch -D master | |
git checkout -b master |
This file contains 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
sudo apt-get install build-essential libsqlite3-dev zlib1g-dev libncurses5-dev libgdbm-dev libbz2-dev libreadline5-dev libssl-dev libdb-dev | |
wget http://www.python.org/ftp/python/2.7.3/Python-2.7.3.tgz | |
tar -xzf Python-2.7.3.tgz | |
cd Python-2.7.3 | |
./configure --prefix=/usr --enable-shared | |
make | |
sudo make install |
This file contains 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
# quick update | |
alias upgrade='apt-get update && apt-get upgrade && apt-get clean' | |
# Extract most know archives with one command | |
extract () { | |
if [ -f $1 ] ; then | |
case $1 in | |
*.tar.bz2) tar xjf $1 ;; | |
*.tar.gz) tar xzf $1 ;; | |
*.bz2) bunzip2 $1 ;; |
This file contains 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
//FIND | |
dbSchemasName.ModelName.find({ 'key1': value1, 'key2': value2 }, function (err, resultFromDB) { | |
if(resultFromDB.length === 0) { | |
var model = { | |
key1: value1, | |
key2: value2 | |
}; | |
} | |
}); |