Skip to content

Instantly share code, notes, and snippets.

Benjamin Goering gobengo

Block or report user

Report or block gobengo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View pulumi-wordpress.ts
import * as pulumi from "@pulumi/pulumi";
import * as k8s from "@pulumi/kubernetes";
let config = new pulumi.Config();
const k8sNamespacePrefix = config.require('k8sNamespacePrefix')
// https://github.com/pulumi/pulumi-kubernetes/issues/217#issuecomment-459105809
const addNamespaceTransformation = (namespaceName: string) => (o: any) => {
if (o !== undefined) {
if (o.metadata !== undefined) {
View activity.json
{
"@context": "http://www.w3.org/ns/activitystreams#",
"id": "https://rhiaro.co.uk/2016/12/georgetown-wandering",
"type": "http://www.w3.org/ns/activitystreams#Article",
"content": "<p>Yesterday evening (21st) I went for a 'quick walk' into town. My apartment is about a 20 minute walk from the edge of George Town heritage area and 40 minutes from the jetty and core tourist zone. Between home and the edge of the 'nice' part of town is not particularly nice: apartment blocks, malls and big roads with... intermittent... footpaths. There are still lots of interesting places to stop of course; markets, stalls, local restaurants, general streetside chaos. Walking around here takes a lot of concentration, between trying to take in the surroundings, not being hit by scooters and cars, avoiding enormous open holes into the sewer, and not accidentally buying a kilo of tropical fruit every five minutes.</p>\r\n\r\n<p>The sky was blue. My goal was to procure coconut oil for cooking. I thought it would be easy to
View gist:72454c03078313933157
### Keybase proof
I hereby claim:
* I am gobengo on github.
* I am bengo (https://keybase.io/bengo) on keybase.
* I have a public key whose fingerprint is 3EFE C28D FEA1 955D CBFB 3B91 FAFE 5464 7D99 6E04
To claim this, I am signing this object:
View urn-resolver-api.md

URN Resolver API

Many Livefyre APIs use Livefyre URNs as ids of the resources they describe.

The URN Resolver API allows a client to resolve a Livefyre URN to a related URL that describes or manages the resource indicated by the URN.

Use Cases

  • Given knowledge of a Livefyre Collection's Network, Site ID, and Article ID, I can create a link to manage that Collection in Livefyre Studio's web UI.
@gobengo
gobengo / xsdDateTime.js
Created Jun 8, 2015
JavaScript xsd:dateTime Parser
View xsdDateTime.js
// built from definition: http://books.xmlschemata.org/relaxng/ch19-77049.html
var xsdDateTimePattern = new RegExp([
'(\\d{4})', //year
'-',
'(\\d{2})', // month
'-',
'(\\d{2})', // day
'T',
'(\\d{2})', // hour
':',
@gobengo
gobengo / content.json
Created Jan 14, 2013
StreamHub-Backbone Content Properties
View content.json
{
"id": "1fe8d2f7-4266-4830-af03-a389ca86f31b",
"event": 1.3575080009429e+15,
"bodyHtml": "Bonne rentr\u00e9e , rien qu'a dire ces 2mots j'ai envie de chialer.\n#va#retrouver#ces#deux#amour#Marie#laurette. ",
"ancestorId": "1fe8d2f7-4266-4830-af03-a389ca86f31b",
"annotations": {
},
"authorId": "0fb0638b4b1ef064d1086f6522d5743f@instagram.com",
"createdAt": 1357508000,
@gobengo
gobengo / gist:2731289
Created May 19, 2012 — forked from clintel/gist:1155906
Fenced code in bullet lists with GitHub-flavoured MarkDown??
View gist:2731289

Fenced code blocks inside ordered and unordered lists

  1. This is a numbered list.

  2. I'm going to include a fenced code block as part of this bullet:

    Code
    More Code
    
@gobengo
gobengo / index.html
Created Dec 12, 2011 — forked from ninowalker/server.py
A simple web server in two (three) steps
View index.html
<html>
<head></head>
<body>
<p>Hello, world!</p>
</body>
</html>
@gobengo
gobengo / node-gchat.js
Created Jan 22, 2011
node.js-driven Google Chat bot
View node-gchat.js
var xmpp = require('node-xmpp'),
secret = require('./secret'),
util = require('util');
var creds = {
jid: 'bengoering@gmail.com',
password: secret.pw, //string
};
var GChat = function(creds) {
View GraphMatrix
Imagine graph G with vertexes A, B, C (sketch this if that's your thing). G has the following directed edges:
A->B
B->C
C->A
Basically this is a triangle with a loop. Now, let's say we model this with a binary matrix. Edge A->B means that G[A][B]=1. Similarly: G[B][C], G[C][A] = 1, 1. Think about this 2D array as a matrix G1:
ABC
A010
B001
C100
You can’t perform that action at this time.