Skip to content

Instantly share code, notes, and snippets.

Trying my best to be worth something.

Benjamin Lupton balupton

Trying my best to be worth something.
View GitHub Profile
dvalfrid / gist:72a203931a928dbc67e2da568b4c5547
Last active Nov 5, 2020
Control the POE fan with ubuntu
View gist:72a203931a928dbc67e2da568b4c5547

Rasparry PI - how to control your POE-fan in Ubuntu

Check if you have the POE-fan

cat /sys/class/thermal/cooling_device0/type

should give rpi-poe-fan

Create file

sudo vi /etc/udev/rules.d/50-rpi-fan.rules

View ExampleHook.ts
import { Component, h } from '@stencil/core';
import { useState } from 'haunted';
import { useHook } from './stencil-hooks';
tag: 'example-hook',
export class ExampleHook {
render = useHook(this, () => {
balupton /
Last active Oct 4, 2020
Learnings from living moneyless for a year in 2014-2015

What inspired it?

In 2013 when I was teaching JavaScript in Berlin, I was introduced to the squatter and dumpster diving movements. Then later in 2013 in Sydney, was introduced to foraging.

Recognised that:

  • my conceptions of food was constrained to that of supermarkets.

  • one can have their basic necessities supplied without money, so people should stop demanding money

WebReflection /
Last active Nov 24, 2020
A recap of my FE / DOM related libraries

My FE/DOM Libraries

a gist to recap the current status, also available as library picker!

Minimalistic Libraries

do one thing only and do it well

  • µhtml (HTML/SVG auto-keyed and manual keyed render)
  • augmentor (hooks for anything)
  • wickedElements (custom elements without custom elements ... wait, what?)
balupton /
Last active Jul 15, 2020
Understanding Society

Understanding Society

A talk, book, and series of posts to write.

  1. How to Read A Book
  2. Normativeness and Tolerance
    1. Bullying
      1. Political Correctness is bullying at the Telos
        1. Intolerant Tolerance
        2. Insensible Sensitivities
colllin /
Last active Oct 10, 2020
FaunaDB User Token Expiration (for ABAC)

Auth0 + FaunaDB ABAC integration: How to expire Fauna user secrets.

Fauna doesn't (yet?) provide guaranteed expiration/TTL for ABAC tokens, so we need to implement it ourselves if we care about it.

What's in the box?

3 javascript functions, each of which can be imported into your project or run from the command-line using node path/to/script.js arg1 arg2 ... argN:

  1. deploy-schema.js: a javascript function for creating supporting collections and indexes in your Fauna database.
kitsonk / bronto.ts
Last active Nov 21, 2020
Example Deno Static Server
View bronto.ts
import {
} from "";
import {
colllin /
Last active Aug 11, 2020
Auth0 + FaunaDB integration strategy



At the very least, we need two pieces of functionality:

  1. Create a user document in Fauna to represent each Auth0 user.
  2. Exchange an Auth0 JWT for a FaunaDB user secret.
bvaughn /
Last active Nov 26, 2020
How to use profiling in production mode for react-dom
posener /
Last active Nov 22, 2020
Story: Writing Scripts with Go

Story: Writing Scripts with Go

This is a story about how I tried to use Go for scripting. In this story, I’ll discuss the need for a Go script, how we would expect it to behave and the possible implementations; During the discussion I’ll deep dive to scripts, shells, and shebangs. Finally, we’ll discuss solutions that will make Go scripts work.

Why Go is good for scripting?

While python and bash are popular scripting languages, C, C++ and Java are not used for scripts at all, and some languages are somewhere in between.

You can’t perform that action at this time.