Skip to content

Instantly share code, notes, and snippets.

View skyofdwarf's full-sized avatar

김영중 skyofdwarf

View GitHub Profile
@helje5
helje5 / main.swift
Last active January 12, 2022 18:44
Using async/await concurrency on iOS 14 and before
// Created by Helge Heß 2021-06-17
import Foundation
// They use obfuscated names to hide it from us!
import JavaScriptCore
/// Setup our async/await runtime.
let runtime = JSContext()!
@jls21
jls21 / How to run devices with new iOS version on old Xcode
Last active April 10, 2024 10:33
How to run devices with new iOS version on old Xcode
If you are having device with new iOS version(iOS 10.3 for example), but don't wanna to update XCode 8.2.1.
It's very simple to run application on new iOS with old XCode.
Check this out.
Follow the steps:
1. Download .dmg file with new XCode from apple developer portal (https://developer.apple.com/download/more/).
2. Keep your old XCode and unarchive new XCode from .dmg file.
3. Goto (New XCode path)/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport and copy folder with new iOS
4. Paste it to (Old XCode path)/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
@marcoconti83
marcoconti83 / Guard-catch.swift
Created October 29, 2015 23:46
Guard-catch in swift?
/**
# QUESTION
Is there a way to combine `guard` and `try-catch`, so that we can
exploit the `guard let` to have a immutable value, but have an early
return in case of errors?
*/
@serveba
serveba / openssl_commands
Last active September 4, 2017 05:25
base64 encode/decode, encrypt/decrypt, md5, sha1
#Just base64 encode a binary file:
openssl base64 -in file.bin -out file.b64
#Decode the same file
openssl base64 -d -in file.b64 -out file.bin
#Encrypt a file using triple DES in CBC mode using a prompted password:
openssl des3 -salt -in file.txt -out file.des3
#Decrypt a file using a supplied password:
@staltz
staltz / introrx.md
Last active June 29, 2024 15:58
The introduction to Reactive Programming you've been missing
@Kentzo
Kentzo / gist:1985919
Created March 6, 2012 12:16
Declaration of CGFLOAT_EPSILON which represents epsilon of CGFloat depending or arch.
#ifndef CGFLOAT_EPSILON
#if CGFLOAT_IS_DOUBLE
#define CGFLOAT_EPSILON DBL_EPSILON
#else
#define CGFLOAT_EPSILON FLT_EPSILON
#endif
#endif