Skip to content

Instantly share code, notes, and snippets.

View rclayton-the-terrible's full-sized avatar

Richard Clayton rclayton-the-terrible

View GitHub Profile
@rclayton-the-terrible
rclayton-the-terrible / LICENSE.md
Last active November 29, 2021 19:46
TypeScript WebSequenceDiagram Client

Copyright (c) 2019 Richard Clayton

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all

@rclayton-the-terrible
rclayton-the-terrible / index.html
Last active October 15, 2018 01:00
Mindy Code
<html>
<head>
<title>Test Document</title>
<style>
h1 {
font-family: 'Courier New', Courier, monospace;
color: red;
}
</style>
@rclayton-the-terrible
rclayton-the-terrible / build_status.html
Last active September 19, 2018 20:32
Build Status
<html>
<body>
<img src="https://circleci.com/gh/peachjar/peachjar-core.svg?style=svg&circle-token=69bcd0c88a218784f3b58e7a9f2b18b57c4698d2" />
</body>
</html>
@rclayton-the-terrible
rclayton-the-terrible / build_and_install_rmq_web_stomp_ssl.sh
Last active August 31, 2018 17:16
Build and Install RabbitMQ Web Stomp with SSL (from @jshiell's repo).
# Make sure you have Mercurial and Git installed
git clone https://github.com/rabbitmq/rabbitmq-public-umbrella.git
cd rabbitmq-public-umbrella
make co
cd rabbitmq-web-stomp
git clone https://github.com/jshiell/rabbitmq-web-stomp.git
make
cd dist
@rclayton-the-terrible
rclayton-the-terrible / config_dev.exs
Last active April 27, 2016 03:03
Elixir+Phoenix and Webpack
use Mix.Config
# For development, we disable any cache and enable
# debugging and code reloading.
#
# The watchers configuration can be used to run external
# watchers to your application. For example, we use it
# with brunch.io to recompile .js and .css sources.
config :myapp, MyApp.Endpoint,
http: [port: 4000],
SURVEY_ID = "12345678"
HOST = "https://api.surveymonkey.net"
LAST_DATE_CHECKED = "2013-01-01 00:00:00"
# set up the two endpoint urls
respondent_uri = "%s/v2/surveys/get_respondent_list" % HOST
response_uri = "%s/v2/surveys/get_responses" % HOST
# set up the initial post data for respondent and responses
# endpoints
@rclayton-the-terrible
rclayton-the-terrible / BugFixesIT.java
Created August 2, 2013 00:21
Demonstrates that the text will be parsed without timing out (from a previous infinite loop introduced by the 'named-regex' library).
package com.berico.clavin.resolver.integration;
import org.junit.Before;
import org.junit.Test;
import com.berico.clavin.GeoParser;
import com.berico.clavin.GeoParserFactory;
import com.berico.clavin.resolver.ResolutionContext;
public class BugFixesIT {
@rclayton-the-terrible
rclayton-the-terrible / installExhibitor.sh
Created July 2, 2013 19:27
Install Exhibitor from Maven pom.xml.
POM="https://raw.github.com/Netflix/exhibitor/master/exhibitor-standalone/src/main/resources/buildscripts/standalone/maven/pom.xml"
JAR="exhibitor-war-1.0-jar-with-dependencies.jar"
RUN="java -jar target/$JAR"
mkdir exhibitor
cd exhibitor
curl $POM -o pom.xml
mvn assembly:single
java -jar target/$JAR --help && echo $RUN >> run.sh
public class MyWritable implements Writable {
// Some data
private int counter;
private long timestamp;
public void write(DataOutput out) throws IOException {
out.writeInt(counter);
out.writeLong(timestamp);
}
@rclayton-the-terrible
rclayton-the-terrible / gist:2474028
Created April 23, 2012 21:38
Writable Interface
package org.apache.hadoop.io;
import java.io.DataOutput;
import java.io.DataInput;
import java.io.IOException;
public interface Writable {
void write(DataOutput out) throws IOException;