This library is now deprecated in favour of a more complete and SwiftUI friendly TextEditor backport:
https://github.com/shaps80/SwiftUIBackports
See it in action here: https://twitter.com/shaps/status/1654972428286668800?s=20
| // See commentary below this gist. | |
| import Foundation | |
| import QuartzCore | |
| // Implementation from https://talk.objc.io/episodes/S01E90-concurrent-map | |
| public final class ThreadSafe<A> { | |
| var _value: A | |
| let queue = DispatchQueue(label: "ThreadSafe") | |
| init(_ value: A) { self._value = value } |
| #!/bin/bash | |
| # Non-scripted Tasks: | |
| # - Configure device name in Preferences > Sharing | |
| # - Enable Remote Login & Remote Management in Preferences > Sharing | |
| # - Enable automatic login/disable password after sleep in Preferences > Security & Privacy > General | |
| # - Disable screensaver/sleep in Preferences > Energy Saver | |
| # - Disable spotlight indexing of home directory | |
| # - Add a runner in GitHub UI to grab your token https://github.com/<org>/<repo>/settings/actions/runners/new |
This library is now deprecated in favour of a more complete and SwiftUI friendly TextEditor backport:
https://github.com/shaps80/SwiftUIBackports
See it in action here: https://twitter.com/shaps/status/1654972428286668800?s=20
| import UIKit | |
| import MobileCoreServices.UTCoreTypes | |
| if #available(iOS 14.1, *) { | |
| let input = Bundle.main.url(forResource: "IMG_0037", withExtension: "HEIC")! | |
| let output = FileManager().temporaryDirectory.appendingPathComponent("IMG_0037.GAIN_MAP.BMP") | |
| let source = CGImageSourceCreateWithURL(input as CFURL, nil)! | |
| // urn:com:apple:photo:2020:aux:hdrgainmap | |
| let dataInfo = CGImageSourceCopyAuxiliaryDataInfoAtIndex(source, 0, kCGImageAuxiliaryDataTypeHDRGainMap)! as Dictionary |
| import SQLKit | |
| import FluentKit | |
| /// Read each method's comments in the order they appear (from `fieldKey(for:)` through `sqlColumn(for:)`) for an | |
| /// _EXTREMELY_ detailed breakdown of how the heck this all works. | |
| extension Fields { | |
| /// Returns the singular `FieldKey` corresponding to a specific property of the model. | |
| /// | |
| /// Detailed operation: | |
| /// |
| /// Gathers progression information of all computations within the `operation` block. | |
| /// | |
| /// This free function sets the `@TaskLocal` value `Task.unsafeProgress`, which serves as an | |
| /// indicator to any task in the structure concurrency tree to start gathering progression information. | |
| /// Functions supporting _progress_ will forward such data into the `progress` handler. | |
| /// | |
| /// ## Features | |
| /// - Progress data forwarding to the `progress` handler. | |
| /// - No locks (and no thread hopping). | |
| /// - Supports concurrent operations. |
According to the Performance penalty from the Static Linux SDK post I would like to provide a step-by-step instruction of how to patch static-linux-sdk with mimalloc
It is important for swift apps – especially for server-side apps – to be performant
Great question! Maybe in the future — who knows?
If you're from the future, you can check your SDK by running