(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
# delete local tag '12345' | |
git tag -d 12345 | |
# delete remote tag '12345' (eg, GitHub version too) | |
git push origin :refs/tags/12345 | |
# alternative approach | |
git push --delete origin tagName | |
git tag -d tagName |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
#!/bin/sh | |
# Combined all static libaries in the current directory into a single static library | |
# It is hardcoded to use the i386, armv7, and armv7s architectures; this can easily be changed via the 'archs' variable at the top | |
# The script takes a single argument, which is the name of the final, combined library to be created. | |
# | |
# For example: | |
# => combine_static_libraries.sh combined-library | |
# | |
# Script by Evan Schoenberg, Regular Rate and Rhythm Software |
$ strings /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/sourcekitd.framework/Versions/Current/XPCServices/SourceKitService.xpc/Contents/MacOS/SourceKitService|grep source.lang.swift
source.lang.swift.keyword
source.lang.swift.pattern
source.lang.swift.syntaxtype.argument
source.lang.swift.syntaxtype.parameter
source.lang.swift.attribute.availability
source.lang.swift.decl.extension
source.lang.swift.decl.var.parameter
source.lang.swift.stmt.brace
protocol Initializable { | |
init() | |
} | |
class A : Initializable { | |
var content:String | |
required init() { | |
content = "TestContent" | |
} |
function logClass(target: any) { | |
// save a reference to the original constructor | |
var original = target; | |
// a utility function to generate instances of a class | |
function construct(constructor, args) { | |
var c : any = function () { | |
return constructor.apply(this, args); | |
} |
public extension CustomDebugStringConvertible { | |
var debugDescription: String { | |
return debugDescription() | |
} | |
func debugDescription(_ indentationLevel: Int = 0, includeType: Bool = true) -> String { | |
let indentString = (0..<indentationLevel).reduce("") { tabs, _ in tabs + "\t" } | |
var s: String |
Author: Chris Lattner
import Foundation | |
import SceneKit | |
let json = """ | |
{ | |
"position": [2.0, 5.0, 3.0], | |
"rotation": [0.0, 0.73, 0.0, 0.73] | |
} | |
""".data(using: .utf8)! |
//: Playground - noun: a place where people can play | |
import UIKit | |
var str = "Anonymous Class in Swift" | |
//https://stackoverflow.com/questions/24408068/anonymous-class-in-swift | |
//There is no equivalent syntax. | |
//Regarding equivalent techniques, theoretically you could use closures and define structs and classes inside them. |