Skip to content

Instantly share code, notes, and snippets.

View sstadelman's full-sized avatar
🚀

Stan Stadelman sstadelman

🚀
View GitHub Profile
@sstadelman
sstadelman / Activity.swift
Created August 20, 2018 20:54 — forked from zwaldowski/Activity.swift
os_activity_t for Swift 3
//
// Activity.swift
//
// Created by Zachary Waldowski on 8/21/16.
// Copyright © 2016 Zachary Waldowski. Licensed under MIT.
//
import os.activity
private final class LegacyActivityContext {
import Foundation
// Inspired by https://gist.github.com/mbuchetics/c9bc6c22033014aa0c550d3b4324411a
struct JSONCodingKeys: CodingKey {
var stringValue: String
init?(stringValue: String) {
self.stringValue = stringValue
}
# python3 version, derived from python2 version https://gist.github.com/dergachev/7028596
#
# taken from http://www.piware.de/2011/01/creating-an-https-server-in-python/
# generate server.xml with the following command:
# openssl req -new -x509 -keyout server.pem -out carthageserver.pem -days 365 -nodes
# run as follows:
# python3 simple-https-server.py
# then in your browser, visit:
# https://localhost:443
@sstadelman
sstadelman / git-selective-merge.md
Created February 12, 2018 17:20 — forked from katylava/git-selective-merge.md
git selective merge

Example: You have a branch refactor that is quite different from master. You can't merge all of the commits, or even every hunk in any single commit or master will break, but you have made a lot of improvements there that you would like to bring over to master.

Standard docs: here

Note: This will not preserve the original change authors. Only use if necessary, or if you don't mind losing that information, or if you are only merging your own work.

On master:

@sstadelman
sstadelman / case.json
Last active August 29, 2015 14:22 — forked from d3noob/.block
{
"links" : [
{"source": "5530bcc5298d000e396ff280", "target": "5530bd47298d000e396ff281"},
{"source": "5530bd47298d000e396ff281", "target": "5530bd83298d000e396ff282"},
{"source": "5530bd47298d000e396ff281", "target": "5530bdcb298d000e396ff283"},
{"source": "5530bd83298d000e396ff282", "target": "5530be68298d000e396ff285"},
{"source": "5530bdcb298d000e396ff283", "target": "5530bd83298d000e396ff282"},
{"source": "5530bdcb298d000e396ff283", "target": "5530be28298d000e396ff284"},
{"source": "5530be28298d000e396ff284", "target": "5530bd83298d000e396ff282"},
{"source": "5530be28298d000e396ff284", "target": "5530be93298d000e396ff286"}