Skip to content

Instantly share code, notes, and snippets.

View hectormatos2011's full-sized avatar

Hector Matos hectormatos2011

View GitHub Profile
@hectormatos2011
hectormatos2011 / setup-github-key.sh
Last active August 2, 2017 01:07 — forked from treelzebub/setup-github-key.sh
Generate new public key (or use existing) and copy to clipboard, to paste into GitHub
#!/bin/bash
# This is a simple script that sets up a public SSH key and copies it to the
# clipboard, so you can paste it into your GitHub account here:
# https://github.com/settings/keys
#
# It only handles the default public key name, id_rsa. Deal with it :D
# Check for existing public key
keys=`find ~/.ssh -type f -name 'id_rsa.pub'`

Keybase proof

I hereby claim:

  • I am hectormatos2011 on github.
  • I am krakendev (https://keybase.io/krakendev) on keybase.
  • I have a public key whose fingerprint is F389 BAA0 8B40 7299 4BE4 18DD EC0E 33CA B4CD 45F9

To claim this, I am signing this object:

@hectormatos2011
hectormatos2011 / TypeErasure.swift
Created May 6, 2016 00:09
Using type erasure to replace Objective-C's UIView<SomeProtocol> property feature
//: Playground - noun: a place where people can play
import UIKit
protocol MythicalCreatureDisplayable: class {
associatedtype Conformer = Self
var displayer: Conformer { get }
func displayMythicalCreature()
}
@hectormatos2011
hectormatos2011 / UIGestureRecognizer+Closures.swift
Last active December 24, 2016 20:27
UIGestureRecognizer+Closures.swift
//
// UIGestureRecognizer+Closures.swift
// Closures
//
// Created by Hector on 7/23/14.
// Copyright (c) 2014 Hector Matos. All rights reserved.
//
import Foundation