Simple commits:
git replace --graft <TAIL_COMMIT_SHA> <TIP_COMMIT_SHA>
If tip is a merge commit:
git replace --graft <TAIL_COMMIT_SHA> <FIRST_PARENT_OF_TIP_MERGE_COMMIT_SHA> <SECOND_PARENT_OF_TIP_MERGE_COMMIT_SHA>
Then:
/// Withable is a simple protocol to make constructing | |
/// and modifying objects with multiple properties | |
/// more pleasant (functional, chainable, point-free) | |
public protocol Withable { | |
init() | |
} | |
public extension Withable { | |
/// Construct a new instance, setting an arbitrary subset of properties | |
init(with config: (inout Self) -> Void) { |
Simple commits:
git replace --graft <TAIL_COMMIT_SHA> <TIP_COMMIT_SHA>
If tip is a merge commit:
git replace --graft <TAIL_COMMIT_SHA> <FIRST_PARENT_OF_TIP_MERGE_COMMIT_SHA> <SECOND_PARENT_OF_TIP_MERGE_COMMIT_SHA>
Then:
public class GUIScreenLoader | |
{ | |
private Transform container; | |
private MainNavGUIConfig config; // a ScriptableObject with a list of easily editable components | |
// it also contains a GUI Scene reference, for more control over | |
// resource loading. | |
public GUIScreenLoader(MainNavGUIConfig config, Transform container) | |
{ | |
this.config = config; |
[ | |
{ | |
"timezones": [ | |
"America/Aruba" | |
], | |
"latlng": [ | |
12.5, | |
-69.96666666 | |
], | |
"name": "Aruba", |
extension Dictionary { | |
public func map<T: Hashable, U>(@noescape transform: (Key, Value) -> (T, U)) -> [T: U] { | |
var result: [T: U] = [:] | |
for (key, value) in self { | |
let (transformedKey, transformedValue) = transform(key, value) | |
result[transformedKey] = transformedValue | |
} | |
return result | |
} | |
Update: https://github.com/phracker/MacOSX-SDKs hosts the direct SDK folders already extracted.
Xcode 4.3.3
Show Package Content
/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
git branch -m old_branch new_branch # Rename branch locally | |
git push origin :old_branch # Delete the old branch | |
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote |
using System; | |
using UnityEngine; | |
using UnityEditor; | |
public class CreateQuadMesh : Editor { | |
[MenuItem("Assets/Create/Quad Mesh", false, 10000)] | |
public static void Create () | |
{ | |
Mesh mesh = BuildQuad (1, 1); |
#!/bin/bash | |
if [ "$1" = "-h" -o "$1" = "--help" -o -z "$1" ]; then cat <<EOF | |
appify v3.0.1 for Mac OS X - http://mths.be/appify | |
Creates the simplest possible Mac app from a shell script. | |
Appify takes a shell script as its first argument: | |
`basename "$0"` my-script.sh |