# enable internal menu
defaults write com.apple.dt.Xcode ShowDVTDebugMenu -bool YES
alias xcbuild=$(xcode-select -p)/../SharedFrameworks/XCBuild.framework/Versions/A/Support/xcbuild
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
{ | |
"beers" : [ | |
{ | |
"brewery" : { | |
"id" : 1, | |
"name" : "(512) Brewing Company" | |
}, | |
"id" : 1, | |
"created_at" : "2010-12-07T02:53:38Z", | |
"abv" : 6, |
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 UIKit | |
import XCPlayground | |
import Foundation | |
func makeArr(n: Int) -> [Int] { | |
var res = [Int]() | |
for _ in 0..<n { | |
res.append(Int(arc4random_uniform(10000) + 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
// Write three functions that compute the sum of the numbers in a given list using a for-loop, a while-loop. | |
// Part 2 | |
var series = [1, 2, 3, 4, 5, 6] | |
let realSum = series.reduce(0,{$0 + $1}) | |
// Normal Closure | |
var timesTenClosure: (Int) -> Int = { $0 * 10 } | |
// Problem 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
# platform :ios, '10.0' | |
use_frameworks! | |
target 'combat' do | |
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks | |
# Pods for combat | |
pod 'Alamofire', :git => 'https://github.com/Alamofire/Alamofire.git', :tag => ‘4.4.0’ | |
pod 'PINRemoteImage', '~> 2.1' | |
pod 'BRYXBanner', :git => 'https://github.com/bryx-inc/BRYXBanner.git', :tag => ‘0.7.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
// | |
// ThemeManager.swift | |
import UIKit | |
import Foundation | |
/// Enum Theme Manager | |
/// - Note: https://github.com/durul/DRL-Theme-Manager | |
enum Theme: Int { | |
Install HomeBrew first
brew update
brew tap caskroom/cask
brew install brew-cask
If you get the error "already installed", follow the instructions to unlink it, then install again:
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
#!/usr/bin/env sh | |
# checks to see if running | |
launchctl list | grep mongo | |
launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.mongodb.plist | |
launchctl remove homebrew.mxcl.mongodb | |
pkill -f mongod |
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
[merge] | |
keepBackup = false | |
tool = custom | |
[mergetool "custom"] | |
cmd = /Applications/p4merge.app/Contents/Resources/launchp4merge "$PWD/$BASE" "$PWD/$REMOTE" "$PWD/$LOCAL" "$PWD/$MERGED" | |
keepTemporaries = false | |
trustExitCode = false | |
keepBackup = false |
OlderNewer