Skip to content

Instantly share code, notes, and snippets.

View rockymadden's full-sized avatar
Setting status

Rocky Madden rockymadden

Setting status
  • UiPath
  • Pale Blue Dot
View GitHub Profile
rockymadden / combinators.js
Created February 20, 2018 13:51 — forked from Avaq/combinators.js
Common combinators in JavaScript
const I = x => x;
const K = x => y => x;
const A = f => x => f(x);
const T = x => f => f(x);
const W = f => x => f(x)(x);
const C = f => y => x => f(x)(y);
const B = f => g => x => f(g(x));
const S = f => g => x => f(x)(g(x));
const P = f => g => x => y => f(g(x))(g(y));
const Y = f => (g => g(g))(g => f(x => g(g)(x)));
rockymadden /
Last active February 23, 2016 20:57 — forked from greglindahl/
Developer Portal pitch

The Pitch

Let's move to a modern approach for our developer documentation and, generally, improve developer experiences by creating a focused developer portal. Let's unify our documentation efforts, use documentation to reduce customer success needs, use documentation to improve experiences, and create a one-stop-shop for anything a developer might need. Additionally, lets make it conceptually simple and easy to maintain and support. This idea is not new, in fact nearly every modern API company uses this approach:

rockymadden /
Created October 9, 2015 02:31 — forked from kennwhite/
OpenSSL command line recipe for multi-public key file encryption. Any single private key paired to one of the public keys can decrypt the file.
#!/usr/bin/env bash
# Example of multiple key AES encryption for text files using the openssl v. 0.9.8+ command line utility
# Uses n public certs as key for MIME PKCS envelope, any individual private key can decrypt.
# If standard RSA ssh keys exist, these can be converted to public certs as well (and ssh keys can decrypt)
# To sign (and verify) the encrypted file, one of the private keys is required, see:
# for openssl smime examples
# or for cms utility (OpenSSL v. 1.0+)
rockymadden /
Created October 9, 2015 02:31 — forked from rgbkrk/
Encrypt a (short) file using someone's public key from github
#!/usr/bin/env bash
# HubCrypt
# ========
# Decrypt a file encrypted using hubencrypt (ok, it's just openssl + rsautl +
# your SSH keys). It needs the private key that matches your last public key
# listed at<user>.keys
# unregister broken GHC packages. Run this a few times to resolve dependency rot in installed packages.
# ghc-pkg-clean -f cabal/dev/packages*.conf also works.
function ghc-pkg-clean() {
for p in `ghc-pkg check $* 2>&1 | grep problems | awk '{print $6}' | sed -e 's/:$//'`
echo unregistering $p; ghc-pkg $* unregister $p
# remove all installed GHC/cabal packages, leaving ~/.cabal binaries and docs in place.

Business Models


Models Examples
Display ads Yahoo!
Search ads Google
{-# LANGUAGE PackageImports #-}
You need to register your Twitter application at <>
to get the consumer key and secret needed for OAuth. When connecting to
Twitter for the first time, do this:
let consumer = Consumer "consumer key" "consumer secret"
token <- authenticate
module Main where
-- A simple directory summing thing for Haskell.
-- by Daniel Lyons <>
-- BSD licensed.
import Control.Applicative
import Data.Either
import Data.Foldable
package pong.imperative
sealed trait Event
class PongConnection {
def isConnected(): Boolean = sys.error("not implemented")
def readEvent(): Event = sys.error("not implemented")
def moveUp(): Unit = sys.error("not implemented")
def moveDown(): Unit = sys.error("not implemented")
def shootMissile(): Unit = sys.error("not implemented")
trait Pointed[F[_]] {
def point[A](a: => A): F[A]
trait Functor[F[_]] {
def fmap[A, B](fa: F[A])(f: A => B): F[B]
trait Show[A] {
def shows(a: => A): String