Skip to content

Instantly share code, notes, and snippets.

View jbrennan's full-sized avatar
😅
bestie please let me merge

Jason Brennan jbrennan

😅
bestie please let me merge
View GitHub Profile
@jbrennan
jbrennan / nearthespeedoflight.css
Created April 3, 2016 01:42
Style for Nearthespeedoflight.com from Feb 2013 to April 2016
/* ============================== */
/* ! */
/* ! Speed of Light style ver 2.6 */
/* ! Copyright 2011 Jason Brennan */
/* ! */
/* ! February 20 2013 */
/* ! */
/* ============================== */
@jbrennan
jbrennan / nearthespeedoflight-2016.css
Created April 3, 2016 03:20
Style for Nearthespeedoflight.com April 2 2016
/* ============================== */
/* ! */
/* ! Speed of Light style ver 3 */
/* ! Copyright 2016 Jason Brennan */
/* ! */
/* ! April 2 2016 */
/* ! */
/* ============================== */
@jbrennan
jbrennan / LineScaling.swift
Created August 3, 2016 23:13
The math behind a “drag to scale this line” operation.
extension Line {
/** Returns a scaled line according to the projection of `scalingPoint` onto the receiver.
- parameter scalingPoint: A point interpreted as a vector used for scaling this line. This point should be something like the location of a touch or cursor during a "drag to scale" operation, but the point doesn't have to lie along the line itself. The point **must** be in the same coordinate space as the line.
*/
func lineByScalingToTouchPoint(scalingPoint: Point) -> Line {
// This algorithm works by
// - treating the incoming point as a vector,

Hello Everyone,

The Swift 3 release is nearing completion, so it is time to look back on the release, learn from what happened, and use it to shape what we (the Swift community) do in the year ahead. Overall, Swift 3 is going to be an absolutely amazing release, and it is impressive how much got done. Thank you to everyone who contributed to making it happen. Instead of diving into a flurry of new proposals immediately, it is important to take stock of where we are, and look at the bigger picture.

Metapoint: this email is ridiculously long and covers multiple topics. Instead of replying to it directly, it is best to start new threads on individual topics that you’d like to discuss. Just tag them with “[Swift 4]” in the subject line.

Swift 3 Retrospective

Every year of Swift’s development has been completely different from the previous one, and I expect Swift 4 to continue this trend. With a goal of learning and improving year over year, here are some observations & retrospective about Swi

@jbrennan
jbrennan / ViewController.swift
Created August 31, 2018 20:11
Simple file for converting Localizable.strings key=values back into a codebase
class ViewController: NSViewController {
override func viewDidLoad() {
super.viewDidLoad()
let translations = translationsFor(stringsFilePath: "/Users/jasonbrennan/peloton/Argon/Argon/Supporting Files/Localizable.strings")
for translation in translations {
replace(translation: translation, inProjectDirectory: "/Users/jasonbrennan/peloton/Argon/Argon")
}
@jbrennan
jbrennan / wwdc2014
Created July 16, 2019 15:00 — forked from phnessu4/wwdc2014
wwdc 2014 sessions and pdf
pdf
http://devstreaming.apple.com/videos/wwdc/2014/102xxw2o82y78a4/102/102_platforms_state_of_the_union.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/201xx2xfazhzce8/201/201_advanced_topics_in_internationalization.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/202xx3ane09vxdz/202/202_whats_new_in_cocoa_touch.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/203xxh9oqtm0piw/203/203_introducing_healthkit.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/204xxhe1lli87dm/204/204_whats_new_in_cocoa.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/205xxqzduadzo14/205/205_creating_extensions_for_ios_and_os_x,_part_1.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/206xxdiurnffagr/206/206_introducing_the_modern_webkit_api.pdf?dl=1
http://devstreaming.apple.com/videos/wwdc/2014/207xx270npvffao/207/207_accessibility_on_os_x.pdf?dl=1