Skip to content

Instantly share code, notes, and snippets.

@ollieatkinson
ollieatkinson / Navigation.swift
Last active March 3, 2022 18:16
NavigationRoute for Swift Composable Architecture
import ComposableArchitecture
import SwiftUI
public struct RouteIntent<R: NavigationRoute>: Hashable {
public enum Action: Hashable {
case navigateTo
case enterInto(EnterIntoContext = .default)
}
@JacobJohansen
JacobJohansen / AuthyToOtherAuthenticator.md
Created October 20, 2017 15:12 — forked from gboudreau/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Generating Authy passwords on other authenticators


There is an increasing count of applications which use Authy for two-factor authentication. However many users who aren't using Authy, have their own authenticator setup up already and do not wish to use two applications for generating passwords.

Since I use 1Password for all of my password storing/generating needs, I was looking for a solution to use Authy passwords on that. I couldn't find any completely working solutions, however I stumbled upon a gist by Brian Hartvigsen. His post had a neat code with it to generate QR codes (beware, through Google) for you to use on your favorite authenticator.

His method is to extract the secret keys using Authy's Google Chrome app via Developer Tools. If this was not possible, I guess people would be reverse engineering the Android app or something like that. But when I tried that code, nothing appeared on the screen. My gues

@ethanhuang13
ethanhuang13 / xcode-beta-slink.sh
Last active February 3, 2023 20:21
Symbolic link from Xcode.app to Xcode-beta.app (Xcode 11.2)
@seivan
seivan / gist:d360aaec9780692e3520
Created July 16, 2014 01:46
NSBezierPath ArcCenter does not work like the UIBezierPath ArcCenter
//This doesn't work as its iOS counterpart
self.appendBezierPathWithArcWithCenter(center, radius: radius, startAngle: startAngle, endAngle: endAngle, clockwise: clockwise)
//This worked like the iOS counterpart
let path = CGPathCreateMutableCopy(self.CGPath)
CGPathAddArc(path, nil, center.x, center.y, radius, startAngle, endAngle, clockwise)
self.CGPath = path