Skip to content

Instantly share code, notes, and snippets.

View bell-jamesl's full-sized avatar

James Laurenstin bell-jamesl

View GitHub Profile
@Edudjr
Edudjr / prettyPrint.swift
Created February 9, 2017 12:45
Swift 3 JSON pretty printing
//Function to pretty-print Json Object in Swift 3
func prettyPrint(with json: [String:Any]) -> String{
let data = try! JSONSerialization.data(withJSONObject: json, options: .prettyPrinted)
let string = NSString(data: data, encoding: String.Encoding.utf8.rawValue)
return string as! String
}
@mbinna
mbinna / podforceupdate.sh
Created December 4, 2012 09:43
Clear CocoaPods cache, re-download and re-install all pods
#!/usr/bin/env bash
rm -rf "${HOME}/Library/Caches/CocoaPods"
rm -rf "`pwd`/Pods/"
pod update