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/python | |
#---------------------------------------------------------------------- | |
# Be sure to add the python path that points to the LLDB shared library. | |
# | |
# # To use this in the embedded python interpreter using "lldb" just | |
# import it with the full path using the "command script import" | |
# command | |
# (lldb) command script import /path/to/dot.py | |
#---------------------------------------------------------------------- |
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
==> MachTimer.h <== | |
// | |
// MachTimer | |
// Tout | |
// | |
// Code sourced from http://zpasternack.org/high-resolution-timing-in-cocoa/ | |
// | |
#import <Foundation/Foundation.h> | |
#include <mach/mach_time.h> |
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 ruby | |
$: << File.expand_path(File.dirname(File.realpath(__FILE__)) + './../lib') | |
require 'gli' | |
require 'version' | |
require 'versionomy' | |
include GLI::App | |
#version Version::VERSION |
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
// Based on https://github.com/T-Pham/NoOptionalInterpolation | |
import Foundation | |
public | |
protocol Unwrappable | |
{ | |
func unwrap() -> Any? | |
} |
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
UIViewController<SomeProtocol> *vc = ...; | |
/** I wish I could do this in Swift. | |
let vc: UIViewController, SomeProtocol = ... | |
*/ |
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
// | |
// KeychainItem.swift | |
// | |
// Created by David Whetstone on 9/28/19. | |
// | |
// Original code by Chris Eidhof | |
// https://github.com/objcio/keychain-item | |
// As yet unlicensed |
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 SwiftUI | |
struct ContentView: View { | |
var body: some View { | |
WrapperView { | |
VStack { | |
PrefView() | |
PrefView() | |
} | |
} |
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
george |
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
on run {filepath, linenumber, columnnumber} | |
tell application "Visual Studio" to activate | |
tell application "System Events" | |
-- ⌘O File → Open... | |
keystroke "o" using command down | |
delay 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
public | |
extension Sequence | |
{ | |
/// Returns a Dictionary using the result of `keySelector` as the key, and the result of `valueTransform` as the value | |
public func associateBy<T, K: Hashable, V>(_ keySelector: (T) -> K, _ valueTransform: (T) -> V) -> [K:V] where T == Iterator.Element | |
{ | |
var dict: [K:V] = [:] | |
for element in self { | |
dict[keySelector(element)] = valueTransform(element) | |
} |
OlderNewer