Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am kmoe on github.
  • I am katy (https://keybase.io/katy) on keybase.
  • I have a public key whose fingerprint is 40F0 ECDC C07E 25D5 A880 7877 A122 3E8E B495 2312

To claim this, I am signing this object:

@kmoe
kmoe / isTheWebsiteDown.js
Last active August 29, 2015 14:09 — forked from Marak/isTheWebsiteDown.js
Checks to see if a website is down
var http = require('http');
module['exports'] = function isTheWebSiteDown (hook) {
http.get(hook.params.url, function(res){
hook.debug(hook.params.url + " is up and running.")
hook.res.end('false');
}).on('error', function (){
hook.debug(hook.params.url + " is DOWN!")
hook.res.end('true');
});
@kmoe
kmoe / gist:f67142fb5623ce6b30b7
Created December 20, 2014 15:46
pyenv --verbose 3.4.2
This file has been truncated, but you can view the full file.
/var/folders/dm/rs_77nws2vlbbw0y7tm_d7v80000gn/T/python-build.20141220154349.11478 ~/Development/python
Downloading Python-3.4.2.tgz...
HTTP/1.1 200 OK
Server: GitHub.com
Content-Type: application/octet-stream
Last-Modified: Tue, 04 Nov 2014 09:32:24 GMT
Expires: Sat, 20 Dec 2014 15:53:49 GMT
Cache-Control: max-age=600
Content-Length: 19257270
Accept-Ranges: bytes
module['exports'] = function kahootHighFive (hook) {
var request = require('request');
var params = hook.params;
console.log(params);
var store = hook.datastore;
if (params.token === hook.env.highfive_token) {
var originalChannelRequestParams = {
@kmoe
kmoe / highfive.js
Last active September 4, 2016 20:56
module['exports'] = function highFive(hook) {
// hook.io has a range of node modules available - see
// https://hook.io/modules.
// We use request (https://www.npmjs.com/package/request) for an easy way to
// make the HTTP request.
var request = require('request');
// The parameters passed in via the slash command POST request.
var params = hook.params;
@kmoe
kmoe / echoHttpRequest.js
Last active August 29, 2015 14:27 — forked from Marak/echoHttpRequest.js
Echo HTTP requests
module['exports'] = function echoHttp (hook) {
console.log("Console messages are sent to /logs");
console.log(hook.params);
console.log(hook.req.path);
console.log(hook.req.method);
module['exports'] = function kahootDeskbeers(hook) {
// Usage:
// /deskbeers balance - gets your balance
// /deskbeers drink [number] - records that you drank [number] beers
// /deskbeers pay [amount] - records that you paid the pig/George £[amount]
var DESKBEERS_ADMIN_USERNAME = 'george';
var USAGE = 'Usage: `/deskbeers balance` to get your balance, `/deskbeers drink [number]` to record that you drank [number] beers, `/deskbeers pay [amount]` to record that you paid £[amount] to George or the pig.';
@kmoe
kmoe / witch.md
Last active November 1, 2015 10:26

This presentation is going to be about the past—so we gain more understanding of the history we’re working with and what we mean when we say ‘magic’ and ‘witchcraft’. Also some of the dangers and problems in the history.

First a note: I’m going to use the words ‘spirituality’ and ‘religion’ interchangeably. Many people are averse to the word ‘religion’ because they associate with any number of oppressive institutions. But I feel spirituality is unnecessarily vague and also focuses on a spirit vs matter dualism.By religion I mean reverence for some kind of power beyond everyday human experience.

Not going to focus on witch-burnings or WITCH, but 19th and 20th c intellectual history leading up to modern witchcraft.

Also I'm going to focus mostly on England because that's where we are + what I know the most about. 

[slide]

@kmoe
kmoe / iot_security.md
Last active May 2, 2019 01:41
a starter kit of IoT security resources for discussion at the IoT roundtable at enterJS 2016
@kmoe
kmoe / client.go
Created September 21, 2016 14:41 — forked from jzelinskie/client.go
grpc bidirectional streams in golang
package main
import (
"log"
"time"
"golang.org/x/net/context"
"google.golang.org/grpc"
pb "github.com/jzelinskie/grpc/simple"