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
import Foundation | |
// This can go in its own separate swift file - just keeping it here for reference.. | |
struct MyModel { | |
let name: String | |
let email: String | |
static func create( name: String, email: String ) -> MyModel { | |
return MyModel( name: name, email: email ) | |
} |
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
## | |
# Below are the steps taken to install the GuestAdditions on a VirtualBox Centos 6.5 Instance. This was done to setup sharing between Mac OSX and CentOS 6.5. | |
# | |
# Login to the GUEST ( your actual VirtualBox CentOS Instance ), update `yum` and install the necessary packages | |
# | |
## | |
yum update | |
yum --enablerepo rpmforge install dkms | |
yum --enablerepo rpmforge install dkms |
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
// Creating method from code found here: https://gist.github.com/bennadel/9751583#file-code-4-js | |
// Used with jsperf | |
var _charArr = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "{", "}", "|", ":", "\"", "<", ">", "?", "~", "!", "@", "#", "$", "%", "&", "^", "&", "*", "(", ")", "_", "+", " ", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "`", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "-", "=", "[", "]", "\\", ";", "'", ",", ".", "/"]; | |
var randomStr( maxLen ) { | |
var rndKey = 0; | |
var str = ""; | |
var i; |
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
# Source global definitions | |
if [ -f /etc/bashrc ]; then | |
. /etc/bashrc | |
fi | |
# Path to where the scripts being included below live. Update this to reflect your own paths.. | |
# In this example, we will assume there is a tools folder in your $HOME folder... | |
TOOLS_PATH=$HOME/tools | |
# Force vi to be vim |
NewerOlder