Skip to content

Instantly share code, notes, and snippets.

View How to link Sublime Text Build system to Python 3
@hlung
hlung / keyboardHeightObservable.swift
Last active May 12, 2020 — forked from laurilehmijoki/keyboardHeightObservable.swift
RxSwift Observable on iOS keyboard height. Updated from original. Changelog below.
View keyboardHeightObservable.swift
import RxSwift // Version 3.2.0
import RxCocoa // Version 3.2.0
typealias KeyboardHeightInfo = (CGFloat, TimeInterval)
func keyboardHeight() -> Driver<KeyboardHeightInfo> {
return Observable
.from([
NotificationCenter.default.rx.notification(NSNotification.Name.UIKeyboardWillShow)
.map { notification -> KeyboardHeightInfo in
@hlung
hlung / fix-xcode-sdk
Last active Dec 24, 2015 — forked from rnapier/fix-xcode
More verbose print and check to process only *.platform folders.
View fix-xcode-sdk
#!/usr/bin/python
# fix-xcode-sdk
# Rob Napier <robnapier@gmail.com>
# Forked by Thongchai Kolyutsakul <thongchaikol@gmail.com>
# (https://gist.github.com/hlung/6806651)
# Script to link in all your old SDKs every time you upgrade Xcode
# Create a directory called /SDKs (or modify source_path).
# Under it, put all the platform directories: