Skip to content

Instantly share code, notes, and snippets.

View relrod's full-sized avatar

Rick Elrod relrod

View GitHub Profile
@relrod
relrod / proxy.md
Created September 22, 2020 17:41 — forked from yougg/proxy.md
complete ways to set http/socks/ssh proxy environment variables

set http or socks proxy environment variables

# set http proxy
export http_proxy=http://PROXYHOST:PROXYPORT

# set http proxy with user and password
export http_proxy=http://USERNAME:PASSWORD@PROXYHOST:PROXYPORT

# set http proxy with user and password (with special characters)
@relrod
relrod / topology.v
Created May 15, 2016 08:24 — forked from andrejbauer/topology.v
How to get started with point-set topology in Coq. This is not actually how one would do it, but it is an intuitive setup for a classical mathematician.
(* How do to topology in Coq if you are secretly an HOL fan.
We will not use type classes or canonical structures because they
count as "advanced" technology. But we will use notations.
*)
(* We think of subsets as propositional functions.
Thus, if [A] is a type [x : A] and [U] is a subset of [A],
[U x] means "[x] is an element of [U]".
*)
Definition P (A : Type) := A -> Prop.
@relrod
relrod / AlaCarte.hs
Last active August 29, 2015 14:07 — forked from puffnfresh/AlaCarte.hs
module AlaCarte where
-- Control.Monad.Free
data Free f a = Free (f (Free f a)) | Pure a
instance Functor f => Monad (Free f) where
Pure a >>= f = f a
Free r >>= f = Free (fmap (>>= f) r)
return = Pure
Please help compile a list of all Scala-related IRC rooms.
All of these channels are on Freenode.
#akka | concurrency & distribution framework
#argonaut | json library
#fp-in-scala | the book Functional Programming in Scala
#geotrellis | geoprocessing library
#indyscala | regional scala group
#json4s | json library
#!/bin/bash
for i in {1..64}; do
./errbit 2400 hts1_2k4.c2 hts1_2k4_$i.c2 $i;
done;
case class Person(name: String, age: Int) {
def <=>(person: Person) = age compare person.age
override def toString = name + " (" + age + ")"
}
val group = List(
Person("Bob", 33),
Person("Chris", 16),
Person("Ash", 23)
)
@relrod
relrod / test.php
Created January 8, 2011 19:19 — forked from JAChapmanII/test.php
<html>
<head>
</head>
<body>
<pre>
<?php
$json = file_get_contents( "http://github.com/api/v2/json/repos/show/JAChapmanII" );
$output = json_decode( $json );
foreach( $output->repositories as $repo ) {

Comments

  • /* */
  • //

Function Definition

:function1 [str1 str2]

:string (join " " [str1 str2])